Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hello

 

Firstly if i have placed this into the wrong forum i do apologise but I am not sure what this error is referring to:

 

"An unhandled exception of type 'System.NullReferenceException' occurred in Unknown Module.

 

Additional information: Object reference not set to an instance of an object."

 

If i choose 'Break' on the message box it then says:

 

"There is no source code available for the current location'

 

This error is shown when I try to run the application (press F5 in VB.net).

 

If i create a brand new project and don't add any controla or anything, then this error will appear. If I add a label and a picture, the error appears, BUT if I try and run a previous project that I know works it doesn't appear - it only seems to happen on my new projects - does anyone know what the error means and how I can solve it. By the way - I haven't deleted or added any code whatsoever.

 

Thanks

Visit: VBSourceSeek - The VB.NET sourcecode library

 

 

"A mere friend will agree with you, but a real friend will argue."
Posted

Just a thought.... It usally happens when the source code and binary are out of sync (via the debugging files)

 

In your project properties, are you still compiling it automatically, or does it run without being compiled?

Howzit??
Posted

Hi thanks for the replies - i've uninstalled and re-installed and that hasn't changed anything, for the other reply i'm not really sure what you mean.

 

I have looked on MSDN and apparently its caused when i'm trying to unreference an unavailable reference but surely if I haven't even added any code to a project this wouldn't occur

 

Any more help would be greatly appreciated

Visit: VBSourceSeek - The VB.NET sourcecode library

 

 

"A mere friend will agree with you, but a real friend will argue."
Posted

Sorry man... now that I read my own reply, I can see it not that clear.. :)

 

If you go to your solution properties page (right click on solution and click on Properties) and click on Configuration Properties, you will see a grid. Make sure that the Column (Build) is ticked for all your projects.

If it's not ticked, the project isn't compiled automatically by vs, and you dll and source will be out of sync.

 

Hope its more clear now...

Cheers

Howzit??
  • 1 year later...
Posted

Well, first you'll have to uninstall and reinstall VStudio a few more times and then install more RAM, get a faster processor and upgrate to the latest version of Windows.

 

Just kidding!

 

I actually ran into this same exact problem, and the solution was closer to what cywizz had to say.

 

Go into the solution properties again, and make sure the value in the "Configuration" column is set to "Debug". Then recompile your project and try again.

 

Additionally, I'm just talking about the "There is no source code available for the current location" error, not the NullReferenceException. But if you are able to debug your project after this fix, you should be able to fix the problem.

 

Oh yeah, and make sure your Machine Debug Manager Service isn't disabled or anything.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...