Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2006-04-26 : 09:30:38
|
Marcus writes "I have 2 gridview controls(using stored procedures) to display customer names and details ect...). the other gridview shows what data is needed in thier jobs.(1 order = multiple machines, materials, thickness)My Gridviews can display all that we need, (join on CUSTOMER table, MATTER table)My question is, I have an SQL 2000 statement(usp, that works in the sql builder) that needs to update these dropdown listsProgrammed, DateTime,Date_Due, DateTimeSize of the job - 15min, 30min, 1hour, 2 hours, etc..(vchar)machine.. that cut it(vchar)- listcontrolprogrammers name....(vchar)(these are all dropwdownlist controls, outside of the gridview)...and are the only fields that need to be updatedI would like to update the all dropdown and list control fields with a submit button using a user_stored_procedure(usp_matter_view_update)I only want to update the dropdown and list control fields.I need to be able to click on the submit button and have my stored_procedure run, or some way to update my data with an on click event.Hope this makes scence....Using ASP.Net 2.0, SQL Server 2000, VWD.ThanksMarcus" |
|
twhelan1
Yak Posting Veteran
71 Posts |
Posted - 2006-04-26 : 10:29:40
|
You want to update the values in the dropdown list or you want the data in the database to be updated?I'm guessing the database but that isn't really clear from your question, so here goes:You need to create a stored procedure with the parameters needed for your update query. If you're having trouble with that you need to post your query, table definitions and some sample data so we can help you. In your ASP code, you need to create an OnClick handler for the button then add code to call the procedure you just created. You can use an ADO.Net command object to do the execute. Without knowing a little more details about what exactly you're having problems with (is it the SQL, is it the ASP code, is it creating a stored procedure?) it's hard to give a more detailed answer, but that's a starting point at least.~Travis |
 |
|
|
|
|
|
|