580 likes | 732 Views
Studio Web App Technology: Overview and Concepts. Dr. Caroline Wilkins www.artificia.co.uk www.RescuePet.org.uk Fred Haislmaier Omnis Development Group, LLC www.odgllc.com. Agenda Concepts Architecture. Component Interface Components Remote Forms Remote Tasks Deployment
E N D
Studio Web App Technology:Overview and Concepts Dr. Caroline Wilkins www.artificia.co.uk www.RescuePet.org.uk Fred Haislmaier Omnis Development Group, LLC www.odgllc.com
Agenda Concepts Architecture Component Interface Components Remote Forms Remote Tasks Deployment Masterclass demo HTML Interface Remote Tasks Deployment Cookies
Web App Technology • What is it???
Web App Technology • Web App Technologyis an Omnis based technology that allows • the visual aspect of a program to be separated from the procedural part. • Responds to and generates HTML forms/pages
Web App Technology • The visual aspect can be instantiated on: • The same machine as the server • A machine on the same intranet • A machine on the internet
Web App Technology • The visual aspect is instantiated with: • Netscape on Win, Mac, OSX and Linux Netscape use Plugin • Internet Explorer Win - Active X Mac - Netscape Plugin • All browsers - HTML • Other Programs - HTML
Internet Architecture Database Server • Web Server (IIS/Apache) • Web Server plug-in • Omnis Studio Runtime • Omnis Library • Database Client • Browser • Webclient plug-in
Internet Architecture Database Server • Web Server (IIS/Apache) • Web Server plug-in • Omnis Studio Runtime • Omnis Library • Database
Internet Architecture Database Server • Web Server (IIS/Apache) • Web Server plug-in • Omnis Studio Runtime • Omnis Library • Database
Internet Architecture Database Server • Web Server (IIS/Apache) • Web Server plug-in • Omnis Studio Runtime • Omnis Library • Database
Internet Architecture Database Server • Web Server (IIS/Apache) • Web Server plug-in • Omnis Studio Runtime • Omnis Library • Database
Positioning • Well defined audience
Positioning • Well defined audience • Security
Positioning • Well defined audience • Security • Ease of implementation
Positioning • Well defined audience • Security • Ease of implementation • Ease of deployment
How is it different • Provides an “Application Environment” instead of HTML or Java forms
How is it different • Provides an “Application Environment” instead of HTML or Java forms • Uses Standard HTTP protocols
How is it different • Provides an “Application Environment” instead of HTML or Java forms • Uses Standard HTTP protocols • Does not show users what is on the back end.
Developing remote form applications Dr. Caroline Wilkins www.artificia.co.uk www.RescuePet.org.uk Fred Haislmaier Omnis Development Group, LLC www.odgllc.com
Components Remote Forms • Webclient equivalent of windows • Many similar looking components
Components Remote Tasks • Remote form needs a remote task to mediate connections. • Set remote task for a remote form in $designtaskname • Task variables allow you to pass data between remote forms
Components Foreground Components Push button • Formflds component • evClick • Use to trigger a method Icon Runtime
Components Foreground Components Button area • Formflds component • evClick • Use to trigger a method • Invisible - place over a graphic Icon Design
Components Foreground Components Single Line edit and Multi Line edit • Formflds component • evAfter • $enabled - allows user entry • $dataname Icon Design
Components Foreground Components Radio Group • Formflds component • evClick • Use for mutually exclusive options • Assign a numeric variable • Arrangement controlled by • $columncount • $horizontal • Must have Multistate 1 icon page for remote form Icon Runtime
Components Foreground Components Checkbox • Formflds component • evClick • Use for boolean data • Assign a numeric or boolean variable • Must have Multistate 2 icon page for remote form Icon Runtime
Components Foreground Components List • Formflds component • evClick, evDoubleClick • Use for a column list • Displays first column of a list • evClick passes line number in pLineNumber • $::multipleselect allows more than one line at a time to be selected. Icon Runtime
Components Foreground Components Drop List • Formflds component • evClick • Use for a list • $listcolumn specifies which list column to display • evClick passes line number in pLineNumber • selection of multiple lines not possible Icon Runtime
Components Foreground Components Combo Box • Formflds component • evClick • Use for a list or user entry • $::listname specifies drop list options • $dataname contains selection/user entry • $listcolumn specifies which list column to display • evClick passes line number in pLineNumber Icon Runtime
Components Foreground Components Heading List • Formflds component • evClick,evDoubleClick, • evHeaderClick • Use for a list • $listcolumn specifies which list column to display • evClick, evDoubleClick pass line number in pLineNumber • evHeaderClick passes column number in pColumnNumber Icon Runtime
Components Foreground Components Paged Pane • Orfcmain component • Use to create multiple screens on a single remote form • $pagecount - no. of pages • $currentpage - current page displayed • control by Sidebar, Tabbar or in code Icon Runtime
Components Foreground Components Paged Pane Sidebar controlled Tabbar controlled
Components Foreground Components Sidebar • Formsbar component • Use to control paged pane • Sidebar content specified by list in $dataname Icon
Components Foreground Components Tabbar • Formtbar component • Use to control paged pane • evClick • $nosoftab - no. of tabs • $::currenttab - current tab • evClick passes tab number in pLineNumber Icon Runtime
Components Foreground Components Formfile • Formfile component • Use to read/write files on client • evClick • $dataname - contains file data • $filename - default filename displayed for save to disk prompt Icon Runtime
Components Background Components Label Border Tile Wash Icon Runtime
Remote Forms Variables • Can only use instance variables for data fields • Class, Task and # variables can only be used for server side methods • Local and parameter variables can be used within remote form methods
Remote Forms Events • Remote form components only respond to the events that you enable. • This minimises client-server communication
Remote Forms Icon Pages • Some components have optional icons e.g. button • Some components need icons e.g. Radio group • You must configure the iconpages required for each remote form. These are downloaded when the remote form is initialised • You can optimise by creating your own iconpages containing only those icons you need using the Icon Editor
Remote Forms Cursors • $cursor - allows you to set a cursor icon for buttons and button areas • Must have appropriate iconpages selected for remote form
Remote Forms Client Side execution • Use for methods that dont require server or database interaction • Client runs faster (unnecessary communication with server is removed) • Reduces server load Cant use in client side methods: • Class variables • Task variables • # variables
Remote Forms Programming restrictions • The following will lock up the server until user intervention occurs, so dont use: • Working message • Prompt for input • Prompt for data file • Enter data • Be careful to ensure the method is running client side with: • Yes/No message • OK message • Be aware that certain commands will execute server side: • Open window • Install menu • Print report
Remote Forms <html> <head> <title>Remote Form Test - rfShelter</title> </head> <!-- Use for Microsoft --> <!-- ActiveX object START--> <object classid="clsid:13510606-30FA-11D2-B383-444553540000" width="804" height="481"> <param name="_Version" value="65536"> <param name="_ExtentX" value="7161"> <param name="_ExtentY" value="7373"> <param name="_StockProps" value="0"> <param name="OmnisServer" value="5912"> <param name="OmnisLibrary" value="RescueDog"> <param name="OmnisClass" value="rfShelter"> <param name="WebServerURL" value=""> <param name="WebServerScript" value=""> <PARAM NAME="Param1" VALUE="ShelterId=@1012"> </object> <!-- ActiveX object END--> <!-- Use for Netscape --> <!-- Netscape object START--> <embed type="application/OMNIS-RCC-plugin" name="rcc1" width="804" height="481" OmnisServer="5912" OmnisLibrary="RescueDog" OmnisClass="rfShelter" WebServerUrl="" WebServerScript=""> <!-- Netscape object END--> </body> </html> Testing • In development mode, ctrl-T to launch in local browser. • Note that you must have the webclient plug-in installed on your development machine
Remote Forms Remote Form Methods: $senddata • An optimisation technique • $senddata() - sends all instance variables from server to client, occurs by default after an event • $senddata(#NULL) - server will not send back any data to client • $senddata(#NULL,iVar) - server just sends iVar back to client • Will not work for client side execution
Remote Forms Remote Form Methods: $showmessage • Use to pop up an OK message on the client
Remote Forms Remote Form Methods: $showurl(Url,[Framename,BrowserProperties]) • Use to pop up an OK message on the client • Cannot use in the $destruct method of a remote form • BrowserProperties correspond to JavaScript window.open • e.g. ‘menubar=0,scrollbars=1’
Remote Tasks Remote Task properties • $maxtime - maximum time, in minutes, that a client can stay connected (default = 0: indefinite connection) • $timeout - maximum time, in minutes, a client can remain idle (default = 0: indefinite idle time) • $clientaddress - IP address of client • $connectionid - id of current connection (allocated by server) • $connectiontime - date/time of remote task instantiation • $lastresponse - date/time of last client access
The Remote TaskActive X Access <object classid="clsid:13510606-30FA-11D2-B383-444553540000" width="600" height="400"> <param name="_Version" value="65536"> <param name="_ExtentX" value="7161"> <param name="_ExtentY" value="7373"> <param name="_StockProps" value="0"> <param name="OmnisServer" value="5930"> <param name="OmnisLibrary" value="WebForm"> <param name="OmnisClass" value="rfPassword"> <param name="WebServerUrl" value="192.168.33.5"> <param name="WebServerScript" value="/cgi-bin/Omnisapi.dll"> <param name="Param1" value""> <param name="Param2" value""> <param name="Param3" value""> <param name="Param8" value""> <param name="Param9" value""> </object>