Re: VS2005 ArgumentException with GetString

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Resource file format has changed with VS2005 so make sure your original resx
went through the upgrade wizard and not just added:
http://www.danielmoth.com/Blog/2005/08/resx-compatibility-for-smart-device.html

Also note that there is a new ResourceManager class you can use with VS2005
projects... autogenerated for you giving you compile time checking of
resource names you use. I refer to that and provide links in the 3rd para
here:
http://www.danielmoth.com/Blog/2005/05/my-project-properties.html

You can check the full resource names by using in debug:
Assembly.GetExecutingAssembly().GetManifestResourceNames()

If you are still having problems, please post a full repro...

Cheers
Daniel
--
http://www.danielmoth.com/Blog/

"MikeB" <mboonept@xxxxxxxxx> wrote in message
news:OlWp9T8AGHA.2356@xxxxxxxxxxxxxxxxxxxxxxx
> Hello,
>
> I have a compact framework project that was built in VS2003 and I'm trying
> to now use that project in VS2005. It seemed to import OK, compiles, but
> I'm getting "ArgumentException was unhandled" on this line of code:
>
> Me.TableView1.Text = rm.GetString("Tables")
>
> I don't know where to start, as there are no such problems with the same
> code in VS2003. Here's my initialization of the
> System.Resources.ResourceManager rm:
>
> rm = New
> System.Resources.ResourceManager("My_Project.Strings",System.Reflection.Assembly.GetExecutingAssembly())
>
> My file Strings.resx seems to be there, and it does have an entry called
> "Tables". Thank you for any suggestions you might have.
>
> Mike B.
>


.



Relevant Pages

  • Re: VS2005 ArgumentException with GetString
    ... > Resource file format has changed with VS2005 so make sure your original ... > resx went through the upgrade wizard and not just added: ... > of resource names you use. ... >> Mike B. ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: Resource file format
    ... >> I want to create a program that imports an excel file into a resource ... >> description of the resource file format? ...
    (microsoft.public.vb.general.discussion)
  • Re: Pros/Cons Kde vs Gnome?
    ... The resource ... Just let me have a top level dot file in my home ... Perhaps this can be taken care of at compile time, ... the time to hassle with that. ...
    (Debian-User)
  • Re: How to include an external (binary) file into a java program at compile (!) time ???
    ... One way to archieve resource bundling at compile time is to package the ... > I think of a variable declaration like: ... > internal part of the one and only java class. ...
    (comp.lang.java.help)
  • Re: Use of resource images
    ... I made sure to set the set the Build Option of the images to 'Embedded ... If you are using VB 2005/2008, you can access the resource via ... access to resources is bound at compile time and thus type-checked. ... M S Herfried K. Wagner ...
    (microsoft.public.dotnet.languages.vb)