Skip to main content
December 10, 2025
Solved

How to populate a Dashboard List Box referencing WFText4 but the UD dim may vary across Workflows?

  • December 10, 2025
  • 1 reply
  • 0 views

As the title suggests, I am trying to populate a dashboard list box that references the Workflow text property regardless of the dimension being used. I'm able to populate the list box using a single dimension, meaning a UD3 member is populated on the workflow's WFText4 property and a member list parameter uses |WFText4| to pull it in. How would I get this to work if the Workflow text value is not always UD3? For Example (both workflows will be using WFText4): Canada Workflow A needs a UD3 Member.Base to populate in the list box when they run the dashboard in their workflow but Canada Workflow B needs a UD6 Member.Base to populate the list box when they run the dashboard in their workflow. Please let me know if I can provide more context.

Best answer by sameburn

Hi MichaelHahn​ 

You could achieve this if you include the Dimension Token in your WFText4.  You can then check the dimension via the token e.g. UD3#Top.Base versus UD6#Top.Base, etc

You can use something like this Dictionary where the key is the DimToken and the Value is the DimTypeName, etc.  My original logic had it the other way round but this works better for your use case

	        Public Function GetDimTokenDictionary(ByVal si As SessionInfo) As Dictionary(Of String, String)
	            Try
					' Create object to return
					Dim dimDict As New Dictionary(Of String, String)
					
					' Retrieve all dimensions
					Dim allDims As List(Of String) = DimType.GetAllDimTypes.Select(Function(dimType) dimType.Name).ToList()

					' Loop allDims List
					For Each dimension As String In allDims
						' Handling for UD's
						If dimension.StartsWith("U") Then
							' Add Dimension and DimToken to dimDict for UD's
							dimDict.Add(StageConstants.MasterDimensionTokens.GetDimensionToken(StageConstants.MasterDimensionNames.GetDimensionName(StageConstants.MasterDimensionNames.GetDimensionLongName(dimension.Replace("D", String.Empty)))), dimension)					
						Else
							' Add Dimension and DimToken to dimDict for all other Dims
							dimDict.Add(StageConstants.MasterDimensionTokens.GetDimensionToken(StageConstants.MasterDimensionNames.GetDimensionName(dimension)), dimension)						
						End If					
					Next dimension
						
					' Return
					Return dimDict
	
	                Return Nothing
	            Catch ex As Exception
	                Throw ErrorHandler.LogWrite(si, New XFException(si, ex))
				End Try
	        End Function

Hope this helps

Sam

1 reply

sameburnAnswer
December 15, 2025

Hi MichaelHahn​ 

You could achieve this if you include the Dimension Token in your WFText4.  You can then check the dimension via the token e.g. UD3#Top.Base versus UD6#Top.Base, etc

You can use something like this Dictionary where the key is the DimToken and the Value is the DimTypeName, etc.  My original logic had it the other way round but this works better for your use case

	        Public Function GetDimTokenDictionary(ByVal si As SessionInfo) As Dictionary(Of String, String)
	            Try
					' Create object to return
					Dim dimDict As New Dictionary(Of String, String)
					
					' Retrieve all dimensions
					Dim allDims As List(Of String) = DimType.GetAllDimTypes.Select(Function(dimType) dimType.Name).ToList()

					' Loop allDims List
					For Each dimension As String In allDims
						' Handling for UD's
						If dimension.StartsWith("U") Then
							' Add Dimension and DimToken to dimDict for UD's
							dimDict.Add(StageConstants.MasterDimensionTokens.GetDimensionToken(StageConstants.MasterDimensionNames.GetDimensionName(StageConstants.MasterDimensionNames.GetDimensionLongName(dimension.Replace("D", String.Empty)))), dimension)					
						Else
							' Add Dimension and DimToken to dimDict for all other Dims
							dimDict.Add(StageConstants.MasterDimensionTokens.GetDimensionToken(StageConstants.MasterDimensionNames.GetDimensionName(dimension)), dimension)						
						End If					
					Next dimension
						
					' Return
					Return dimDict
	
	                Return Nothing
	            Catch ex As Exception
	                Throw ErrorHandler.LogWrite(si, New XFException(si, ex))
				End Try
	        End Function

Hope this helps

Sam

December 15, 2025

Thank you for the reply, Sam. Where exactly is this rule logic being applied and how would this feed into a dashboard list box?

December 15, 2025

You would need to use a Business Rule to achieve what you want e.g  conditional logic based on your use case

You can use Dashboard DataSet or XFBR rules to feed parameters in onestream 

You could then derive the dimension to use based on the dimension token e.g E# = Entity, etc in that rule based on your use case

Alternatively if you're not familiar with rules you might want to consider using a different WFText property instead to disseminate between dimension types using just substitution variables e.g |WFText4|

Hope this helps