No Unicode in DAO recordset

  • Thread starter Thread starter Axel Dahmen
  • Start date Start date
A

Axel Dahmen

Hi,

I've imported a table from MS SQL Server containing characters beyond ASCII.
When I open this table from within Access, all characters appear correctly.
But if I open a DAO Recordset, these characters have been converted into
ASCII characters. (e.g. 0x11F becomes 0x67)

How can I cope with this?

TIA,
Axel Dahmen
 
Did you have set the Unicode compression feature for this field? If yes,
than try with no.

Also, what is the version of Access that you are using and how are you
opening your recordset and displaying the result?

S. L.
 
Meanwhile I've learned from another newsgroup that the Recordset contains
correct data but that the Debugger window and Tooltips can't display Unicode
strings.

My problem is that I've written an Access module to create a text file to
contain the data I get from the Recordset. It seems that Access can only
create ANSI files but no Unicode files.

Do you perhaps know some solution I could use?

TIA,
Axel Dahmen


PS.: Here's an excerpt from the VBA-Script I have written:

Open filepath For Output Lock Read Write As #lfn

Set rsa = DBEngine(0)(0).OpenRecordset("SELECT ID,Bezeichnung FROM
Anbieter ORDER BY ID", ...)
Do Until rsa.EOF
Print #lfn, rsa!Bezeichnung; " ---------------------"
...
rsa.MoveNext
Loop

Close lfn






-----------
 
If you want to write in Unicode with VBA, my feeling would be that you must
write in binary mode; not in Text mode.

You can also convert from Unicode to your local code page. The following
piece of code give you all the functions needed:
http://www.trigeminal.com/code/InCodePage.bas .

You also have the possibility of interfacing your access application with
..NET, which offers a much greater support for Unicode and Localization.

For the rest, you should repost your question in this newsgroup.

Happy new year!
S. L.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top