Help / Developing for iOS (iPhone / iPad)
  • Overview
  • How to?
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Stored procedures
A global procedure in WLanguage can be directly called from the code of a global procedure in Objective C.
How to?
To call a WLanguage procedure directly from the code of a global procedure in Objective C:
  1. Type the code of WLanguage procedure. The WLanguage procedure must comply with some rules:
    • Have an acceptable name in Objective C.
    • The type of procedure parameters and the type of return value must be supported types: boolean, integer, real, string, buffer.
    • The "ObjC" attribute must be added to the WLanguage procedure.
  2. Then simply call the procedure from the Objective C code.

Example: Procedure for adding 1 to the specified number:
  • WLanguage code:
    PROCEDURE nWL_AddOne(n is int), ObjC: int
    RESULT n+1
  • Objective C code:
    int nObjC_ResultInt(int i)
    return nWL_AddOne(i);

Example: Procedure for displaying text:
  • WLanguage code:
    PROCEDURE MyProcedure(psMessage is string), ObjC: string
    RETURN psMessage
  • Objective C code:
    void ios_Call_Proc()
    MyProcedure(@"My text");
Minimum version required
  • Version 19
Click [Add] to post a comment

Last update: 06/09/2023

Send a report | Local help