CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 8 of 8
  1. #1
    Join Date
    Apr 2012
    Location
    STL
    Posts
    12

    Anyone Else Experincing This problem?

    When I type the Code

    UserProperties=True
    CPU=Inactive
    User Login Form2.Show()


    The whole program crashes. It works just fine on Visual Studio 2010 but doesnt work a big on Visual C++ no idea why this is happening. This code works. But its crashing -.-

  2. #2
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: Anyone Else Experincing This problem?

    Quote Originally Posted by Se7en_Gamerz View Post
    When I type the Code

    UserProperties=True
    CPU=Inactive
    User Login Form2.Show()
    It is not a C++ code.
    Victor Nijegorodov

  3. #3
    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    3,654

    Re: Anyone Else Experincing This problem?

    In what way do crashing code work?
    Debugging is twice as hard as writing the code in the first place.
    Therefore, if you write the code as cleverly as possible, you are, by
    definition, not smart enough to debug it.
    - Brian W. Kernighan

    To enhance your chance's of getting an answer be sure to read
    http://www.codeguru.com/forum/announ...nouncementid=6
    and http://www.codeguru.com/forum/showthread.php?t=366302 before posting

    Refresh your memory on formatting tags here
    http://www.codeguru.com/forum/misc.php?do=bbcode

    Get your free MS compiler here
    https://visualstudio.microsoft.com/vs

  4. #4
    Join Date
    Feb 2002
    Posts
    4,640

    Re: Anyone Else Experincing This problem?

    Quote Originally Posted by VictorN View Post
    It is not a C++ code.
    Well, it could be... "UserProperties" could be a bool; "True" could be typedefed to "true"; "User_Login_Form2" could be an object (if there were underscores). But, I wouldn't expect a crash. Maybe a syntax error because of the lack of ';'.

    Viggy

  5. #5
    Join Date
    Apr 2012
    Location
    STL
    Posts
    12

    Re: Anyone Else Experincing This problem?

    Quote Originally Posted by MrViggy View Post
    Well, it could be... "UserProperties" could be a bool; "True" could be typedefed to "true"; "User_Login_Form2" could be an object (if there were underscores). But, I wouldn't expect a crash. Maybe a syntax error because of the lack of ';'.

    Viggy
    Tried that, it froze when i used this code T_T
    I don't under stand what is happening. I'm trying to take my program
    from Visual Basic to Visual C++ cause I'm alot better at C++ and The
    Coding is a little easier for me. I don't have any idea why but honestly.
    I tried everything I googled, results came up with no errors, its just kinda annoying ... I asked my Visual Basic / Visual C++ teachers and neither one of them knew what I should do -.-

  6. #6
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: Anyone Else Experincing This problem?

    Quote Originally Posted by MrViggy View Post
    Well, it could be... "UserProperties" could be a bool; "True" could be typedefed to "true"; "User_Login_Form2" could be an object (if there were underscores). But, I wouldn't expect a crash. Maybe a syntax error because of the lack of ';'.

    Viggy
    Then would we also expect to besomethig like
    Code:
    #define True true;
    ...
    and so on?
    Victor Nijegorodov

  7. #7
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: Anyone Else Experincing This problem?

    Quote Originally Posted by Se7en_Gamerz View Post
    Tried that, it froze when i used this code T_T
    I don't under stand what is happening. I'm trying to take my program
    from Visual Basic to Visual C++ cause I'm alot better at C++ and The
    Coding is a little easier for me. ...
    Then why did you post the this Forum which is
    Visual C++ Bugs & Fixes Share bugs and fixes for source code on this site. Also use this to share bugs/fixes in the various class libraries etc. of use to VC++ developers. This is NOT for general programming questions.
    And being "alot better at C++" must mean that you know about semicolons...
    Victor Nijegorodov

  8. #8
    Join Date
    Feb 2002
    Posts
    4,640

    Re: Anyone Else Experincing This problem?

    Quote Originally Posted by VictorN View Post
    Then would we also expect to besomethig like
    Code:
    #define True true;
    ...
    and so on?


    I knew a guy that had his programming background in PASCAL. As such, all of his C files began with:
    Code:
    #define BEGIN {
    #define END }
    Talk about going crosseyed while debugging...

    Viggy

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured