• <GetStart>
  • CSPro User's Guide
    • The CSPro System
    • Data Dictionary Module
    • The CSPro Language
    • Data Entry Module
    • Batch Editing Applications
    • Tabulation Applications
    • Data Sources
    • CSPro Statements and Functions
      • Statement Format Symbols
      • Alphabetical List of Functions and Statements
      • List of Reserved Words
      • Deprecated Features
      • Declaration Statements
      • Symbol Functions
      • Item Functions
      • Array Object
      • Audio Object
      • Barcode and QR Codes
      • Case Object
      • Document Object
      • File Object
      • Freq Object
      • Geometry Object
      • HashMap Object
      • Image Object
      • List Object
      • Map Object
      • Path
      • Pff Object
      • SystemApp Object
      • ValueSet Object
      • Program Control Statements
      • Assignment Statements
      • Data Entry Statements and Functions
      • Batch Edit Statements
      • Numeric Functions
      • String Functions
      • Multiple Occurrence Functions
      • General Functions
        • Compress Function
        • Decompress Function
        • diagnostics Function
        • Encode Function
        • ErrMsg Function
        • ExecSystem Function (Desktop)
        • ExecSystem Function (Mobile)
        • ExecPFF Function
        • GetProperty Function
        • GetLabel Function
        • GetLanguage Function
        • GetSymbol Function
        • GetValueLabel Function
        • hash Function
        • htmldialog Function
        • InValueSet Function
        • Invoke Function
        • IsChecked Function
        • loadsetting Function
        • LogText Function
        • MaxValue Function
        • MinValue Function
        • paradata Function
        • PathConcat Function
        • PathName Function
        • savesetting Function
        • SetLanguage Function
        • SetProperty Function
        • SetValueSet Function
        • SetValueSets Function
        • Special Function
        • sqlquery Function
        • Stop Function
        • SysParm Function
        • tr Function
        • Trace Function
        • UUID Function
        • View Function
        • Warning Function
      • Date and Time Functions
      • External File Functions
      • Synchronization Functions
    • Templated Reporting System
    • HTML and JavaScript Integration
    • Action Invoker
    • Appendix
  • <CSEntry>
  • <CSBatch>
  • <CSTab>
  • <DataViewer>
  • <TextView>
  • <TblView>
  • <CSFreq>
  • <CSDeploy>
  • <CSPack>
  • <CSDiff>
  • <CSConcat>
  • <Excel2CSPro>
  • <CSExport>
  • <CSIndex>
  • <CSReFmt>
  • <CSSort>
  • <ParadataConcat>
  • <ParadataViewer>
  • <CSCode>
  • <CSDocument>
  • <CSView>
  • <CSWeb>

ExecSystem Function (Mobile)

Format
b = execsystem(actionʃ, stopʅ);
Description
The execsystem function, on mobile devices (Android), starts another application or executes a task. There is a related version for applications running on desktop CSEntry.
If stop is coded, the application will immediately close after launching the application, in the same way that would occur if using the stop function with an argument of 1.
The string expression action must begin with one of the following commands:
CommandDescription
appOpen another application on the device. (You can get more control using SystemApp instead.)
browseView a website in the Internet browser.
callPlace a phone call.
cameraTake a photo in .jpg or .png format.
gpsView a latitude/longitude point using an installed mapping engine (e.g., Google Maps).
htmlView a website from within CSEntry (equivalent to using the view function).
signatureBring up a screen where someone can sign the mobile device, an image of which can be saved in .jpg or .png format.
smsSend a text message.
viewDisplay an image, play a sound clip, or view a movie (equivalent to using the view function).
Return Value
The function returns a logical value of 1 (true) if the new application or task is started successfully and 0 (false) otherwise.
Examples
execsystem("app:com.google.android.gm"); // open Gmail

execsystem("browse:https://www.census.gov");

execsystem("call:+13017631451"); // call the CSPro support number

execsystem("camera:" + pathconcat(Application, "photo.jpg"));
execsystem("camera:" + pathconcat(Application, "photo.png"));

execsystem("gps:38.84839,-76.931098");
execsystem("gps:38.84839,-76.931098,CSPro Team at the U.S. Census Bureau");

execsystem("html:https://www.census.gov");
execsystem("html:file:///" + pathconcat(Application, "local_webpage.html"));

execsystem("signature:" + pathconcat(Application, "saved-signature.jpg"));
execsystem("signature:" + pathconcat(Application, "saved-signature.png"));

execsystem("sms:+13017631451");
execsystem("sms:+13017631451,Hello, CSPro Team!");

execsystem("view:" + pathconcat(Application, "picture.jpg"));
execsystem("view:" + pathconcat(Application, "audio.mp3"));
execsystem("view:" + pathconcat(Application, "movie.3gp"));
See also: SystemApp Object, ExecSystem Function (Desktop), ExecPFF Function, Multimedia Features, View Function