Question : Changing or retaining an update Parameter value in a gridview

This relates to the question I asked earlier and it really has me tearing my hair out :(
Using the gridview on this particular form, the user can enter/update notes and save the record or enter a complete date. If a complete date is entered, the priority changes to "PEND". If it is not entered, the priority remains unchanged.
What's happening is, if I access the record and just update the notes, the priority is set to null. If I enter the complete date, that field is updated but the priority is still set to null. What am I doing wrong? I thought I had the code-behind set up in the same way I did before. Also, do I need to add code to retain the original value of the priority if the user only enters/updates the notes?
I'm attaching my code and thanks in advance for any help.
Code Snippet:
1:
2:
3:
4:
5:
Protected Sub ToolDesignSqlDataSource_Updating(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.SqlDataSourceCommandEventArgs) Handles ToolDesignSqlDataSource.Updating
    If IsDate(e.Command.Parameters("@tool_design_complete_date")) Then
      e.Command.Parameters("@priority").Value = "PEND"
    End If
  End Sub

Answer : Changing or retaining an update Parameter value in a gridview

It has something to how this column is bounded
can you try using Bind instead of Eval:

           
             
           

         

Random Solutions  
 
programming4us programming4us