Quintiq file version 2.0 #parent: #root Method SelectKB ( Scenario scenario, internal[KBFullID] kbfullid ) id:Method_ApplicationLibMacroPlanner_SelectKB { #keys: '[11660.0.749719678]' Body: [* // Select kb for a scenario editor := CKBEditor::Create(); componentmds := ComponentMDS::CreateForLoadedMDSsOnly( Application ); mdsinstance := selectobject( componentmds, ComponentMDSKinds.ComponentMDSInstances, m, m.MDSID().Equals( scenario.DatasetMDSID() ) ); mdshandle := mdsinstance.GetMDSHandle(); editor.SelectMDSKB( mdshandle, kbfullid ); ScenarioManager.UpdateScenarioKBInfo( scenario, kbfullid.Name(), kbfullid.Branch(), kbfullid.ChangeNr(), scenario.State(), scenario.KBDescription() ) *] }