CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: Jim_Auricman

Page 1 of 5 1 2 3 4

Search: Search took 0.02 seconds.

  1. Replies
    3
    Views
    655

    Re: System.NullReferenceException

    You need to first instantiate the object before you can modify its members.
  2. Thread: Random

    by Jim_Auricman
    Replies
    1
    Views
    1,741

    Re: Random

    Try:


    long Seed = DateTime.Now.Ticks;
    Random R = new Random((int) Seed);
    int Ri = R.Next();

    Ri can then be printed out.
  3. Replies
    10
    Views
    751

    Re: Focus not returned to InputTextBox

    Thanks for that useful information, RJ. I added (e.Handled = true;) to the KeyDownFn(object sender, KeyEventArgs e) function and now the system doesn't steal the focus when F10 is pressed.
    One line...
  4. Replies
    10
    Views
    751

    Re: Focus not returned to InputTextBox

    I added a button labeled "F10 - Function name" which can be clicked on instead of pressing F10 to run the function.
    This doesn't steal the focus like the F10 key does.
    Both laptops that I tried it...
  5. Replies
    10
    Views
    751

    Re: Focus not returned to InputTextBox

    It means that I have to click in the InputTextBox after running the F10 function, something I don't have to do for the other functions.
    Did you try my test program and see it for yourself?
  6. Replies
    10
    Views
    751

    Re: Focus not returned to InputTextBox

    I created this test program with 2 Textboxes; One is called InputTextBox and the other is called MainTextbox.
    When you click on the InputTextBox (bring it in focus) and press various function keys,...
  7. Replies
    10
    Views
    751

    Re: Focus not returned to InputTextBox

    If you could tell me how to know where the focus is, it would be helpful.
    When I step through the code, including the line, InputTextBox.Focus();, the code is executed, but when execution resumes,...
  8. Replies
    10
    Views
    751

    Re: Focus not returned to InputTextBox

    The same code that was originally activated by pressing F10 works fine when it is moved to activation by pressing F12. The function that was activated by F12 originally, now moved to activation by...
  9. Replies
    10
    Views
    751

    Focus not returned to InputTextBox

    I wrote a program that executes functions when various function keys are pressed.
    At the end of these functions this is called to return the focus to the InputTextBox:
    ...
  10. Re: '2008' is not a valid warning number

    Maybe you can buy a new computer every year, but many of us are not in a position to do that. My old laptops serve my purposes well.
  11. Re: '2008' is not a valid warning number

    Microsoft would not allow me to install any version newer than VS2012 because my laptop didn't have the requirements for them.
    No, I'm not going to install Windows 10. The next time I buy a laptop...
  12. Re: '2008' is not a valid warning number

    Uninstalled VS2010 on W7 laptop; Downloaded VS2012 C# & installed it. - Problem solved.
  13. Re: '2008' is not a valid warning number

    VS2008 was the first version I have used since I started developing C# software in 2008. I have it installed in two older laptops that I still use. When I got newer laptops I installed VS2010 on...
  14. Re: '2008' is not a valid warning number

    Your point is moot since a new project created in the VS2010 development system has the same warning.
    Looking at the CSProj file with notepad doesn't reveal the "2008" string.
    Previously posted:...
  15. Re: '2008' is not a valid warning number

    Sorry, but what you suggested did not appear possible. The option to use an XML editor wasn't on the list.
    BTW, when I create a new forms project in VS2010, the warning appears when I do a build.
    I...
  16. Re: '2008' is not a valid warning number

    Strange, but I can build projects on the VS2008 system without that "Warning 2008 is not a valid warning number." Only when I build on the VS2010 development system do I get that warning.
  17. Re: '2008' is not a valid warning number

    Thanks, Hannes.
    It is only a warning - the project builds OK.
    The .Net version is 4.0.
    The VS 2008 C# program is still on my computer, but it shouldn't be the cause of the warning. I don't want...
  18. [RESOLVED] '2008' is not a valid warning number

    A few days ago I installed VS 2010 C# on my Toshiba Windows 7 laptop.
    I can build projects on it, but I get the following warning:
    Warning 1 '2008' is not a valid warning number F_CW16_Ini
    What...
  19. Re: Change number formatting output (0.10204080 to 1020.408).

    Search on MSDN library for Decimal.ToString Method (String)
    // Use standard numeric format specifiers.
    specifier = "G";
    Console.WriteLine("{0}: {1}", specifier, value.ToString(specifier));
    //...
  20. Replies
    4
    Views
    915

    Re: Need help with very simple program!

    If you want it to recognize names not only 'Will', but containing "Will", like "Willster", etc., you can use 'Contain' rather than '=='.


    if (name.Contains("Will"))
    {
    ...
  21. Replies
    10
    Views
    1,493

    Re: Taking 1 method from another

    You can pass parameters by reference; that way you can declare the variable in the calling function and pass this same variable into both methods.


    public static void function(ref double x)
    ...
  22. Replies
    8
    Views
    4,085

    Re: Saving Entire Projects in SharpDevelop

    The way I do this in Visual Studio is to save a template of the project I want to copy, then close the project and create a new project, importing the template of the old project, using a different...
  23. Replies
    5
    Views
    1,274

    Re: Creating arrays with a method

    Yes, you could pass the array size into the method as a value parameter.
    Loop as long as i < the array length, not i<= array length.
    To display the contents of the array, start with this line, then...
  24. Replies
    5
    Views
    1,274

    Re: Creating arrays with a method

    I see several problems with your method. In your 'for' loop, you are exceeding the bounds of the array. You are looping until i <= Array.Length; When you start with i = 0, you should run as long as i...
  25. Replies
    14
    Views
    1,481

    Re: Creating methods

    You got it. Good luck!
Results 1 to 25 of 109
Page 1 of 5 1 2 3 4





Click Here to Expand Forum to Full Width

Featured