EDN Admin
Well-known member
I have a project that has been developed on 3.5
As I need to use couple of compents that are for .NET4 I decided to upgrade the project.
I updated the version of all the .NET framework under Compile. Advanced compile and changed the Target Framework.
The next step has been to modify the App.config to add:
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
<
<span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small runtime<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small >
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
<
<span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small NetFx40_LegacySecurityPolicy<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#ff0000; font-size:small <span style="color:#ff0000; font-size:small <span style="color:#ff0000; font-size:small enabled<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small =<span style="font-size:small <span style="font-size:small "<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small true<span style="font-size:small <span style="font-size:small "<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small />
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
</
<span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small runtime<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small >
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
as I have some legacy calls: http://msdn.microsoft.com/en-us/library/ms130778(v=vs.100).aspx Load(AssemblyName, Evidence)
Now without ANY other change to the code the library is not able to access its own resources anymore.
Note that teh Resource.vb executes correctly
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
Dim
<span style="font-size:small <span style="font-size:small temp <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small As<span style="font-size:small <span style="font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small Global<span style="font-size:small <span style="font-size:small .System.Resources.<span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small ResourceManager<span style="font-size:small <span style="font-size:small =
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small New<span style="font-size:small <span style="font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small Global<span style="font-size:small <span style="font-size:small .System.Resources.<span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small ResourceManager<span style="font-size:small <span style="font-size:small (<span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small "library.Resources"<span style="font-size:small <span style="font-size:small ,
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small GetType<span style="font-size:small <span style="font-size:small (<span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small Resources<span style="font-size:small <span style="font-size:small ).Assembly)
<span style="font-size:small <span style="font-size:small
resourceMan = temp
but when I access the resources
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
Dim
<span style="font-size:small <span style="font-size:small sqlCommand
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small As<span style="font-size:small <span style="font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small String<span style="font-size:small <span style="font-size:small =
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small My<span style="font-size:small <span style="font-size:small .Resources.JobsDatabaseSQL_v1
<span style="font-size:small <span style="font-size:small <span style="font-size:small
I got an error: "library.resources" File not found
Its driving me nuts.
Ive tried to create a resx, to move there resource, to rebuild, to put resources from Friend to Public but nothing!
<
M.Savazzi
View the full article
As I need to use couple of compents that are for .NET4 I decided to upgrade the project.
I updated the version of all the .NET framework under Compile. Advanced compile and changed the Target Framework.
The next step has been to modify the App.config to add:
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
<
<span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small runtime<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small >
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
<
<span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small NetFx40_LegacySecurityPolicy<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#ff0000; font-size:small <span style="color:#ff0000; font-size:small <span style="color:#ff0000; font-size:small enabled<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small =<span style="font-size:small <span style="font-size:small "<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small true<span style="font-size:small <span style="font-size:small "<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small />
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
</
<span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small runtime<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small >
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
as I have some legacy calls: http://msdn.microsoft.com/en-us/library/ms130778(v=vs.100).aspx Load(AssemblyName, Evidence)
Now without ANY other change to the code the library is not able to access its own resources anymore.
Note that teh Resource.vb executes correctly
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
Dim
<span style="font-size:small <span style="font-size:small temp <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small As<span style="font-size:small <span style="font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small Global<span style="font-size:small <span style="font-size:small .System.Resources.<span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small ResourceManager<span style="font-size:small <span style="font-size:small =
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small New<span style="font-size:small <span style="font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small Global<span style="font-size:small <span style="font-size:small .System.Resources.<span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small ResourceManager<span style="font-size:small <span style="font-size:small (<span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small <span style="color:#a31515; font-size:small "library.Resources"<span style="font-size:small <span style="font-size:small ,
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small GetType<span style="font-size:small <span style="font-size:small (<span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small <span style="color:#2b91af; font-size:small Resources<span style="font-size:small <span style="font-size:small ).Assembly)
<span style="font-size:small <span style="font-size:small
resourceMan = temp
but when I access the resources
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small
Dim
<span style="font-size:small <span style="font-size:small sqlCommand
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small As<span style="font-size:small <span style="font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small String<span style="font-size:small <span style="font-size:small =
<span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small <span style="color:#0000ff; font-size:small My<span style="font-size:small <span style="font-size:small .Resources.JobsDatabaseSQL_v1
<span style="font-size:small <span style="font-size:small <span style="font-size:small
I got an error: "library.resources" File not found
Its driving me nuts.
Ive tried to create a resx, to move there resource, to rebuild, to put resources from Friend to Public but nothing!
<
M.Savazzi
View the full article