VB.Net 2003 Very Strange Behavior

  • Thread starter Thread starter GG
  • Start date Start date
G

GG

VB.Net Standard 2003 , Win2k Pro All Patches & Updates

I have line numbers turned on. When I run this code it stops at line 63 as
expected and when I step over each line, they execute in sequence as
expected 64,65,66,67 etc. STRANGE thing is when I hit the enter key at the
end of a line (63 as an example) and insert a few blank lines. Lines 64 - 67
are moved to say 70 - 73. When I restart the app it still stops at 63
however when I step through the code it stops at 64 , not at 70 as expected.
I then moved the code back but swapped lines of code( 67's code is moved to
64 and 64 code moves to 67). App still stops at 63 but the code executed at
line 64 is not 'CheckFileExistance' but the original code
'GApplicationIsRunning'.

62 Public Sub main()
<Brk Pt>63 Debug.Write(Date.Now)
64 If GApplicationIsRunning() Then End
65 If MS_AccessIsRunning() = False Then End
66 If CheckFileExistance(CurrentDB) = False Then End
67 If CheckFileExistance(Config) = False Then End
68
69
70 ***** Move code to here, 64 - 69 become blank lines*****
71
72
73
74

I have rebooted the computer and reloaded the app several times but the
problem remains. I guess that I will have to reinstall VB.

I am curious if anyone else has seen this. Could it be that garbage has
become imbedded in the source?
 
GG,

Sounds like your build configuration is set not to do a build every time you
run the project, therefore the code in your code window is not the code that
is actually running. Check your build configuration (Build -> Configuration
Manager) and check that the 'Build' option is ticked for your project which
will ensure that a build is done whenever you run the project.

Gary
 
Back
Top