ContactsmQuery: Cannot modify a read-only dataset ContactsDB
Looking in sources i found that it is in this part:
unit pfgPalmSyncComponent;
...
function TpfgPalmSyncComponent.SyncFast:
...
LocalDataSet.Open;
//
pfgPalmRemoteTable.First;
while not pfgPalmRemoteTable.eof do
begin
SyncYieldCycles(1);
if FOnFindLocalRecordID(self, pfgPalmRemoteTable.Fields.RecordID) then
begin
compare_and_act(0);
ShowMessage('compar y actu');
pfgPalmRemoteTable.next;
end
else
begin
if not isdeleted(pfgPalmRemoteTable.fields.Flags) then
begin
LocalDataSet.Append; // HERE
I dont understand, try a Append in LOCAL TABLE and the error message is in REMOTE TABLE (ContactsDB), beside the respective property in the component pfgPalmRemoteTable1 is ReadOnly : False, and the atributte in the PALM table is not checked in ReadOnly
Can you help me please?
(my english is poor, excuse me please)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'd suspect at a guess the problem is that you're using a query component, with the synchronisation component set to bi-directional synchronisation. By default, queries don't allow their contents to be modified, so when it tries to append a record to the local dataset, the query component throws an error.
You have two options. Firstly, query components can be set to allow updates. Or, you may be able to set the synchronisation component to only do uni-directional synchronisation. I'm not sure the exact details in either case, but hopefully it'll give you enough to fix your error.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The HostSync send me it message:
ContactsmQuery: Cannot modify a read-only dataset ContactsDB
Looking in sources i found that it is in this part:
unit pfgPalmSyncComponent;
...
function TpfgPalmSyncComponent.SyncFast:
...
LocalDataSet.Open;
//
pfgPalmRemoteTable.First;
while not pfgPalmRemoteTable.eof do
begin
SyncYieldCycles(1);
if FOnFindLocalRecordID(self, pfgPalmRemoteTable.Fields.RecordID) then
begin
compare_and_act(0);
ShowMessage('compar y actu');
pfgPalmRemoteTable.next;
end
else
begin
if not isdeleted(pfgPalmRemoteTable.fields.Flags) then
begin
LocalDataSet.Append; // HERE
I dont understand, try a Append in LOCAL TABLE and the error message is in REMOTE TABLE (ContactsDB), beside the respective property in the component pfgPalmRemoteTable1 is ReadOnly : False, and the atributte in the PALM table is not checked in ReadOnly
Can you help me please?
(my english is poor, excuse me please)
I'd suspect at a guess the problem is that you're using a query component, with the synchronisation component set to bi-directional synchronisation. By default, queries don't allow their contents to be modified, so when it tries to append a record to the local dataset, the query component throws an error.
You have two options. Firstly, query components can be set to allow updates. Or, you may be able to set the synchronisation component to only do uni-directional synchronisation. I'm not sure the exact details in either case, but hopefully it'll give you enough to fix your error.
Paul:
Excuse me, i dont make sure the property "RequestLive" is set to true in the mQuery component !!!
i set it to true and "eureka"
Thanks very much !!!!
Roberto