The Unicode extension to the fields is only supported for Visual FoxPro compatible tables (the DBFVFP RDD) and you cannot use the OleDb driver for this.
You will have to create the table with DBCreate().
And I just found a problem in 2.19 that causes the Unicode flag to get lost when creating the table.
I'll fix that in the 2.20 release.
After that change you can store various character sets in a DBF like this:
Code: Select all
FUNCTION Start() AS VOID STRICT
RddSetDefault("DBFVFP")
System.Console.OutputEncoding = System.Text.Encoding.UTF8
DbCreate("Polchars.dbf", {{"Name","C:U",100,0},{"Adresse","C:U",100,0}, {"Info","C:U",100,0}})
DbuseArea(,,"PolChars")
DbAppend()
FieldPut(1, "Witaj świecie") // Polish
FieldPut(2, "你好世界") // Chinese
FieldPut(3, "こんにちは世界") // Japanese
DbCommit()
? FieldGet(1)
? FieldGet(2)
? FieldGet(3)
wait