bjoernscher 0 Newbie Poster

First of all Hello to this forum. I have the follwoing problem.

When I am runnig an UpdateCommand with codebehind :
sqldatasource1.Update() I get the following error. (I want this command to CompareAllValues)

You have specified that your update command compares all values on SqlDataSource 'SqlDataSource1', but the dictionary passed in for oldValues is empty. Pass in a valid dictionary for update or change your mode to OverwriteChanges.

My Code looks like this :

<asp:SqlDataSource ID="SqlDataSource1" runat="server"            ConnectionString="<%$ ConnectionStrings:ConnectionString2 %>"
            OldValuesParameterFormatString="original_{0}" 
            SelectCommand="" 
            ConflictDetection="CompareAllValues" 
            DeleteCommand="" 
            InsertCommand="" 
            UpdateCommand="UPDATE Hauptthema SET Categories = @Categories, Subject = @Subject, Body = @Body, filepath = @filepath 
FROM Hauptthema INNER JOIN Categories ON Hauptthema.Categories = Categories.CategoryID WHERE (Hauptthema.Categories = @original_Categories) 
AND (Hauptthema.ThreadID = @original_ThreadID) AND (Hauptthema.Body = @original_Body) AND (Hauptthema.Subject = @original_Subject) 
AND (Hauptthema.filepath = @original_filepath)"
            OnUpdated="OnUpdatedHandler">

 <UpdateParameters>
         <asp:Parameter Name="Categories" ConvertEmptyStringToNull="False" />
         <asp:Parameter Name="Subject" ConvertEmptyStringToNull="False" />
         <asp:Parameter Name="Body" ConvertEmptyStringToNull="False" />
         <asp:Parameter Name="filepath" ConvertEmptyStringToNull="False" />
         <asp:Parameter Name="original_ThreadID" />
         <asp:Parameter Name="original_Body" ConvertEmptyStringToNull="False" />
       <asp:Parameter Name="original_Subject" ConvertEmptyStringToNull="False" />
       <asp:Parameter Name="original_filepath" ConvertEmptyStringToNull="False" />
  </UpdateParameters>

Any suggestions to help me ?
I would like to keep "CompareAllValues" activated cause this database will be in use by many people.