Connecting Tech Pros Worldwide Help | Site Map

Unbound text box, text>255, MS Access/PostgreSQL

 
LinkBack Thread Tools Search this Thread
  #1  
Old November 13th, 2005, 02:04 PM
Zlatko Matiæ
Guest
 
Posts: n/a
Default Unbound text box, text>255, MS Access/PostgreSQL

Hello.
I have the following problem with MS Access/PostgreSQL combination:
There is a form in Access that has an unbound text box, used for entering a
commentary of a batch of records.
There is a DAO Append Query that has a parameter that is passed from the
text box using parameter of DAO QueryDef object.
I adjusted B7 parameter (Text as LongVarchar) in connection string (ODBC
driver) to 1, so that Access links PostgreSQL Text fields as Memo fields in
Access. The intention was to be able to enter unlimited length commentary
into the field.
But, although I can enter unlimited text by using bound text box in some
other forms, in this particular form I can't use bound control, so I need to
pass text from UNBOUND control to the linked table by using DAO or ADO
code. It seems that DAO query can't accept Memo as parameter, but only text.
If my text exceeds length of 255, I have an VBA error 3271. If text in
unbound text box is shorter that 255 everything is OK.

So, is there any way to pass text of length >255 from unbound text box to
Memo field of linked PostgreSQL table, by using DAO or ADO ?

Thanks in advance,

Zlatko



  #2  
Old November 13th, 2005, 02:04 PM
Steve Jorgensen
Guest
 
Posts: n/a
Default Re: Unbound text box, text>255, MS Access/PostgreSQL

On Mon, 3 Oct 2005 01:15:54 +0200, "Zlatko Matiæ" <zlatko.matic1@sb.t-com.hr>
wrote:
[color=blue]
>Hello.
>I have the following problem with MS Access/PostgreSQL combination:
>There is a form in Access that has an unbound text box, used for entering a
>commentary of a batch of records.
>There is a DAO Append Query that has a parameter that is passed from the
>text box using parameter of DAO QueryDef object.
>I adjusted B7 parameter (Text as LongVarchar) in connection string (ODBC
>driver) to 1, so that Access links PostgreSQL Text fields as Memo fields in
>Access. The intention was to be able to enter unlimited length commentary
>into the field.
>But, although I can enter unlimited text by using bound text box in some
>other forms, in this particular form I can't use bound control, so I need to
>pass text from UNBOUND control to the linked table by using DAO or ADO
>code. It seems that DAO query can't accept Memo as parameter, but only text.
>If my text exceeds length of 255, I have an VBA error 3271. If text in
>unbound text box is shorter that 255 everything is OK.
>
>So, is there any way to pass text of length >255 from unbound text box to
>Memo field of linked PostgreSQL table, by using DAO or ADO ?
>
>Thanks in advance,
>
>Zlatko
>[/color]

The easiest way is to open a DAO recordset, and add a new record to it.
  #3  
Old November 13th, 2005, 02:06 PM
Zlatko Matic
Guest
 
Posts: n/a
Default Re: Unbound text box, text>255, MS Access/PostgreSQL

You were right!
Thanks,

Zlatko

"Steve Jorgensen" <nospam@nospam.nospam> je napisao u poruci interesnoj
grupi:uo15k1dibufmifm570p499tf5gdkqgo1d9@4ax.com.. .[color=blue]
> On Mon, 3 Oct 2005 01:15:54 +0200, "Zlatko Matiæ"
> <zlatko.matic1@sb.t-com.hr>
> wrote:
>[color=green]
>>Hello.
>>I have the following problem with MS Access/PostgreSQL combination:
>>There is a form in Access that has an unbound text box, used for entering
>>a
>>commentary of a batch of records.
>>There is a DAO Append Query that has a parameter that is passed from the
>>text box using parameter of DAO QueryDef object.
>>I adjusted B7 parameter (Text as LongVarchar) in connection string (ODBC
>>driver) to 1, so that Access links PostgreSQL Text fields as Memo fields
>>in
>>Access. The intention was to be able to enter unlimited length commentary
>>into the field.
>>But, although I can enter unlimited text by using bound text box in some
>>other forms, in this particular form I can't use bound control, so I need
>>to
>>pass text from UNBOUND control to the linked table by using DAO or ADO
>>code. It seems that DAO query can't accept Memo as parameter, but only
>>text.
>>If my text exceeds length of 255, I have an VBA error 3271. If text in
>>unbound text box is shorter that 255 everything is OK.
>>
>>So, is there any way to pass text of length >255 from unbound text box to
>>Memo field of linked PostgreSQL table, by using DAO or ADO ?
>>
>>Thanks in advance,
>>
>>Zlatko
>>[/color]
>
> The easiest way is to open a DAO recordset, and add a new record to it.[/color]


 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,662 network members.