473,386 Members | 1,598 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Generated Code Confused

I have a project with many DataAdapters and Datasets generated via the
Wizard. DAs and been deleted and more DAs have been added. The Generated
code has become somewhat of a mess.

Now when I try to add a new SQLDataAdapter I get an error box saying that
there is already a SQLSelectCommand12. I notice that DAs have different
numbers for their Select, Insert, Delete commands too.

What is the best way in which to fix this mess?
Thanks,
G
Nov 18 '05 #1
3 889
"G. Dean Blake" <De**@nospam.com> wrote in message
news:uY**************@TK2MSFTNGP11.phx.gbl...
I have a project with many DataAdapters and Datasets generated via the
Wizard. DAs and been deleted and more DAs have been added. The Generated
code has become somewhat of a mess.

Now when I try to add a new SQLDataAdapter I get an error box saying that
there is already a SQLSelectCommand12. I notice that DAs have different
numbers for their Select, Insert, Delete commands too.

What is the best way in which to fix this mess?


Give them all real names. I use things like daCustomers, dvCustomers and
dsNorthwind, conNorthwind, cmdselCustomers, cmddelCustomers.
--
John Saunders
johnwsaundersiii at hotmail
Nov 18 '05 #2
Sorry, I wasn't clear enough...

I give my dataAdapters meaningful names along with my datasets. VS.NET then
generates command objects and names them things like SqlSelectCommand1,
SqlInsertCommand1, SqlUpdatecommand14, etc. That's what's getting
clobbered.
G

"John Saunders" <jo**************@notcoldmail.com> wrote in message
news:%2***************@TK2MSFTNGP10.phx.gbl...
"G. Dean Blake" <De**@nospam.com> wrote in message
news:uY**************@TK2MSFTNGP11.phx.gbl...
I have a project with many DataAdapters and Datasets generated via the
Wizard. DAs and been deleted and more DAs have been added. The Generated code has become somewhat of a mess.

Now when I try to add a new SQLDataAdapter I get an error box saying that there is already a SQLSelectCommand12. I notice that DAs have different
numbers for their Select, Insert, Delete commands too.

What is the best way in which to fix this mess?


Give them all real names. I use things like daCustomers, dvCustomers and
dsNorthwind, conNorthwind, cmdselCustomers, cmddelCustomers.
--
John Saunders
johnwsaundersiii at hotmail

Nov 18 '05 #3
"G. Dean Blake" <De**@nospam.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Sorry, I wasn't clear enough...

I give my dataAdapters meaningful names along with my datasets. VS.NET then generates command objects and names them things like SqlSelectCommand1,
SqlInsertCommand1, SqlUpdatecommand14, etc. That's what's getting
clobbered.
My answer is the same. Give them real names.
--
John Saunders
johnwsaundersiii at hotmail

"John Saunders" <jo**************@notcoldmail.com> wrote in message
news:%2***************@TK2MSFTNGP10.phx.gbl...
"G. Dean Blake" <De**@nospam.com> wrote in message
news:uY**************@TK2MSFTNGP11.phx.gbl...
I have a project with many DataAdapters and Datasets generated via the
Wizard. DAs and been deleted and more DAs have been added. The Generated code has become somewhat of a mess.

Now when I try to add a new SQLDataAdapter I get an error box saying that there is already a SQLSelectCommand12. I notice that DAs have different numbers for their Select, Insert, Delete commands too.

What is the best way in which to fix this mess?


Give them all real names. I use things like daCustomers, dvCustomers and
dsNorthwind, conNorthwind, cmdselCustomers, cmddelCustomers.
--
John Saunders
johnwsaundersiii at hotmail


Nov 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Martin Kofahl | last post by:
Hello, I'm slightly confused with the passthru() command. The program I call writes html headers itself. However, passthru() makes apache sending some generated headers first. There's no fault...
4
by: Irmen de Jong | last post by:
Hello, I don't understand why the following doesn't work. What I want to do is dynamically import some generated Python code and I'm doing this using compile and exec'ing it in the dict of a new...
0
by: Jimmy Cerra | last post by:
I recently came up with a cool little stylesheet for definition lists. There is a small demostration for the impatient . I hope this helps someone. Here's how I did it. Definition lists are...
6
by: Dave | last post by:
Hello all, Consider this function template definition: template<typename T> void foo(T) {} If foo is never called, this template will never be instantiated. Now consider this explicit...
7
by: Studio P.M. | last post by:
Dear colleagues, Does anyone have an idea where I could find precise and detailed explanation of each and every statement of the following “Web Form Designer generated code”: #region Web...
6
by: dark.peony | last post by:
Hi, (--1--) I'm trying to find a way to jump to a link (<a href="ref"></a>) in a page that is generated with javascript. The source view of the page only shows the javascript methods. The...
2
by: David Jessee | last post by:
I have a schema that I've used to generate a class structure vis the xsd.exe utility. I'm having to manually validate the resultant XML since the resultant document is not necessarily compliant...
12
by: vbnewbie | last post by:
I am having problems accessing properties of dynamically generated objects in VB2005. Can someone please help? In a nutshell: My app creates an equal number of checkboxes and labels that share the...
7
by: The Mad Ape | last post by:
Hi I have code to programatically create a label. It works but when I try to call a sub to create a tooltip it does not work. I do not get an error so have no idea what it wrong. Please review...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.