No Source Code Error

  • Thread starter Thread starter Doug Bell
  • Start date Start date
D

Doug Bell

Hi,

I have been debugging a new VB.Net Application and today, I have been
getting an error that I have not seen before

This error is now appearing on a line with the following code:
lnGUID = lnGUID * 1000 + DatePart(DateInterval.DayOfYear, Now)

this line runs fine in another App. The Error that I am getting is:
"There is no source code available for the current location"

I do not understand how the Microsoft explanation for this error applies to
the code that I have?

Any help appreciated

Doug
 
Are you running in Debug mode (F5)? If so, what result are you getting when
not running in Debug mode (CTRL+F5)?
 
Doug Bell said:
I have been debugging a new VB.Net Application and today, I have been
getting an error that I have not seen before

This error is now appearing on a line with the following code:
lnGUID = lnGUID * 1000 + DatePart(DateInterval.DayOfYear, Now)

this line runs fine in another App. The Error that I am getting is:
"There is no source code available for the current location"

Post the complete error message. Maybe the error is occuring inside the
'DatePart' function and you have configured "Debug" -> "Exceptions..." to
break even if the exception is being handled.
 
That is the complete Error message. No Title or other text.

If I breake the line up adding:
dim datMyDate as Date = Now
Dim i as integer
i=DatePart(DateInterval.DayOfYear, datMyDate )
then it errors on that line
 
Hmm, the code works fine here. The message "There is no source code
available for the current location", means that the debugger is trying to
show the disassembly window. How is your project configured, Debug or
Release and how are you running it?
 
Yes running in Debug

Ctl + F5
Seems to run through that line (based on setting MsgBoxes)

I need to step through in Debug to fix other issues.

Why would it run through using Start without Debugging but not when just
Start?

Doug
 
Have yout tried deleting both the bin and obj folders, and the rebuild your
solution before debugging (F5)?
 
CT Thanks,

It is configured as Debug
I run have a main form that loads and enables a timer
At configurable preset intervals it calls a Class.

I am trying to debug the code in the class so consequently stepping through
it.

I run it by clicking the Start button next to the Debug Combo on the
toolbar.

And have set various BreakPoints.

Doug
 
CT,
Thanks
Deleting bin and obj folders and building the Solution has completely solved
the problem.

Doug
 
Back
Top