How do you set a value into a field of a cursor

Ruslan Zasukhin sunshine at public.kherson.ua
Mon Jun 30 23:17:38 CDT 2003


on 6/30/03 23:01, Howard Steadman at hsteadma at fulltilt.com wrote:

> Ruslan, 
> 
> pCursorPOPDetail is a VDK_Cursor*;
> Field (2) is a VDK_Long;
> 
> What I want to do is set the value to a long that I have. I can get it as a
> string and set it as a string, but this seems really wasteful since I know I
> have longs. What I would like is something like:
> 
> 
>               pCursorPOPDetail->GetField(2).Value = 3;
> 
> This won't compile. I have tried many variations.

Howard,

    GetField() returns VDK_field, but you need VDK_Long class.
    correct?

So look that VDK_Cursor class have also set of functions that return
required field type.

This should work as you want:

    *(pCursorPOPDetail->GetLongField(2)) = 3;

-- 
Best regards,
Ruslan Zasukhin      [ I feel the need...the need for speed ]
-------------------------------------------------------------
e-mail: ruslan at paradigmasoft.com
web: http://www.paradigmasoft.com

To subscribe to the Valentina mail list go to:
http://lists.macserve.net/mailman/listinfo/valentina
-------------------------------------------------------------



More information about the Valentina mailing list