Forum Discussion
Henning
11 months agoValued Contributor II
Hi, you can use Method Queries in a dashboard data set rule with this function:
Dim objDataSet As DataSet = BRApi.Database.ExecuteMethodCommand(dbConn, methodTypeId, methodQuery, resultDataTableName, customSubVars)
Also available in Snippets:
In your case e.g. like this:
'Open DB connection and execute the method command
Dim ds As DataSet = Nothing
Using dbConnApp As DbConnInfo = BRAPi.Database.CreateApplicationDbConnInfo(si)
'Execute the Method Command
ds = BRAPi.Database.ExecuteMethodCommand(dbConnApp, XFCommandMethodTypeId.WorkflowAndEntityStatus,"","WF", Nothing)
End Using
Then you pull your other source table and do with the two data tables what you need in the dashboard data set rule.
You could also execute a SQL command, joining this all together before creating the data table, though the above is probably quicker.
(Or pull the data from a adapter data like aformenti suggested, who beat me with his response time 🙂)
Related Content
- 10 months ago
- 3 years ago
- 25 days ago
- 2 years ago
- 2 years ago