Set dashboard tab text by code

I have a dashboard with five tabs, all using a filter on a grid view for working weekdays. The first contains the results for up to and including today, tab 2 for today +1, tab 3 for today + 2. What I would like to know is, is it possible to customise the text on the tabs to show the actual date each time the dashboard is used?

Well if it would need to persist, you would have to create a UD field in a UD table or something. But as for setting the tab text, use:

//Add these to your using statements
using Ice.UI.App.(name of your dashboard goes here);
using System.Linq;

public void InitializeCustomCode()
		// ** Wizard Insert Location - Do not delete 'Begin/End Wizard Added Variable Initialization' lines **
		// Begin Wizard Added Variable Initialization

		// End Wizard Added Variable Initialization

		// Begin Wizard Added Custom Method Calls

		// End Wizard Added Custom Method Calls
		MainDockPanel mainPanel = (MainDockPanel)csm.GetNativeControlReference("D1E2D613-8F6D-4014-AD5C-F68870E1EC69");

		var firstTab = mainPanel.baseDockManager.ControlPanes.Cast<Infragistics.Win.UltraWinDock.DockableControlPane>().Where(x => x.TextTab == "test").FirstOrDefault();
		firstTab.TextTab = DateTime.Today.ToString();



This helped me figure this out

1 Like

Thank you @cfinley, that’s just what I was looking for. I will give it a try and see how I get on.
Thanks again

1 Like

I am getting an error with this line

using Ice.UI.App.(Due-Shipments);

Identifier Expected.
Is my syntax correct?