// get the active investigation view var iv = KnowledgeGraphInvestigationView.Active; var serviceUri = iv.Investigation.ServiceUri; // build a dictionary of records var dict = new Dictionary<string, List<long>>(); //Each entry consists of the type name and corresponding lists of ids dict.Add(first_entity, new List<long>() { 1, 5, 18, 36, 78 }); //Create the id set... var idSet = KnowledgeGraphLayerIDSet.FromDictionary(new Uri(serviceUri), dict); // select the records on the investigation view iv.SetSelectedRecords(idSet, SelectionCombinationMethod.New);
Target Platforms: Windows 11, Windows 10