glasgow.27
02-27-2014, 09:08 AM
Hello everyone,
Is it possible to get to the calculation for a field in an Access Query via VBA? I know that I could parse the SQL string, but I was thinking that there had to be an easier, more direct way to get the the information.
To clarify, take the following example:
A table contains two columns ([Column A] and [Column B])
A query has a calculated field (Product: [Column A] * [Column B])
Is there a way to get to "[Column A] * [Column B]"? I've tried using the Expression Property of the field (QueryDef.Field.Property("Expression").value), but that just returns a null string. Any help would be appreciated. Thanks.
Is it possible to get to the calculation for a field in an Access Query via VBA? I know that I could parse the SQL string, but I was thinking that there had to be an easier, more direct way to get the the information.
To clarify, take the following example:
A table contains two columns ([Column A] and [Column B])
A query has a calculated field (Product: [Column A] * [Column B])
Is there a way to get to "[Column A] * [Column B]"? I've tried using the Expression Property of the field (QueryDef.Field.Property("Expression").value), but that just returns a null string. Any help would be appreciated. Thanks.