Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

setting standard property on a field per code

Status
Not open for further replies.

kingz2000

Programmer
May 28, 2002
304
DE
Hi guys,
with the code below, I am trying to set the property of a field 'Shares' as standard. For some rerason it gives me the error message: Error 3219 - Operation is not allowed in this context...as I append the property pstdProp.

can somebody help me out??

Dim td As TableDef
Dim aField As Field
Dim pStdProp As Property



Set aField = td.CreateField("shares", dbDouble)
td.Fields.Append aField
Set pStdProp = aField.CreateProperty("Format", dbText)
pStdProp.Value = "Fixed"
aField.Properties.Append pStdProp
aField.Properties("Format") = "Standard"

Thanks in advance,
~k~
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top