[VSDK ] Access to cursor fields
Eric Forget
forgete at cafederic.com
Fri Jan 24 10:50:42 CST 2003
>>
>> Also, back to your idea, I wonder now on next 2 points
>>
>> 1) may be we should allow usage of GetValue() on left side also?
>>
>> curs->Value("Field1") = (short) 5;
>>
>> 2) may be even shorter?
>>
>> curs("Field1") = (short) 5;
>>
>
> Wouldn't this also work with an overloaded 'operator[]' so you can do:
>
> curs["Field1"] = (short) 5;
>
> It seems more natural than having a method-call on the left-hand-side.
I'm not sure about that one. I would have thought about keeping the
operator[] for navigating through all the records of the cursors. However,
something like this would be nice:
curs[index]["Field1"] = (short)5;
And
(*curs)["Field1"] = (short)5; // If you are already on the right index.
Éric
___________________________________________________________________
Eric Forget Cafederic
ForgetE at cafederic.com <http://www.cafederic.com/>
Fingerprint <86D5 38F5 E1FD 5D9C 71C3 BAA3 797E 70A4 6210 C684>
More information about the Valentina
mailing list