Programmatically setting Unicode Compression

R

Ronald

Hi all.

I can create tables with fields and set field Required to Yes and so on.
The Text fields are default with Unicode Compression set to No and I cannot
find the command to change it.
Can any MVP help me please?
Thank you.

Ronald.
 
J

James Rivera [MS]

You can get to this via DAO with VBA:

Sub foo()
Debug.Print
Application.CurrentDb.TableDefs("Table1").Fields("Field1").Properties("UnicodeCompression").Value

Application.CurrentDb.TableDefs("Table1").Fields("Field1").Properties("UnicodeCompression").Value = True
End Sub

-James
 
R

Ronald

Thank you very much, James.

James Rivera said:
You can get to this via DAO with VBA:

Sub foo()
Debug.Print
Application.CurrentDb.TableDefs("Table1").Fields("Field1").Properties("UnicodeCompression").Value

Application.CurrentDb.TableDefs("Table1").Fields("Field1").Properties("UnicodeCompression").Value = True
End Sub

-James
 

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

Top