QPR Knowledge Base 2012.1

ChangeCurrentModelingLanguage

ChangeCurrentModelingLanguage

Previous topic Next topic  

ChangeCurrentModelingLanguage

Previous topic Next topic  

Revision history:

Introduced in QPR 7.4.1 SP1

 

Changes the currently active modeling language to the language supplied as a parameter.

 

Synopsis:

 

PGModel.ChangeCurrentModelingLanguage(Language)

 

Parameters:

 

Language: Integer/String. Either a language ID (integer) or a language code (string). The language code is supplied in QPR Modeling Client when adding languages available as modeling languages. In the case the value is 0 or empty, the default modeling language is used.

 

Required Rights:

 

View rights to the process level.

 

Return Values:

Below are listed the return values that this function can return:

 

RV_SUCCESS

RV_APPLICATION_QUIT_CALLED

RV_MODEL_NOT_OPEN

RV_MODEL_DOES_NOT_USE_MULTILINGUAL_MODELING

RV_LANGUAGEID_NOT_FOUND

 

Example Procedure:

 

Sub ChangeLanguage()

 dim iResult

 

 iResult = PGModel.ChangeCurrentModelingLanguage("FIN")

 If iResult <> 0 Then

   MsgBox "Call failed: " + PGApplication.GetErrorMessage(iResult)

 End If

End Sub