| Quintiq file version 2.0 | 
| #parent: #root | 
| Method PTF_TestSelectScenario ( | 
|   output Real duration_o, | 
|   output String response_o, | 
|   String scenarioname | 
| ) as Boolean id:Method_LibPTF_pnlTestRunner_PTF_TestSelectScenario | 
| { | 
|   #keys: '[136682.0.314444068]' | 
|   Body: | 
|   [* | 
|     issuccessful := false; | 
|      | 
|     scenario := select( ScenarioManager, ScenarioNode.astype( Scenario ), scenario, scenario.Name() = scenarioname ); | 
|      | 
|     preconditionflag := not isnull( scenario ); // Your precondition before executing the action | 
|      | 
|     if( preconditionflag ) | 
|     { | 
|       startprecisionctr := OS::PrecisionCounter(); | 
|      | 
|       SelectionScenario.Data( scenario ); | 
|      | 
|       duration_o   := this.PTF_GetDurationInMilisecond( startprecisionctr ); | 
|       response_o   := 'Select scenario' ; | 
|       issuccessful := true; | 
|     } | 
|     else | 
|     { | 
|       response_o := 'PTF_TestSelectScenario: Precondition failed because scenario not found'; // Your precondition failed reason | 
|     } | 
|      | 
|     return issuccessful; | 
|   *] | 
| } |