Actually I dont want to use forms or Reports here. Is it possible to get the format setting properties of a field in a "table" directly. Thanks for your replies.
i just thought that would most likely be where it was to be found.
i am sure it is possible - pretty well everything is just part of a collection of some sort
------------------
I have tried it now - like a lot of things its a user created property - so it isnt there unitl you define it - then it is there
this sub shows you all the properties of a given field
Code:
Sub tryit()
Dim s As String
Dim dbs As Database
Dim prp As Property
s = "Properties " & vbcrlf
Set dbs = CurrentDb
For Each prp In dbs.TableDefs("switchboard items").Fields("argument").Properties
s = s & prp.Name & vbCrLf
Next
MsgBox (s)
End Sub
create a format - then you will see it IS there
and this version will show you the format string
Code:
Sub tryit()
Dim s As String
Dim dbs As Database
On Error GoTo noprop
Set dbs = CurrentDb
MsgBox (dbs.TableDefs("switchboard items").Fields("thedate").Properties("format").value)
Exit Sub
noprop:
MsgBox ("Property Not Found" & vbCrLf & _
"Error: " & err & " Desc: " & err.Description)
End Sub