|
OK, I found the problem... but wtf? Maximum doesn't mean maximum? Since when does Maximum mean "maximum - largechange + 1"? How is that beneficial? Any insight as to why that design choice was made?
|
|
|
|
|
Hi
I have declared a Socket.I have some problem on recieving data.I can not find my answers about Socket flags And how could I use them. Actually I wanted to use "SocketFlags.MaxIOVectorLength" unfortunatly it did not worked.
tmpSocket.Receive(DataBuffer,0,BufferSize,SocketFlags.MaxIOVectorLength);
Please give me help or resource on this Subject ? Thanks in advance.
|
|
|
|
|
Hi there,
I have a little GDI+ (I think) question to ask... I am writing a little howitzer game (remember Scorched Earth?) to further my understanding of the .Net GDI+ world. Now I have an interesting problem: my tanks are (or should be) placed on a filled region representing the ground, according to its X-position, with its Y-position determined by the height of the ground at that point. What I need to know, is how to find the Y-coordinate of the top of the region, when given the X-coordinate. Currently all I can think of is looping a PointF through all the Y-coords for the given X-coord and testing when it becomes Region.IsVisible(Point) in the region. This is kinda hacky an I would like to know if the .Net framework (I'm using version 2.0) has anything else I could use?
Any help would be greatly appreciated!
A)bort, R)etry, I)nfluence with large hammer.
|
|
|
|
|
Hi everyone!
How can I encapsulate my program into a software (with setup.exe file)?
My English is so bad so that I hope u can understand what I mean ^_^.
Thank you!
|
|
|
|
|
If I am not wrong....Select the following procedure:-
Run .Net
Select New Project
Select Setup and Deployment Projects(from Project Types...in left pane)
Finally Select Setup Project (from Templates...in right pane)
Give the Proejct any App Name and Click Ok!!
Add the file which has your program and or even add the folder that
contains whole of ur program with source and etc etc.
Run it & u will have have ur setup.exe file generated.
Ppl if i perceive his question...make me correct and give him solution in that case...
Regards
|
|
|
|
|
we have a case study in class... and this is all about turbo c.. i don't know where to post this thread that is why i just place it here.. i need any pro programmer to help me.. well the prblem goes this way..
GROUP
PROBLEM
Write an astrology program. The user types in his or her birthday, and the program responds with the user’s sign and horoscope. The month may be entered as a number from 1 to 12 or as a word and not case-sensitive. Use the functions that involve strings (READ CHAPTER 8 OF THE THICK BOOK). Use a newspaper horoscope section for the horoscopes or you can write your own horoscope and dates of each sign. If the user is only two days away from an adjacent sign, the program announces that the user is on a “cusp” and also outputs the horoscope for the nearest adjacent sign. The screen design should also be considered.
pls reply in my email as soon as you read this.. thank you very much!! ^_^
|
|
|
|
|
First: wrong language.
Second: attempt to do the problem before you dump it into a forum.
|
|
|
|
|
and third, what's your question?
If you are just trying to get the legacy yTurbo C, you can download it from Borland for free. That should answer your question; the rest is academic.
Matt Gerrans
|
|
|
|
|
Hello!
I am trying to create Namespace Extension using Dave Rensin's article http://msdn.microsoft.com/msdnmag/issues/04/01/WindowsShell/default.aspx
After compilation his example I created c:\temp\test.{6B49E580-186E-4f8c-AB6A-E55D6F0F171D} directory. But when opening c:\temp I get message:
Failed to load resources from resource file
Please check your Setup
Can anybody help?
Oleg Chebotar
|
|
|
|
|
I'm trying to determine the conversion of this function...
in c:
exit(-1);
what's in c#?
|
|
|
|
|
Isn't it Environment.Exit()?
MSDN[^]
best regards,
David 'DNH' Nohejl
Never forget: "Stay kul and happy" (I.A.)
|
|
|
|
|
Sounds like it. I'll try that. Thanks!
|
|
|
|
|
I hope your goal is to be able to return a value (or errorlevel) from a console app, rather than to be able to exit your program from all sorts of odd places. If so the best way is to have a return value from Main(), like so:
namespace Demo
{
class ReturnErrorLevel
{
public static int Main( string [] args )
{
if( args.Length == 1 )
try
{
return int.Parse(args[0]);
}
catch( System.Exception ex )
{
System.Console.WriteLine(ex.ToString());
}
return 0;
}
}
}
Yes, I know most people are only interested in the "answer" and not any advice or opinions, but on this one I must persist. I once got a DLL from another group in the same company and after using some facilities in it, my app would seemingly crash -- just disappear. It was driving me nuts. Looking through the source code, I discovered that in many different cases, it would do whatever calculations were required, print to standard out (another silly thing for a DLL to be doing) and exit().
Exiting from all over your app is like having a large function with tons of returns, or gotos. Life is a lot simpler if the app exits from one place -- at the end of the main entrypoint.
Matt Gerrans
|
|
|
|
|
I recently received Avalon & WinFX Community Technology Preview. I tried messing around with it a bit (Visual Studio 2005 -> new C# project) and soon found those wierd "Preview" events, like PreviewMouseMove. A quick search at internet revealed this MSDN article: The "Avalon" Input System[^]
But I still don't understand what's the practical use of them. Could anyone please help me out here ?
|
|
|
|
|
How can I get the handle to a window when it's class changes? Normally I would use FindWindow and pass it the Class and the title of the window. What do I do in the variable class case? Is there a way to find it just by the title?
/\ |_ E X E GG
|
|
|
|
|
Documentation states that the FindWindow method finds any window whose title matches the lpWindowName parameter if the lpClassName parameter is NULL.
www.troschuetz.de
|
|
|
|
|
|
|
Recently, I voiced my opinion (so what is new ) about my dislike for the underscore ("_") as a member prefix for private or protected members. Thought I would see what other think on this touchy subject. I personally find them very ugly and it makes the code harder to read. It makes member variable stand out worse than if they were in bold large type fonts.
Please take a quick moment to cast your vote below.
Vote[^]
Results[^]
Rocky <><
www.HintsAndTips.com
Me Blogs: wdevs - MSN Spaces (new)
|
|
|
|
|
How can i change text color of an item or subitem ?
Thanks!
|
|
|
|
|
See ListViewItem.ForeColor .
This space for rent!
My Blog
|
|
|
|
|
Hi,
I have a windows program with a menu that opens other Forms.
I've noticed that users will min. a Form and then later run another instance of the same Form from the menu. How do I make it so that instead of another Form opening, it just restores (displays) the Form already running in taskbar?
New to programming... thanks
|
|
|
|
|
Save your Form in a Field permanently. If it already exists you can restore it by setting the WindowState to normal and activating it as well.
WinForm.WindowState = FormWindowState.Normal;
WinForm.Activate();
|
|
|
|
|
Use the Singleton pattern. Create a static member variable in your form where you keep an instance of your form.
Add a static method to your form class called "GetInstance" (or whatever you like). In that method check to see if your static variable contains an instance of the form. If it doesn't, put one in there (using new).
Then return from GetInstance the form instance kept in your member variable.
This guarantees that as long as you always call "GetInstance" to get your form object (this will require discipline on your part) only one instance of a form will ever be created:
MyCustomForm myForm = MyCustomForm.GetInstance();
MyCustomForm myForm2 = MyCustomForm.GetInstance();
myForm.WindowState = Normal;
myForm.Activate();
This space for rent!
My Blog
|
|
|
|
|
What TypeCode does an int-Array have?
|
|
|
|