The following Sub stopped working after I upgraded to CDK 4.03:
-------------------------------------------------------------------
Sub SetFlag()
Dim bArray(0 To 1) As Byte

Set Adapter =3D DbQuery.OpenRecordDatabase
("CEPedSyn", "PDDirect.PDRecordAdapter")
If Adapter.RecordCount =3D 0 Then
    UniqueId =3D vbEmpty
Else
    Adapter.IterationIndex =3D 0
    Data =3D Adapter.ReadNext(Index, UniqueId, Category, Attributes)
End If
IntegerToBlob bArray, 0, 1
Adapter.Write UniqueId, 0, 0, bArray '<---ERROR OCCURS HERE!!!
Set Adapter =3D Nothing

End Sub
----------------------------------------------------------------
Public Sub IntegerToBlob(ByRef vData As Variant, Offset As Long,
InData As Integer)
Dim ByteArr2 As tByteArr2
Dim MyInteger As tInteger
Dim Counter As Integer
  MyInteger.VarInteger =3D InData
  LSet ByteArr2 =3D MyInteger
  For Counter =3D 0 To 1
    vData(Offset + Counter) =3D ByteArr2.ByteArr(1 - Counter)
  Next Counter
End Sub
-----------------------------------------------------------------

When executing the Adapter.Write method, I receive this message from
windows:

Application Error : the instruction at "0x00000000" made reference to
memory at "0x00000000". Memory could not be read.

And this message from VB:
Run-time error '10':
This array is fixed or temporarily locked.

I=B4m syncing with POSE 3.5, emulating a Palm Vx.


___________________________
Ricardo Beltr=E3o
Recife - PE
Brazil



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to