Quintiq file version 2.0
#parent: #root
Method NewScenarioFolder (
  internal[GUIComponent] parent,
  ScenarioManager scenariomanager,
  ScenarioFolder selection
) as ScenarioFolder id:Method_ScenarioManager_DialogCreateEditScenarioFolder_NewScenarioFolder
{
  #keys: '[11122.0.37341038]'
  Body:
  [*
    // New scenario folder
    
    result := this.DoModal( parent );
    scenarioFolder := null ( ScenarioFolder );
    
    if ( result > 0 )
    {
      scenarioFolder := scenariomanager.CreateFolder(
                                                      selection,
                                                      EditorScenarioName.Text(),
                                                      EditorComment.Text(),
                                                      guard( SWF_DataHolderCurrentUser.Data().Name(), '' )
                                                    );
    }
    
    return scenarioFolder;
  *]
}
