Talk:Common Class/Notes: Difference between revisions
		
		
		
		Jump to navigation
		Jump to search
		
Kate Racaza (talk | contribs) No edit summary  | 
				Kate Racaza (talk | contribs) No edit summary  | 
				||
| Line 11: | Line 11: | ||
==Example ==  | ==Example ==  | ||
To demonstrate the method's functionality, the   | To demonstrate the method's functionality, the example deliberately returns an error message in Portuguese by connecting to a repository that doesn't exist.  | ||
   '''VBA'''  |    '''VBA'''  | ||
| Line 21: | Line 21: | ||
  {{APIComment|'The following code will deliberately cause the connection to fail and return an error message.}}  |   {{APIComment|'The following code will deliberately cause the connection to fail and return an error message.}}  | ||
    {{APIPrefix|Dim}} MyRepository {{APIPrefix|As New}} Repository  |     {{APIPrefix|Dim}} MyRepository {{APIPrefix|As New}} Repository  | ||
    MyRepository.ConnectToAccessRepository({{APIString|"C:\RSRepositoryx122g3.rsr10"}})  |     MyRepository.ConnectToAccessRepository({{APIString|"C:\RSRepositoryx122g3.rsr10"}})  | ||
| Line 33: | Line 31: | ||
  {{APIComment|'The following code will deliberately cause the connection to fail and return an error message.}}  |   {{APIComment|'The following code will deliberately cause the connection to fail and return an error message.}}  | ||
    {{APIPrefix|Dim}} MyRepository {{APIPrefix|As New}} Repository  |     {{APIPrefix|Dim}} MyRepository {{APIPrefix|As New}} Repository  | ||
    MyRepository.ConnectToAccessRepository({{APIString|"C:\RSRepositoryx122g3.rsr10"}})  |     MyRepository.ConnectToAccessRepository({{APIString|"C:\RSRepositoryx122g3.rsr10"}})  | ||
Revision as of 21:03, 13 January 2016
Sets the language of the Synthesis API library. Messages returned by the Synthesis repository to the API will be displayed in the specified language.
Syntax
.SetLanguage(Language)
Parameters
Language
- Required. The display language. Can be any Language constant.
 
Example
To demonstrate the method's functionality, the example deliberately returns an error message in Portuguese by connecting to a repository that doesn't exist.
VBA 'Set the API's language to Portuguese Dim Lng As New cLanguage Lng.SetLanguage (Language_Portuguese) 'The following code will deliberately cause the connection to fail and return an error message. Dim MyRepository As New Repository MyRepository.ConnectToAccessRepository("C:\RSRepositoryx122g3.rsr10")
VB.NET 'Set the API's language to Portuguese Dim Lng As New cLanguage Lng.SetLanguage (Language.Portuguese) 'The following code will deliberately cause the connection to fail and return an error message. Dim MyRepository As New Repository MyRepository.ConnectToAccessRepository("C:\RSRepositoryx122g3.rsr10")