D
Dodo2u
I'm running a MakeTableQuery (if that is the proper translation from
Dutch) to create a new table after export of a batch of ASCII-data from a
different application, which is linked to the database.
This replaces each time the table that was used before, which is a pity
because several fields have to be added to that table. So far this has
been done manually.
How can it be done in VB? I have added some lines to the button code to
get this done automatically, but I cannot find the proper expression for
a selection (tick?) box (selectievakje?).
So, something similar to:
DoCmd.OpenQuery "A5-A6_keuze"
Dim db As DAO.Database
Dim tbl As DAO.TableDef
Dim fld As Field
Dim fld2 As Field
Dim Veld5 As Field
Set db = CurrentDb
Set tbl = db!janus
Set fld = tbl.CreateField("A5", dbBoolean)
Set fld2 = tbl.CreateField("A6", dbBoolean)
tbl.Fields.Append fld
tbl.Fields.Append fld2
db.Close
This works but the Boolean type gives a 0 or 1, not a selection box (that
little square that you can tick).
Appreciate any help!
Dutch) to create a new table after export of a batch of ASCII-data from a
different application, which is linked to the database.
This replaces each time the table that was used before, which is a pity
because several fields have to be added to that table. So far this has
been done manually.
How can it be done in VB? I have added some lines to the button code to
get this done automatically, but I cannot find the proper expression for
a selection (tick?) box (selectievakje?).
So, something similar to:
DoCmd.OpenQuery "A5-A6_keuze"
Dim db As DAO.Database
Dim tbl As DAO.TableDef
Dim fld As Field
Dim fld2 As Field
Dim Veld5 As Field
Set db = CurrentDb
Set tbl = db!janus
Set fld = tbl.CreateField("A5", dbBoolean)
Set fld2 = tbl.CreateField("A6", dbBoolean)
tbl.Fields.Append fld
tbl.Fields.Append fld2
db.Close
This works but the Boolean type gives a 0 or 1, not a selection box (that
little square that you can tick).
Appreciate any help!