The popupsharingmenu statement pops up a menu for the toolbar sharing icon.


This statement has one parameter:

operation – operation to perform, or empty for popup menu.


This statement pops up a menu for the toolbar sharing icon (it’s used internally by ProVUE for this purpose). It can also be used with a Text Display object to pop-up the sharing menu within a form (see setbannericon to learn how to do this).

To pop-up the menu, use this statement with an empty parameter, like this:

popupsharingmenu ""

If the parameter is not empty, the pop-up menu will not appear. Instead, Panorama will immediately perform the requested operation, which must be specified from this list: checkconnection, synchronizedata, downloaddata, disconnect, connect, newgeneration.

For example, you could use this code if you wanted to check the database connection as if the user had popped up the menu and picked the Check Server Connection item.

popupsharingmenu "checkconnection"

You could also use the parameter to make your own custom sharing menu, like this limited menu with only 3 items:

let connected = dbinfo("connected","")
let sharingMenu = menu("Sharing","size",11)+
        ?(info("modifiers") contains "option",
            menuitem("Upload Record","IDENTIFIER","uploadrecord","ENABLED",connected),
            menuitem("Lock Record","IDENTIFIER","lockrecord","ENABLED",connected)
        menuitem("Unlock Record","IDENTIFIER","unlockrecord","ENABLED",connected)
    menuitem("Check Server Connection","IDENTIFIER","checkconnection")+
        menuitem("Disconnect from Server","IDENTIFIER","disconnect"),
        menuitem("Connect to Server","IDENTIFIER","connect")
local popChoice
popupclick sharingMenu, "Synchronize Data", popChoice
if popChoice="" return endif
operation = info("menuidentifier") 
popupsharingmenu operation

See Also


10.2NewNew in this version.