/// <summary> /// Display the data for this tab where we have selected an asset or child node thereof /// </summary> /// <param name="displayedNode"></param> protected void DisplayForAsset(UltraTreeNode displayedNode) { // We are displaying ALL publishers and ALL applications for this asset - add in columns for // Application Object, Publisher, Name, Version, Serial Number and CD Key DataColumn column1 = new DataColumn("ApplicationObject", typeof(object)); DataColumn column2 = new DataColumn("Publisher", typeof(string)); DataColumn column3 = new DataColumn("Name", typeof(string)); DataColumn column4 = new DataColumn("Version", typeof(string)); DataColumn column5 = new DataColumn("Serial Number", typeof(string)); DataColumn column6 = new DataColumn("CD Key", typeof(string)); // Add these columns to the DataSet applicationsDataSet.Tables[0].Columns.AddRange(new System.Data.DataColumn[] { column1, column2, column3, column4, column5, column6 }); // Get the work item controller NetworkWorkItemController wiController = WorkItem.Controller as NetworkWorkItemController; Asset theAsset = displayedNode.Tag as Asset; // ...and from there settings which alter what we display in this view bool showIncluded = wiController.ShowIncludedApplications; bool showIgnored = wiController.ShowIgnoredApplications; String publisherFilter = wiController.PublisherFilter; // Call database function to return list of applications (for the specified publisher) ApplicationsDAO lwDataAccess = new ApplicationsDAO(); DataTable applicationsTable = lwDataAccess.GetInstalledApplications(theAsset, publisherFilter, showIncluded, showIgnored); foreach (DataRow row in applicationsTable.Rows) { ApplicationInstance newApplication = new ApplicationInstance(row); AddApplication(newApplication); } }