| Home | Previous Lesson: Course 3:: Session 27 :: Page 150 Next Lesson: Course 3:: Session 27 :: Page 170 |
Creating Language-neutral ScriptsUse syntax 2 of the Open(), OpenSheet(), OpenWithParm() and OpenSheetWithParm() functions. You can open windows by sending the window name as a string argument to these functions. For example, to open window 'w_login', you can use Open() function in the following two ways: // Syntax 1 Open( w_login ) // Syntax 2 String ls_WindowName ls_WindowName = 'w_login' Open( w_login, ls_Window ) The second syntax is useful when you don't know the window name at design time and want to open a different window dynamically. In the above example, the window name is hard coded. In multilingual application development, call LanguageDependent() function to get the appropriate object name for the local language and send that value as an argument to the Open() function. For example: Open( w_login,
guo_Language_Manager.LanguageDependent( & If you deploy the application in French language, LanguageDependent() returns 'w_login_f'. Similarly use LanguageDependent() function for OpenUserObject() and OpenUserObjectWithParm() functions also. Similarly call LanguageDependent() to get DataWindow object names when you want to assign DataWindow objects dynamically. // In the Open event of a
Window To refer to menus from window events/functions, refer to the MenuID instead of menu name. |
| Home | Previous Lesson: Course 3:: Session 27 :: Page 150 Next Lesson: Course 3:: Session 27 :: Page 170 |