Hello Brad,
I'm a bit confused about the code you provided, based on your code
fragment, I can get the following things:
1. You want to update database records in ASP.NET web page(though your
thread title is "insert problem").
2. In your ASP.NET page's server-code block, instead of using the
"UpdateCommand" property, you're using the "SelectCommand" property to
store some UPDATE T-SQL statement. Also, DataAdapter is used for updating
data through DataSet/DataTable.
So if you just want to execute a single select/update/delete SQL
command(without using dataset/datatable), you can just call
SqlCommand.ExecuteXXX method instead of using DataAdapter.
Here are some articles introducing data access in ASP.NET 2.0:
#Performing Data Access
http://www.asp.net/QuickStart/aspnet...a/default.aspx
Here is a msdn reference describe supported means to update database:
#How to: Update Records in a Database
http://msdn2.microsoft.com/en-us/library/ms233819.aspx
In addition, I notice that you use repeater control to display data in
page, will your update statement pickup udate paramters from the repeater
control?
Please feel free to provide some further background or code logic of your
web page so that we can help have a look and provide some futher ideas.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.