DataAdapter creation problems - VS 2005 - WebServices

G

Guest

I create a simple DATAADAPTER in a webservice project. It creates the
UPDATE, INSERT, DELETE commands for me - no problem.

In vS2005 it creates these commands as RESOURCES in the RESX file (i.e.
strings). The problem is whenever I try to test the webservice I get:

System.Resources.MissingManifestResourceException: Could not find any
resources appropriate for the specified culture or the neutral culture. Make
sure "WS_SComm2.resources" was correctly embedded or linked into assembly
"App_Code" at compile time, or that all the satellite assemblies required are
loadable and fully signed.
at System.Resources.ResourceManager.InternalGetResourceSet(CultureInfo
culture, Boolean createIfNotExists, Boolean tryParents)
at System.Resources.ResourceManager.InternalGetResourceSet(CultureInfo
culture, Boolean createIfNotExists, Boolean tryParents)
at System.Resources.ResourceManager.InternalGetResourceSet(CultureInfo
culture, Boolean createIfNotExists, Boolean tryParents)
at System.Resources.ResourceManager.GetString(String name, CultureInfo
culture)
at System.Resources.ResourceManager.GetString(String name)
at WS_SComm2.InitializeComponent()
at WS_SComm2..ctor()

I've tried restarting, moving my resx files, I've even created entire new
blank applications - and then i would just set up one dataadapter and i still
get this error. It seems like the application can't find these resource
strings.

I am not doing anything special - I am just creating a dataadapter usine the
VS2005 IDE. In VS2003 this was a real easy process and everything worked
fine. I don't know how to get this to work! We literally have HUNDREDS of
these dataadapters with the embedded SQL statements. These things have to
work in VS2005. What's the deal - I am completely lost!

So in order to get my project done I am ripping out all of my dataadapters.
Shouldn't the resx file thing just work? I didn't have any of these troubles
in VS2003... Please help? What should I do?

Thanks!
 
G

Guest

Hi I wanted to post a solution to this in case anyone coming from VS 2003
runs into this same issue.

The trick is to abandon creating the dataadapter UPDATE, INSERT and DELETE
statements at DESIGN time and instead - create them at RUN TIME.

Look up the SQLCOMMANDBUILDER object in the .NET 2005 documentation. It
shows you how to use the object to dynamically re-create your UPDATE, INSERT
AND DELETE statements right before you execute the UPDATE METHOD on your
dataadapter...

....actually a very slick little solution...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top