[Gambas-user] Result object

tobias tobiasboe1 at ...20...
Wed Nov 17 14:34:34 CET 2010


Charlie Reinl schrieb:
> Am Dienstag, den 16.11.2010, 21:44 +0100 schrieb tobias:
>> Charlie Reinl schrieb:
>>> Am Montag, den 15.11.2010, 19:56 +0100 schrieb tobias:
>>>> hi,
>>>> i have again another question about the result object...
>>>> when i do:
>>>> hResult = hConnection.Edit("table")
>>>>
>>>> i get a read/write result, i can move through the elements and edit 
>>>> their fields, e.g.
>>>> hResult.MoveTo(2)
>>>> hResult["id"] = 10
>>>>
>>>> right?
>>>> but where do i have to move to to add one (or more) new element/s??
>>>>
>>> Salut Tobias,
>>>
>>> hResult = hConnection.Create("table")
>>>
>>> should to the job
>>>
>> this maybe works but in theory i can't imagine why...?
>>
> Sorry, I can't follow you.
> 
> EDIT reads something which can be handeled read/write afterwards.
> 
> Where is the problem with CREATE  ?
> 
> CREATE, creates something new, and throws immediately an EDIT.
> 
> So, EDIT reads something which can be handeled read/write afterwards. 
> 
salut,
yes, understood is this far but my problem is that hConnection.Edit() 
returns a read/write result to edit an specific entry field by 
Move*()ing to the record. my question is now where i have to Move*() to 
to add a new record.
Connection.Create("table")["field"] = new_records_value
works well, but in case i Move*()ed somewhere in the result where do i 
have to move to make sure that i don't overwrite data in the record i 
just moved too, instead create a new one?
is this explanation clear enough?




More information about the User mailing list