Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Creat Tmp Recordset with adMemo
Message
 
To
01/07/2000 01:05:28
General information
Forum:
Visual Basic
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00386954
Message ID:
00387304
Views:
18
>>>Creating a memory Recordset, I need a field to be Memo data type
>>>like the example below. Is there such data type as adMemo?
>>>I checked the help file but couldn't find it. Any advise? Thanks.
>>>
>>> Set rstMemory = New ADODB.Recordset
>>> With rstMemory
>>> .CursorLocation = adUseClient
>>> .LockType = adLockPessimistic
>>> .Fields.Append "TypeCode", adChar, 20
>>> .Fields.Append "TypeName", adChar, 50
>>> .Fields.Append "Amount", adCurrency
>>> .Fields.Append "Remarks", ????? (need a Memo data type)
>>> .Open
>>> End With
>>
>>According to >http://msdn.microsoft.com/library/officedev/off2000/acdatComparisonDataTypes.ht>m, you should use adLongVarWChar.
>
>I tried to declared this but has Type Mismatch error:
> .Fields.Append "Remarks", adLongVarWChar
>
>But if I do this, then it is OK
> .Fields.Append "Remarks", adLongVarWChar, 255
>
>Do I need to specific the Length of the memo field?

I just found that adLongVarWChar is to be used with the Command object.

Instead, you can declare that:
.Fields.Append "Remarks", adWChar, 100000
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com
Previous
Reply
Map
View

Click here to load this message in the networking platform