View
216
Download
0
Category
Preview:
Citation preview
8/19/2019 f Verifica Versa o
http://slidepdf.com/reader/full/f-verifica-versa-o 1/1
!!CB!! 279Function: fVerificaVersao
Description:Returns
Boolean:ParametersStatic VariablesLocal variables
String: sDataProducaoNumber: nAuxString: sProximaVersaoNumber: nTempoAvisoVersao
ActionsIf NOT fMPSPrepareProc( hSqlApp, 'exec MPS..VersaoSistemaS
@Sistema = :_nCodigoSistema',':sDataProducao,:sProximaVersao,:nTempoAvisoVersao')
Return FALSEIf NOT SqlExecute( hSqlApp )
Return FALSEIf NOT SqlFetchNext( hSqlApp, nAux )
Return FALSEIf sDataProducao != _sDataVersao
Call SalMessageBox( 'Esta versão do dia ' || _sDataVersao || ' esta desatualizada', 'Advertencia', MB_Ok )Return FALSE
If SalStrToDate( sProximaVersao ) - SalDateCurrent() <= nTempoAvisoVersao AND SalStrToDate( sProximaVersao ) != DATETIME_Null
Call SalModalDialog( dlgVersao, hWndForm, sProximaVersao, nTempoAvisoVersao )
Return TRUEReturn TRUE
Recommended