Re: How to put array Value in C++
From: Jerry Pisk (jerryiii_at_hotmail.com)
Date: 05/23/04
- Next message: mp: "Incremental search"
- Previous message: Jerry Pisk: "Re: Can I use the ADO to get the server' time"
- In reply to: Tim: "How to put array Value in C++"
- Next in thread: Tim: "Re: How to put array Value in C++"
- Reply: Tim: "Re: How to put array Value in C++"
- Messages sorted by: [ date ] [ thread ]
Date: Sun, 23 May 2004 01:45:30 -0700
Don't you have to call SafeArrayUnaccessData when you're done with copying
your data into the buffer?
Jerry
"Tim" <anonymous@discussions.microsoft.com> wrote in message
news:94929D9E-7453-4ADD-92D7-A3BA784227DF@microsoft.com...
> SAFEARRAY *psa;
> How to put an array value into recordset Value property? What's wrong with
this code?
>
> LPSTR HUGEP *psb;
> VARIANT v;
> VariantInit(&v);
> psa=SafeArrayCreateVector(VT_UI1,0,400);
> SafeArrayAccessData(psa,(void HUGEP**)&psb);
> memcpy((LPSTR)psb,fv,400);
> v.vt=VT_ARRAY|VT_UI1;
> v.parray=psa;
> pRS->Fields->GetItem("DATA")->put_Value(v);
>
> also tried
>
> pRS->Fields->GetItem("DATA")->appendChunk(v);
>
> Both failed.
>
> Thanks.
>
- Next message: mp: "Incremental search"
- Previous message: Jerry Pisk: "Re: Can I use the ADO to get the server' time"
- In reply to: Tim: "How to put array Value in C++"
- Next in thread: Tim: "Re: How to put array Value in C++"
- Reply: Tim: "Re: How to put array Value in C++"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|