A
AC
Hi
I am running some vba which opens a table, and the default column
width it uses is much much too small for the text contained in the
field. Is there any way to either resize it via the code, or to get
it to use a more sensible value?
The table opens with the field only wide enough to show 14 characters,
which as an aside is also smaller than the field name let alone the
size of the data.
My code is something like:
'Drop the temp table if it exists
DropTable("t_temp") '<--- THIS IS A CUSTOM ROUTINE I HAVE
'Create a temp table
Set tdf = db.CreateTableDef("t_temp")
With tdf
.Fields.Append .CreateField("Unknown_Scenario_Filename",
dbText, 255)
End With
db.TableDefs.Append tdf
db.TableDefs.Refresh
Application.RefreshDatabaseWindow
'Put some data into this table
<puts various rows of data into the table, the data is full
file and path names so can be quite long >
'Open this table
DoCmd.OpenTable "t_temp"
Thanks in advance
AndyC
I am running some vba which opens a table, and the default column
width it uses is much much too small for the text contained in the
field. Is there any way to either resize it via the code, or to get
it to use a more sensible value?
The table opens with the field only wide enough to show 14 characters,
which as an aside is also smaller than the field name let alone the
size of the data.
My code is something like:
'Drop the temp table if it exists
DropTable("t_temp") '<--- THIS IS A CUSTOM ROUTINE I HAVE
'Create a temp table
Set tdf = db.CreateTableDef("t_temp")
With tdf
.Fields.Append .CreateField("Unknown_Scenario_Filename",
dbText, 255)
End With
db.TableDefs.Append tdf
db.TableDefs.Refresh
Application.RefreshDatabaseWindow
'Put some data into this table
<puts various rows of data into the table, the data is full
file and path names so can be quite long >
'Open this table
DoCmd.OpenTable "t_temp"
Thanks in advance
AndyC