469,356 Members | 2,555 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,356 developers. It's quick & easy.

Problem using Windows Resource Localization Editor (WinRes.exe)

Hi Everyone,

I am having some difficulty in using the Windows Resource Localization
Editor (WinRes.exe) on several Visual Basic .NET forms (.resx files) in two
different projects. The editor gives an error when loading the .resx files.

When attempting to load a .resx file using WinRes under Visual Studio .NET
2003, the following error is displayed in the client area of the editor:

"An error occurred while loading the document. Fix the error, and then try
loading the document again. The error message follows: Object reference
not set to an instance of an object."

When attempting to load the same .resx file using WinRes under Visual Studio
2005, the following errors are displayed in the status area of the tool:

"Warning: Failed to load the type for component 'dsCustomer'.
Warning: Failed to load the type for component 'Titles1'.
Error - The data name 'dsCustomer' is invalid. Valid data names must be of
the form 'Component.Property'.
Error - The data name 'dsCustomer' is invalid. Valid data names must be of
the form 'Component.Property'.
Error - The data name 'Titles1' is invalid. Valid data names must be of the
form 'Component.Property'.
Error - The data name 'Titles1' is invalid. Valid data names must be of the
form 'Component.Property'."

The 'dsCustomer' and 'Titles1' are data sets (DataSet objects). It seems
that all forms that have data sets have this issue with the localization
editor.

Does anyone have an idea how to solve or work around this problem? I need a
solution using Visual Studio 2003, not VS 2005.

Thank You.

Nov 22 '05 #1
5 6469
Hi Bill,

What verison of VS.NET are these .resx files build from? As a general rule,
you should use the version of Winres.exe that was released with the .NET
Framework you are using to create the application. Here is a link for your
reference.

http://msdn2.microsoft.com/en-us/library/8bxdx003.aspx

If you still cannot open that file, could you attach an resx file that can
reproduce the error?

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

Nov 22 '05 #2
Hi Bill,

From the error message, it seems that the 'dsCustomer' reference is not
pointing to any valid object. As opening the resx file requires to open the
form file together, please do check if there is any error in the form file.
Try to rebuild the windows form project to see if there is any compile
error.

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

Nov 22 '05 #3
Hi Bill,

Thank you very much for your repro code. With this code, I did more
research and found it is a known issue in VS.NET. the DataSets are not
serialized correctly in localized Forms. In this case, I suggest you try to
contact Microsoft PSS for a workaround. Please check the following link for
the contact information:

http://support.microsoft.com/default...;OfferProPhone

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

Nov 22 '05 #4
Kevin,

Thanks for your feedback. Since Microsoft knows about this issue, I assume
they don't have to be reminded of it. I'm curious though that I could not
find anything in Knowledge Base about it.

I did some digging and found that 3rd party translation tools don't have the
same issue and actually present a cleaner mechanism for translation by not
exposing all of the resource properties. The other workaround is to
programmatically create the required DataSets and links to the forms --
assuming that there is no other issue with WinRes.

Bill
"Kevin Yu [MSFT]" <v-****@online.microsoft.com> wrote in message
news:Za**************@TK2MSFTNGXA02.phx.gbl...
Hi Bill,

Thank you very much for your repro code. With this code, I did more
research and found it is a known issue in VS.NET. the DataSets are not
serialized correctly in localized Forms. In this case, I suggest you try to
contact Microsoft PSS for a workaround. Please check the following link for
the contact information:

http://support.microsoft.com/default...;OfferProPhone

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."
Nov 22 '05 #5
Hi Bill,

Nice to hear that you have got a workaround. I'm sorry for the
inconvenience.

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."

Nov 22 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Joseph Geretz | last post: by
3 posts views Thread by Barry | last post: by
5 posts views Thread by ma | last post: by
2 posts views Thread by Dave Brown | last post: by
1 post views Thread by CARIGAR | last post: by
1 post views Thread by Marylou17 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.