By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,161 Members | 2,002 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,161 IT Pros & Developers. It's quick & easy.

SQLDataSource Configuration not allowing Update, Delete or Insert

P: n/a
I created a new table in Visual Web Developer for SQL Server Express
2005. I created a 'gridview' by dragging the table onto an empty web
form in Visual Developer Express.

Clicked on the smart tag 'configure data source'. When I click Advanced
should see
the Generate Insert, Update and Delete statements check box but it is
greyed
out. It isn't in all the video tutorials I have watched.

Tried to repeat with various new tables, but it always gives the same
result.

Activated the edit button on GridView and it allowed me to edit the
record, but it will not update as DataSource not configured for UPDATE.

What can I be doing wrong ? I am guessing it is a property or a
permission, but permissions not normally a problem in windows

Help my Test Host expires on Microsoft tomorrow and I can not even get
to edit an existing table at local level, never mind test how to upload
and execute on a real host.

Any help appreciated

Richard

Apr 28 '06 #1
Share this Question
Share on Google+
3 Replies


P: n/a
If it is any help, the same problem occurs with an AccessDataSource !!!

Apr 28 '06 #2

P: n/a
The usual reason for this is that you have not included the primary key in
the Select statement so it cannot autonatically generate corresponding
Insert, Update and Delete statements.

You can still do it all yourself though.

"mosscliffe" wrote:
I created a new table in Visual Web Developer for SQL Server Express
2005. I created a 'gridview' by dragging the table onto an empty web
form in Visual Developer Express.

Clicked on the smart tag 'configure data source'. When I click Advanced
should see
the Generate Insert, Update and Delete statements check box but it is
greyed
out. It isn't in all the video tutorials I have watched.

Tried to repeat with various new tables, but it always gives the same
result.

Activated the edit button on GridView and it allowed me to edit the
record, but it will not update as DataSource not configured for UPDATE.

What can I be doing wrong ? I am guessing it is a property or a
permission, but permissions not normally a problem in windows

Help my Test Host expires on Microsoft tomorrow and I can not even get
to edit an existing table at local level, never mind test how to upload
and execute on a real host.

Any help appreciated

Richard

Apr 28 '06 #3

P: n/a
Genius - I did not even have a primary key specified - now rectified
and all working.

Many, many thanks

Richard

Apr 28 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.