How to display Decimal places using VBA

Leen

Registered User.
Local time
Today, 01:05
Joined
Mar 15, 2007
Messages
56
Hi,

I'd like to create a table using VBA where one of the fields is a number datataype, the fieldsize property is double.

Code:
.Fields.Append .CreateField("LENGTH", dbDouble)

However, I'd like tthat that, when values are inserted in this tablefield, 7 decimal places are displayed. I know you can set it manual in the design view of the table (in the tab general - decimal places), but i'd like to do this automatically when creating the table?

In the help I found under DecimalPlaces Property:
"Note You can set this property for text boxes and combo boxes by using the control's property sheet and for table fields by using the table's property sheet. You can also set this property in the Field Properties property sheet in query Design view"

Does that means it can't be set while creating the table?

Thanks for any help!
Leen
 
there's probably another field attribute for display decimals you can set in a similar way
 

Users who are viewing this thread

Back
Top Bottom