Tech Off Post

Single Post Permalink

View Thread: PLEASE HELP!!! FormatException?
  • User profile image
    qwert231

    I'm getting this error when I am firing a command, and have no idea what it means. There are 2 parameters filled in the SQL command, the ID field, and RowState which equals Deleted. Both parameters are filled properly. There are other parameters for this command, but they are not needed when this error fires, so they are Nothing.

    I have no idea what string or boolean it is talking about!!! And it's really bugging me.

    System.FormatException: String was not recognized as a valid Boolean.
       at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
       at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()

      
    Here's the code that errors:

    Me.cmdProductsUpdate.ExecuteNonQuery()

    If you need more details I can provide them. But I have no idea what you would need except for the SQL.