Tags

    Default Functions: 29

    _FmNx_Base64Decode( base64_string; format )

    With this function you can now extract a binary file that has been transmitted using xml.
    Base64Decode has 2 parameters:
    • base64_string
    • format
    format can be an extension or a full filename (only jpeg/gif/png/bmp/pdf have previews)


    _FmNx_Base64Encode( binary_data )

    Encode data to be transmitted to your web service.
    Base64Encode has 1 parameters:

    binary_data

      encode any binary data which will then allow you to send it over XML.



      _FmNx_GetPref( key )

      Preferences have been greatly simplified in the 2.0 release. Now instead of having preferences at the global, WSDL, and WSDL function level you now have them only globally. This means that if you need to have some preferences set before you execute a particular WSDL function, then you should include those settings in your script. For example, you might need to send some authentication headers as part of your request. In this case, you would be setting the user and password information before you execute any other function calls. This has also reduced the number of functions that we have to support and the number of functions you have to learn about.
      Possible keys include:
        • wsdl_count
        • wsdl_names
        • function_count
        • function_names
        • function_prototypes
        • verbose
        • host
        • port
        • wsdl:user
        • wsdl:password
        • wsdl:timeout

      wsdl_count returns the number of WSDLs installed
      Example:
      _FmNx_GetPref( “wsdl_count” )
      Returns 4 if 4 WSDLs were installed

      wsdl_names returns the names of all the WSDLs installed
      Example:
      _FmNx_GetPref( “wsdl_names” )
      Returns the list of WSDL names (example assumes you have only 4 WSDLs installed)
      xQuotes
      Demographics
      PhoneNotify
      SMSNotify
      function_count returns the number of WSDL functions installed
      Example:
      _FmNx_GetPref( “function_count” )
      Returns 82 for the 4 WSDLs installed

      function_names returns the function names of each installed function
      Example:
      _FmNx_GetPref( “function_names” )
      Returns 82 function names
      NOTE: the list is reduced to only show a few entries to save space
      SMS_GetCountryCodes
      xQuotes_GetChartDesign
      PhoneNotify_CancelNotify
      Demographics_GetIncomeHouseValueByAddress …

      function_prototypes returns the function name and parameters of each installed function
      Example:
      _FmNx_GetPref( “function_prototypes” )
      Returns 82 function prototypes (and yes those would be 82 new FileMaker functions you could use)
      NOTE: the list is reduced to only show a few entries to save space
      SMS_GetCountryCodes( EmailAddress; UserID; Password )
      PhoneNotify_LM_AddNewList( ListName; ParentListID; LicenseKey )
      xQuotes_GetChartDesign( Username; Password; Tracer ) …

      verbose returns “true” or “false”. This is helpful when debugging what is sent and returned by the request. On a Mac it can be viewed using the console application. By default this option is set to “true”.
      Example:
      _FmNx_GetPref( “verbose” )
      Returns “true” if previously setwith
      _FmNx_SetPref( “verbose=true” )

      host returns the host ip address of request's destination.
      Example:
      _FmNx_GetPref( “host” )
      Returns "125.168.26.36” if previously setwith
      _FmNx_SetPref( “host=125.168.26.36” )

      port returns the destination port number of the request.
      Example:
      _FmNx_GetPref( “port” )
      Returns “591” if previously setwith
      _FmNx_SetPref( “port=591” )

      Note: in the following 3, you would substitute the WSDL name in the place of “wsdl”

      wsdl:user – [required format] – returns the user name associated with this WSDL.
      Example:
      _FmNx_GetPref( “xQuotes:user” )
      Returns “fmnexus” if previously setwith
      _FmNx_SetPref( “xQuotes:user=fmnexus” )

      wsdl:password[required format] – returns the password associated with this WSDL
      Example:
      _FmNx_GetPref( “xQuotes:password” )
      Returns “abc123” if is was previously setwith
      _FmNx_SetPref( “xQuotes:password=abc123” )

      wsdl:timeout – needs to be supplied in this format – returns the timeout value in seconds.
      Example:
      _FmNx_GetPref( “xQuotes:timeout” )
      Returns “10” if is was previously setwith
      _FmNx_SetPref( “xQuotes:timeout=10” )





      _FmNx_Load_WSDL( wsdl_name; wsdl_document )


      This function allows you the ability to dynamically load the WSDL functions. Because you can load the WSDL functions dynamically from fields, you don't need to worry about also distributing the WSDLs to each client. For example you could have a table with 2 fields; the WSDL name, and the WSDL data. Your script could then loop over all these records and automatically load the functions. As soon as you have loaded the functions from the WSDL, they become instantly available in your solution.

      Note: the WSDL name can be set to anything you would like it to be. Sometimes it is a good idea to keep it short as there is little space available in the External functions list to view the WSDL name and its function name. But once you have started using the WSDL with the name you have selected, don't change it because your function references will not be able to be resolved. View information about the WSDL used in this example.

      Download Download file "n2t.zip" example file to experiment with this function.
      Load_WSDL has 2 parameters:
      • wsdl_name: text - the name of the WSDL
      • wsdl_document: text - the entire contents of the WSDL you wish to load

      Example:
      _FmNx_Load_WSDL( “n2t”; WSDL::data )
      Result: Loads the following 2 functions as FileMaker native functions - Ready to be used!
      n2t_NumberToDollars( NumberToDollars_dNum )
      n2t_NumberToWords( NumberToWords_ubiNum )





      _FmNx_Register( license_key; owner )

      This function is used to register your FM::Nexus Web Services Plug-in
      Register has 2 parameters:
        • license_key
        • owner
      Example:

      _FmNx_Register( "WEB-2.0-YWXL-LTL1-Y9UI-T17F1"; "FM Nexus" )

      Result: Returns "Success" if valid and "Error: Invalid license number or owner name"






      _FmNx_Reload_All

      This function can be used to load new WSDL functions. Drop a new WSDL file in your WSDL directory (which should be located at the root of your Extensions directory), and call this function to load its functions to become instantly available as FIleMaker native functions. Lets say you wanted to dynamically load the functions available to you from the Demographics WSDL provided by CDYNE.
      Important: WSDLs that you put into the WSDL directory should have the extension of .xml or .wsdl
      Example:

      _FmNx_Reload_All

      Result: Returns "Loaded: Demographics" followed by the list of function prototypes.
      Download file "sample_result.txt"






      _FmNx_SetPref( key=value[, key=value[, ...]] )

      Set Preferences allow you to set the following perferences
      Keys that can be set are:
        • verbose = true/false
        • host = url
        • port = number
        • wsdl:user = text string
        • wsdl:password = text string
        • wsdl:timeout = number (seconds)

      verbose set to true will output incoming and outgoing requests to the console on the Mac.
      Example:

      _FmNx_SetPref( "verbose=true" )


      host sets the url you would like the transaction to be sent to.
      Normally you never have to set this as the WSDL knows where to send the request.

      Example:
      _FmNx_SetPref( "url=<some url>" )


      port sets the port you would like the transaction to be sent to.
      Normally you never have to set this as the WSDL knows where to send the request.

      Example:
      _FmNx_SetPref( "port=591" )


      wsdl:user sets user name that will be sent in the headers
      Note: some WSDLs require authentication - using set preferences lets you sent the required header attributes.

      Example: "abc" is the name of the WSDL, and "tony" is the user name
      _FmNx_SetPref( "wsdl:user= abc:tony" )


      wsdl:password sets the password that will be sent in the headers
      Note: some WSDLs require authentication - using set preferences lets you sent the required header attributes.

      Example: "abc" is the name of the WSDL, and "top_secret_password" is the password
      _FmNx_SetPref( "wsdl:password=abc:top_secret_password" )


      wsdl:timeout sets the timeout value in seconds.

      Example: "abc" is the name of the WSDL, and the timeout is set to 10 seconds.
      _FmNx_SetPref( "wsdl:timeout=abc:10" )






      _FmNx_Unload( wsdl_name )

      This function will remove the all the WSDL functions for the specified WSDL
      Example:
      _FmNx_Unload( "Demographics" )
      Result: Returns "Unloaded wsdl: Demographics" followed by the list of functions removed.

      Download file "unload result.txt"






      _FmNx_Version( short/long )

      This function returns the version number of the FM::Nexus Web Service Plug-in.
      Example:
      _FmNx_Version( "short" )
      Result: "2.0"
      Example:
      _FmNx_Version( "long" )
      Result: "FM.NEXUS - Web Services 2.0"

      Comments

      /groups/ws/search/index.rss?tag=hotlist/groups/ws/search/?tag=hotWhat’s HotHotListHot!?tag=hot0/groups/ws/sidebar/HotListNo items tagged with hot.hot/groups/ws/search/index.rss?sort=modifiedDate&kind=all&sortDirection=reverse&excludePages=wiki/welcomelist/groups/ws/search/?sort=modifiedDate&kind=all&sortDirection=reverse&excludePages=wiki/welcomeRecent ChangesRecentChangesListUpdates?sort=modifiedDate&kind=all&sortDirection=reverse&excludePages=wiki/welcome0/groups/ws/sidebar/RecentChangesListmodifiedDateallRecent ChangesRecentChangesListUpdateswiki/welcomeNo recent changes.reverse5search