I’m trying to get the datatype out of a DAO recordset. Code below:
Public Function EditFormData(frm As Form)
Dim rst As DAO.Recordset
Dim fieldType as DAO.DataTypeEnum
Set rst = frm.RecordsetClone
rst.MoveFirst
fieldType = rst.Fields(0).Type
MsgBox fieldType.ToString
I get an Invalid Qualifier error on fieldType in the msgbox when I try to run this, and don’t know why since this is my first foray into Enums.
Create your own function to convert the enum to text. Instead of writing the code from scratch I found this example.
http://bytes.com/topic/access/answers/209125-can-you-tell-datatype-control
PS My first post or comment so feel free to comment.