Sergey
2 months agoContributor III
Components' Dynamic state for dynamic dashboard
Hello,
I am trying to get my dynamically created buttons to execute a server task.
I can create all the buttons I need in my dynamic dashboard, but as soon as I try to get them to execute a dashb...
- 31 days ago
Hi Sergey
You do not appear to be passing your repeatArgsList into the api that creates the ComponentCollection?
e.g. this is the method.
GetDynamicComponentsRepeatedForDynamicDashboard(SessionInfo si, DashboardWorkspace workspace, WsDynamicDashboardEx dynamicDashboardEx, List<WsDynamicComponentRepeatArgs> repeatArgsList, TriStateBool convertStoredComponentsToDynamic, WsDynamicItemStateType dynamicItemStateType)
The example you shared is the default when you create a new DynamicDashboardsService and it expects nothing to be returned (excuse C# below but principles are the same)
Try passing in your repeatArgsList and TriStateBool.Unknown (instead of Nothing) and hopefully it works... or at least you get a new error 😄
BR
Sam
e.g.
WsDynamicComponentCollection componentCollection = api.GetDynamicComponentsRepeatedForDynamicDashboard(si, workspace, dynamicDashboardEx, repeatArgsList, TriStateBool.Unknown, WsDynamicItemStateType.Unknown);