Retrieve Expression attribute via Column #1493
vermw
started this conversation in
Other Topics
Replies: 1 comment
|
I found a solution via: |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Dear all,
I'm writing a script that loops over all columns in the model, checks if the column type is Calculated and then gets its Expression. Something like this:
foreach (var m in Model.AllColumns) { if(m.Type == ColumnType.Calculated) { if (m.Expression.Contains("dog")){ Info(m.Name); } } }Problem is that the Columns class doesn't have an expression. Though when I do a ToString() on the column (m.ToString()), then it shows me "TabularEditor.TOMWrapper.CalculatedColumn", so it knows it's a calculated column, yet treats it as column.
Anyway, what is the appropriate way to retrieve an expression if you have the column?
Thanks!
All reactions