Bug in VS 2003?

I recently posted regarding a TypeLoad exception in Microsoft.VisualBasic

http://forums.microsoft.com/msdn/ShowPost.aspx PostID=113878

It appears that my findings have highlighted a bug in VS2003 is this the case

Also my work around seems inconsistent sometimes its OK other times it doesn't have the desired effect. Any ideas

Thanks in advance.


Answer this question

Bug in VS 2003?

  • bishoycom

    I have managed to repro the problem in a small project without any references...

    Would you like me to send you the project

    Thanks

    Glynn

  • IK81

    The reply you got there still stands. When you create a new project make sure you are creating a Smart Device Project. Make sure you only reference netcf assemblies and not full framework ones (your own, msft's or 3rd party ones). Do not use the vb upgrade code utility since it will bring desktop assemblies in your project.

    Bottom line, the typeloadexception you are seeing means that one way or another you are getting the desktop version of the VB.dll in your project.

    Cheers
    Daniel



  • dipak22101980

    Building a new project and copying the objects in does work but the problem will arise in the new project.

    What are the configuration files you mention

  • Rburkhal

    That would be project files in the project folder. Extension is something like .*proj.
    By the way, does it repros on fresh empty project without adding any references

  • Tony - Memphis

    I doubt VS is adding references to wrong assemblies on it's own, so it must have been added at some point and persisted to the project configuration files. Looks like this configuration is not updated and you're getting bad reference back every time project is reloaded.

    I would suggest looking into project configuration files to see if reference is present. Another way may be to start a fresh project from the same files.



  • Ohad Ninio

    Sure. Please remove "online" from my e-mail. Also, please rename VB files to .txt and pack it all with normal zip, that would let it pass antivirus filters. Thanks.

  • nantunes82

    Thanks Daniel for the response,

    This issue is driving me mad....

    How can I be getting a desktop reference when as you say the project was created as a Smart Device Project and the only external reference is OpenNetCF. Serialization

    Also why does shutting VS down and restarting cause the exception to occur (I've taken to hibernating my development machine just to be safe!!)

    And why does my workaround cure the problem sometimes

    Cheers

    Glynn


  • Bug in VS 2003?