This project is read-only.

System.ArgumentException with Blob data

Dec 19, 2014 at 10:52 AM
I'am developing a App with blob sqlile DB. But my insert statement error:

System.ArgumentException: Value does not fall within the expected range.

error with PrepareStatementAsync method.

My code:
String command = "INSERT INTO Fleet (fleetId,enterpriseId,code,data,searchText) VALUES(?, ?, ?, ?, ?)";
 using (var insertStatement = await database.PrepareStatementAsync(command))
                    foreach (Fleet item in list)
               = SQLiteUtil.encode(convertDataToBytes(item));

                        insertStatement.BindIntParameterAt(1, item.fleetId);
                        insertStatement.BindIntParameterAt(2, item.enterpriseId);
                        insertStatement.BindTextParameterAt(3, item.code);
                        insertStatement.BindTextParameterAt(5, item.searchText);
                        await insertStatement.StepAsync();
Dec 22, 2014 at 2:50 AM
Edited Dec 22, 2014 at 10:36 AM
I have fixed it.

The cause of bug is my thread control in WP.
Jan 22, 2015 at 3:50 PM
Can you explain the solution please ? I have the same problem.