Quintiq file version 2.0
#parent: #root
Method GetChangeOfPlanningPeriodAtEditionWarningDialog (
  MacroPlan macroplan,
  PeriodSpecification_MP periodspecification,
  Boolean isusedforplanning,
  DateTime periodalignment,
  Number nroftimeunit,
  String timeunit,
  Number nrofhistoricalperiod,
  Number nroffutureperiod,
  Boolean isnew
) as Boolean id:Method_ApplicationLibMacroPlanner_GetChangeOfPlanningPeriodAtEditionWarningDialog
{
  #keys: '[133004.0.311448611]'
  Body:
  [*
    // Prompt user with warning dialog for action confirmation
    result := true;
    
    if( PeriodSpecification_MP::GetChangeOfPlanningPeriodsAtEdition( macroplan,
                                                                     periodspecification,
                                                                     isusedforplanning,
                                                                     periodalignment,
                                                                     nroftimeunit,
                                                                     timeunit,
                                                                     nrofhistoricalperiod,
                                                                     nroffutureperiod,
                                                                     isnew ) )
    {
      message := Translations::MP_PeriodSpecification_MP_ChangePlanningPeriodDefinition();
      result := MessageBox::Warning( this, message, '&Yes|&No' ) = 0;
    }
    
    return result;
  *]
}
