Re: OLE DB Consumer Templates

Erik Valdes <[email protected]> Thu, 9 Jan 2003 09:27:07 -0700
Newsgroups gmane.comp.windows.devel.oledb.devel
Message-ID <[email protected]>
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C2B7FB.F38E78B0
Content-Type: text/plain

I've tried that.  I get the following error during compilation:



error C2597: illegal reference to data member 'CAddWorkRequest::m_lLength'
in a static member function



-----Original Message-----
From: Kjell Arild Tangen [mailto:[email protected]]
Sent: Wednesday, January 08, 2003 11:00 PM
To: [email protected]
Subject: Re: [OLEDB_DEV] OLE DB Consumer Templates



You can use the the COLUMN_ENTRY_TYPE_SIZE macro, but the size must refer to
a member variable that contains the size, e.g.



COLUMN_ENTRY_TYPE_SIZE(2,DBTYPE_STR,m_lWorkRequestLen, m_WorkRequest)



What you need to do before the command is executed is to set the variable to
the length of the buffer that holds the corresponding value.



Regards,

Kjell Tangen

-----Original Message-----
From: Erik Valdes [mailto:[email protected]]
Sent: 8. januar 2003 23:22
To: [email protected]
Subject: [OLEDB_DEV] OLE DB Consumer Templates

-->

I'm having trouble implementing an accessor.  I'm trying to use a variable
(m_WorkRequest) that's dynamically allocated as the variable that's bound to
a parameter in my accessor (commented line below).   The reason I need it to
be dynamic is that it is XML and can be any length.  The stored proc's
parameter is of ntext type to handle the variable length.  However, I don't
know at compile time how big to make the buffer for my parameter in my
accessor.  What's the proper way to do this?  I've tried COLUMN_ENTRY
(access violation), COLUMN_ENTRY_LENGTH (different variations produce
different errors, but basically I can't set the length),
COLUMN_ENTRY_TYPE_SIZE (similar problems as the previous).  I'm running out
of ideas now.  The code below is just one of many, many variations I've
tried.





class CAddWorkRequest

{

public:

   CAddWorkRequest() STD_INIT

   ~CAddWorkRequest()

   {

      if (m_WorkRequest)

         delete [] m_WorkRequest;

   }

   LONG m_RETURNVALUE;

   LPTSTR m_WorkRequest;

   LONG m_lLength;



   void SetStringParam(LPCTSTR szString,int cBytes)

   {

      m_WorkRequest = (LPTSTR) new TCHAR[cBytes];

      _tcsncpy(m_WorkRequest,szString,cBytes);

      m_lLength = _tcslen(m_WorkRequest);

   })



BEGIN_PARAM_MAP(CAddWorkRequest)

   SET_PARAM_TYPE(DBPARAMIO_OUTPUT)

   COLUMN_ENTRY(1, m_RETURNVALUE)

   SET_PARAM_TYPE(DBPARAMIO_INPUT)

//   COLUMN_ENTRY_TYPE_SIZE(2,DBTYPE_STR,_tcslen(m_WorkRequest),
m_WorkRequest)





END_PARAM_MAP()



DEFINE_COMMAND(CAddWorkRequest, _T("{ ? = CALL dbo.AddWorkRequest;1 (?) }"))



};



class CAddWorkRequestCommand : public CBsDbCommand<CAddWorkRequest>

{

};



foo (LPTSTR szWor)

{

            CAddWorkRequestCommand cmd;

            cmd.SetStringParam(szWor,_tcslen(szWor)+1);

cmd.Open();

}



You can read messages from the OLEDB_DEV archive, unsubscribe from
OLEDB_DEV, or subscribe to other DevelopMentor lists at
http://discuss.develop.com.

You can read messages from the OLEDB_DEV archive, unsubscribe from
OLEDB_DEV, or subscribe to other DevelopMentor lists at
http://discuss.develop.com.

You can read messages from the OLEDB_DEV archive, unsubscribe from OLEDB_DEV,
or subscribe to other DevelopMentor lists at http://discuss.develop.com.

------_=_NextPart_001_01C2B7FB.F38E78B0
Content-Type: text/html
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>

<head>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Dus-ascii">


<meta name=3DGenerator content=3D"Microsoft Word 10 (filtered)">
<title>Message</title>

<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {font-family:Arial;
        color:navy;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</style>
<DEFANGED_META CONTENT=3D"text/html; charset=3Dus-ascii" =
HTTP-EQUIV=3D"Content-Type"><DEFANGED_META content=3D"Microsoft Word 10 =
(filtered)" name=3D"Generator"><!-- <DEFANGED_STYLE>
<!--
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {font-family:Arial;
        color:windowtext;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</head>

<body lang=3DEN-US link=3Dblue vlink=3Dpurple>

<div class=3DSection1>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>I've tried that.&nbsp; I get the
following error during compilation:</span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>&nbsp;</span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>error C2597: illegal reference to =
data
member 'CAddWorkRequest::m_lLength' in a static member =
function</span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DTahoma><span
style=3D'font-size:10.0pt;font-family:Tahoma'>-----Original =
Message-----<br>
<b><span style=3D'font-weight:bold'>From:</span></b> Kjell Arild Tangen
[mailto:[email protected]] <br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Wednesday, January =
08, 2003
11:00 PM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> =
[email protected]<br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> Re: [OLEDB_DEV] =
OLE DB
Consumer Templates</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
color=3Dblue face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;color:blue'>You can use the =
the
COLUMN_ENTRY_TYPE_SIZE macro, but the size must refer to a member =
variable that
contains the size, e.g.</span></font></p>

</div>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

</div>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>COLUMN_ENTRY_TYPE_SIZE(2,DB=
TYPE_STR,m_lWorkRequestLen,
m_WorkRequest)</span></font></p>

</div>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

</div>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>What you need to do before =
the
command is executed is to set the variable to the length of the buffer =
that
holds the corresponding value.</span></font></p>

</div>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

</div>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>Regards,</span></font></p>

</div>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>Kjell =
Tangen</span></font></p>

</div>

<blockquote style=3D'border:none;border-left:solid blue =
1.5pt;padding:0in 0in 0in 4.0pt;
margin-left:3.75pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt=
'>

<p class=3DMsoNormal =
style=3D'margin-right:0in;margin-bottom:12.0pt;margin-left:
.5in'><font size=3D2 face=3DTahoma><span =
style=3D'font-size:10.0pt;font-family:Tahoma'>-----Original
Message-----<br>
<b><span style=3D'font-weight:bold'>From:</span></b> Erik Valdes
[mailto:[email protected]] <br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> 8. januar 2003 =
23:22<br>
<b><span style=3D'font-weight:bold'>To:</span></b> =
[email protected]<br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> [OLEDB_DEV] OLE =
DB
Consumer Templates</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>--&gt; </span></font></p>

</DEFANGED_STYLE>

<div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>I'm having trouble =
implementing an
accessor. &nbsp;I'm trying to use a variable (m_WorkRequest) that's =
dynamically
allocated as the variable that's bound to a parameter in my accessor =
(commented
line below).&nbsp; &nbsp;The reason I need it to be dynamic is that it =
is XML
and can be any length.&nbsp; The stored proc's parameter is of ntext =
type to
handle the variable length.&nbsp; However, I don't know at compile time =
how big
to make the buffer for my parameter in my accessor.&nbsp; What's the =
proper way
to do this?&nbsp; I've tried COLUMN_ENTRY (access violation),
COLUMN_ENTRY_LENGTH (different variations produce different errors, but
basically I can't set the length), COLUMN_ENTRY_TYPE_SIZE (similar =
problems as
the previous).&nbsp; I'm running out of ideas now.&nbsp; The code below =
is just
one of many, many variations I've tried.</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>class =
CAddWorkRequest</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>{</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>public:</span></span></font=
></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; CAddWorkReques=
t()
STD_INIT</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; =
~CAddWorkRequest()</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; { =
</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp; if
(m_WorkRequest)</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp;&nbsp;
delete [] m_WorkRequest;</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; =
}</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; LONG =
m_RETURNVALUE;</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; LPTSTR =
m_WorkRequest;</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; LONG =
m_lLength;</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; void
SetStringParam(LPCTSTR szString,int cBytes)</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; =
{</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;
m_WorkRequest =3D (LPTSTR) new TCHAR[cBytes];</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;
_tcsncpy(m_WorkRequest,szString,cBytes);</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp; m_lLength
=3D _tcslen(m_WorkRequest);</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; =
})</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>BEGIN_PARAM_MAP(CAddWorkReq=
uest)</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;
SET_PARAM_TYPE(DBPARAMIO_OUTPUT)</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp; =
COLUMN_ENTRY(1,
m_RETURNVALUE)</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;
SET_PARAM_TYPE(DBPARAMIO_INPUT)</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>//&nbsp;&nbsp;
COLUMN_ENTRY_TYPE_SIZE(2,DBTYPE_STR,_tcslen(m_WorkRequest), =
m_WorkRequest)</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>END_PARAM_MAP()</span></spa=
n></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>DEFINE_COMMAND(CAddWorkRequ=
est,
_T(&quot;{ ? =3D CALL dbo.AddWorkRequest;1 (?) =
}&quot;))</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
DEFANGED_STYLE=3D"font-size:10.0pt;&#13;&#10;font-family:Arial"><span
style=3D'font-size:10.0pt;font-family:Arial'>};</span></span></font></p>=


<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
DEFANGED_STYLE=3D"font-size:&#13;&#10;12.0pt"><span =
style=3D'font-size:12.0pt'>class
CAddWorkRequestCommand : public =
CBsDbCommand&lt;CAddWorkRequest&gt;</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
DEFANGED_STYLE=3D"font-size:&#13;&#10;12.0pt"><span =
style=3D'font-size:12.0pt'>{</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
DEFANGED_STYLE=3D"font-size:&#13;&#10;12.0pt"><span =
style=3D'font-size:12.0pt'>};</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
DEFANGED_STYLE=3D"font-size:&#13;&#10;12.0pt"><span =
style=3D'font-size:12.0pt'>foo
(LPTSTR szWor)</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
DEFANGED_STYLE=3D"font-size:&#13;&#10;12.0pt"><span =
style=3D'font-size:12.0pt'>{</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
DEFANGED_STYLE=3D"font-size:&#13;&#10;12.0pt"><span =
style=3D'font-size:12.0pt'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp;&nbsp;
CAddWorkRequestCommand cmd;</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
DEFANGED_STYLE=3D"font-size:&#13;&#10;12.0pt"><span =
style=3D'font-size:12.0pt'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp;&nbsp;
cmd.SetStringParam(szWor,_tcslen(szWor)+1);</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in' =
DEFANGED_STYLE=3D"text-indent:.5in"><font
size=3D3 face=3D"Times New Roman"><span =
style=3D'font-size:12.0pt'>cmd.Open();</span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
DEFANGED_STYLE=3D"font-size:&#13;&#10;12.0pt"><span =
style=3D'font-size:12.0pt'>}</span></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>&nbsp;</span></font></p>

</div>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D3 =
face=3D"Times New Roman"><span
style=3D'font-size:12.0pt'>You can read messages from the OLEDB_DEV =
archive,
unsubscribe from OLEDB_DEV, or subscribe to other DevelopMentor lists =
at
http://discuss.develop.com. </span></font></p>

</blockquote>

</div>

</body>

</html>
You can read messages from the OLEDB_DEV archive, unsubscribe from =
OLEDB_DEV,
or subscribe to other DevelopMentor lists at =
You can read messages from the OLEDB_DEV archive, unsubscribe from OLEDB_DEV,
or subscribe to other DevelopMentor lists at http://discuss.develop.com.
http://discuss.develop.com.
------_=_NextPart_001_01C2B7FB.F38E78B0--