Lesson 1. The ScreenSurfer Environment Visual Surfer IntroductionLesson 2. 3270/5250 Display Characteristics
 Click on any item to view...
Contents

+Introduction
+Concepts
+Product Positioning
+Operations
+Customization
+SurferScript Guide
ScreenSurfer Tutorial

The ScreenSurfer Tutorial Introduction

Visual Surfer Introduction

Lesson 1. The ScreenSurfer Environment

Lesson 2. 3270/5250 Display Characteristics

Lesson 3. SurferScript Screens and Events

Lesson 4. Basic Customization

Lesson 5. Key ScreenSurfer HTML Tags

Lesson 6. Variables and Expressions

Lesson 7. Logic and control

Lesson 8. Cold Fusion and ASP Co-Servers



This is the first lesson in the ScreenSurfer tutorial.

In this lesson, you will learn about the ScreenSurfer installation directories, how ScreenSurfer works as a Web server and other basics.

As with all tutorial lessons, this page includes a skills access table at the top; throughout the page is a mix of concepts, skills, and exercises--you can come-back at any time to review. Also, throughout

New Skills

ScreenSurfer Folder

When ScreenSurfer is installed on your Windows/NT system, an icon is added to your desktop named "ScreenSurfer" and the graphic associated with it is a "wave". When the ScreenSurfer icon is double-clicked, it opens the "ScreenSurfer Folder". The ScreenSurfer folder can also be accessed by clicking on Start->Programs->Windows Explorer->Click on the hard drive where ScreenSurfer is installed->Click on the ScreenSurfer directory.

ScreenSurfer Folder The ScreenSurfer folder contains the following:
  • Administrator's Console View and control active sessions; change settings
  • HTML Templates Default location for template files
  • ScreenSurfer Control Manual startup of the ScreenSurfer service
  • ScreenSurfer DevCenter Perform development tasks
  • ScreenSurfer Documentation Main access to all of the ScreenSurfer documentation
  • ScreenSurfer Guide Table of contents for the ScreenSurfer Guide
  • Web Gateway Home Page Access the ScreenSurfer Web Gateway (testing, exploration; what users will see)
  • Toy Mainframe Start the Toy Mainframe TN3270 Server

Exercise 1.1

End of Exercise 1.1


ScreenSurfer Directories

ScreenSurfer is installed on your Windows/NT system in a single directory tree. The organization of the directory is as follows:
Understanding the ScreenSurfer directory (folder) structure /ScreenSurfer/
The ScreenSurfer root folder--installed on the drive you specified during installation. Contains readme.txt file, the ScreenSurfer "wave" sound file and three sub-folders.

    /ScreenSurfer/bin
    Contains the primary ScreenSurfer executable, "ielua.exe" and the ScreenSurfer service control applet, "surfer.exe." These files may be executed from the command line, but surfer.exe is typically started from the ScreenSurfer folder or ScreenSurfer start programs entry.

    /ScreenSurfer/ScreenSurfer Folder
    This is a holding directory, or folder, for the icons and other shortcuts used for the Windows user interfaces.

    /ScreenSurfer/HostServer
    The root folder for the ScreenSurfer runtime environment. This is the default location for log files. Contains five subfolders:

      /ScreenSurfer/HostServer/Templates
      Default location of all customization templates for ScreenSurfer. Files in this folder typically have the file extension .STML. At startup and on request, ScreenSurfer compiles the template files in this directory to create the runtime environment for delivering enhanced 3270-to-HTML applications.

      /ScreenSurfer/HostServer/Img
      Default location for image files, such as .GIF and .JPG files used in ScreenSurfer HTML pages and user-defined pages.

      /ScreenSurfer/HostServer/C_Samples
      Sample C extensions directories. ScreenSurfer enables the implementation of C-based Dynamic Link Libraries (DLL's) which extend the ScreenSurfer <TEDATA> and <TEAREA> tags. This enables very high performance custom screen translations integrated with the ScreenSurfer tag-based development environment.

      /ScreenSurfer/HostServer/Extensions
      Where extension DLL's created from the C_Samples directory are placed. At start-up, ScreenSurfer enumerates this directory and loads each DLL found within it. Each DLL provides ScreenSurfer with information about the extensions it supports at load time.

      /ScreenSurfer/HostServer/Events
      If you have any time-driven or other background event sections, their output when executed will be written to static HTML files in this directory. An example of this kind of TESECTION is one that executes every morning at 6am.

      /ScreenSurfer/HostServer/docs
      The ScreenSurfer static HTML resource root directory. All user static HTML pages and any accompanying resources should be placed in subdirectories off of the "docs" directory. Contains two system folders:

        /ScreenSurfer/HostServer/docs/DevTool
        Where the HTML and JavaScript files reside for the ScreenSurfer DevCenter application. The UserDefs.JS file is provided for users to define the menus and resources for DevCenter extensions.

        /ScreenSurfer/HostServer/docs/Guide
        Contains the static HTML pages used to provide the ScreenSurfer Guide.

Exercise 1.2

End of Exercise 1.2


ScreenSurfer Registry Entries

By accessing the ScreenSurfer Administration Console (described later in this lesson), you can change ScreenSurfer settings from a formatted HTML form which includes integrated help links. While this is the recommended way to manage ScreenSurfer behavior, it is useful to understand where you can go to make changes directly, should that be necessary at any time.

Accessing ScreenSurfer Registry Entries To view and/or update ScreenSurfer Registry entries, perform the following steps:
  1. Open a command window from the Start Button
  2. Enter the command REGEDIT
  3. Click on HKEY_LOCAL_MACHINE
  4. Click on Software
  5. Click on Intelligent Environments
  6. Click on ScreenSurfer
There are a number of keys off of the ScreenSurfer "hive" which control characteristics of ScreenSurfer, including the access key, user security and so on. The Config entry has the most values under it; by clicking on any of the subkeys, you can browse the entries and learn what settings are available beyond those offerred in the Settings page.

Exercise 1.3

End of Exercise 1.3


The ScreenSurfer Service
The ScreenSurfer primary application program is a standard Windows/NT Service. A Windows/NT Service is a special program designed for use in server or memory-resident background applications. There are two interfaces available on a ScreenSurfer machine for starting ScreenSurfer: The Control Panel Services Applet and the ScreenSurfer Service Control Panel.

Changing ScreenSurfer Service Settings The Control Panel Services Applet is a generic interface to all Windows/NT Services, and is accessed by:
  1. Clicking on the Start Button
  2. Sliding the mouse up to "Settings"
  3. Sliding the mouse up to "Control Panel"
  4. Double-clicking on the "Services" icon (two gears)

Once the services applet is displayed, you select the ScreenSurfer service and select start. You also use the services applet to change startup settings for ScreenSurfer. For example, you can change whether or not ScreenSurfer starts automatically each time the system is started or rebooted. You also change the UserID and Password to be used for the ScreenSurfer process.

Exercise 1.4

End of Exercise 1.4


The ScreenSurfer Service Control Panel is provided with ScreenSurfer and is accessed either by the Start Button or the ScreenSurfer folder which is installed on the Desktop. To load the ScreenSurfer Service Control Panel:

  1. Click on the Start Button
  2. Slide the mouse to the Programs entry
  3. Slide to the ScreenSurfer/Service Control Panel

The Service Control Panel will always open the ScreenSurfer folder and for the first three times will open the ScreenSurfer readme.txt file in a Notepad window.

Starting ScreenSurfer in Diagnostic Mode A key feature of the ScreenSurfer direct control panel (besides the fun graphics) is the ability to execute ScreenSurfer in Diagnostic mode. The diagnostic mode of ScreenSurfer provides immediate feedback to you as ScreenSurfer initializes, with text logged to the console for each stage of initialization. In addition to the visual feedback provided in diagnostic mode, ScreenSurfer automatically performs host connection logging to the file \ScreenSurfer\hostserver\surfdiag.log.

Exercise 1.5

  • Double-click on the ScreenSurfer icon on the Desktop
  • Double-click on the ScreenSurfer control icon
  • Click on the ScreenSurfer service
  • Click on the Start button on the ScreenSurfer Service Control window (you will hear a series of "beeps" and watch what happens to the sky!)...This starts the ScreenSurfer service
  • Click on the Stop button to stop the ScreenSurfer service (you will hear a series of "beeps" and watch what happens to the sky now! )...This stops the ScreenSurfer service
  • Click on the "Diagnostic Mode" box and click on the Start button and a command prompt window titled "ScreenSurfer Diagnostic Execution Window" is displayed
  • Enter "Y" to Clear Log File (this clears the \ScreenSurfer\hostserver\surfdiag.log file)
  • Information listed in the "ScreenSurfer Diagnostic Execution Window" is the following:
    • You can use Ctrl-C to manually stop the ScreenSurfer service
    • Lists the current version of ScreenSurfer (i.e. 2.0.5M GA)
    • Identifies that ScreenSurfer has read the registry entries
    • "ScreenSurfer Executable IELUA.EXE Successfully Started" identifies that the ScreenSurfer service has successfully started
    • "Processing Host Group Configuration Entries..." initializes and performs DNS searches for machine(s) defined in the Administrator's Console
    • "Compiling Templates..." will compile templates in the specified template directory (specified in the ScreenSurfer DevCenter)
    • "Opening Web Server Port..." opens the HTTP port specified in the Administrator's Console (default is port 80)
    • "Opening Console Port..." opens the console port which is the port for the Administrator's Console and the DevCenter specified in the Administrator's Console (default is 81)
    • "***ScreenSurfer Version...Ready for Requests***" states that ScreenSurfer is now ready for sessions to be "started" and the ScreenSurfer web server to be accessed!

End of Exercise 1.5

You can Create log files at any time using the Administration Console Settings page, but using the diagnostic mode is a quick and direct method of logging, particularly for troubleshooting a new installation.

Working with ScreenSurfer Support Personnel on Protocol problems ScreenSurfer host protocol log files are important resources in trouble-shooting both host connection problems as well as improperly translated screens (where the generated HTML is not correct for a given host screen). You can add a new ticket to the ScreenSurfer SupportCenter and then email your log file to surfer@ieinc.com using the new ticket number in the subject line. ScreenSurfer support personnel can then use your host protocol log file to determine the nature of the problem and provide assistance, a work-around or a code update to resolve the problem.

When you execute ScreenSurfer in diagnostic mode (see above), the file /ScreenSurfer/hostserver/surfdiag.log is created: this is the file you should e-mail to surfer@ieinc.com...

Exercise 1.6

  • Access the Support Center ScreenSurfer SupportCenter http://support.ScreenSurfer.com/support
  • Enter your email address that you specified when you originally downloaded ScreenSurfer
  • Enter your password (this was emailed to you when you downloaded ScreenSurfer)
  • Press Logon
  • Under "Available Actions" click on "Find a Customer"
  • Tab to the last entry field and type in keywords in your company name
  • Press Search
  • See people from your company that have downloaded ScreenSurfer
  • Close the window
  • Under "Available Actions" click on "Logoff"
  • Close browser window

End of Exercise 1.6


Browser Access to ScreenSurfer

ScreenSurfer is a Web-based product, meaning that while the primary executable code installs and executes on a Windows/NT Server or Windows/NT Workstation, all of the user interfaces involved in defining, accessing and developing ScreenSurfer can run on any workstation that can host one of the following browsers:

  • Netscape Communicator Version 4 (or higher)
  • Microsoft Internet Explorer Version 4 (or higher)
Access to the Web Gateway port can be any HTML browser, including text-only browsers although this is dependent on the level of HTML you choose to implement in your ScreenSurfer HTML templates.

As a developer working with ScreenSurfer on the same machine (this is the only configuration supported for the free developer's license), you typically access ScreenSurfer resources using the local machine address of 127.0.0.1.

During installation, access to the key ScreenSurfer resources is defined both off the Start button as well as the ScreenSurfer folder.

Accessing Key ScreenSurfer features with your Browser It is recommended that you add bookmarks in your Web Browser for the key areas provided by ScreenSurfer. The easiest way to set your browser bookmarks (or "favorites") is to start ScreenSurfer using the Console (see above), which brings the ScreenSurfer folder to the foreground. Then, click on the following icons one at a time. After selecting access, use the browser bookmark or favorites feature to add the newly displayed page to your browser's bookmark list.
  • Administrator's Console View and control active sessions; change settings
  • ScreenSurfer DevCenter Perform Development Tasks
  • Web Gateway Home Page Access the ScreenSurfer Web Gateway (testing, exploration; what users will see)

Exercise 1.7

End of Exercise 1.7


ScreenSurfer Template Editing

ScreenSurfer templates are standard ASCII files which are a combination of HTML tags, text and ScreenSurfer HTML tag extensions. We call this combination of HTML and HTML tag extensions SurferScript.

The quickest and most direct way to edit ScreenSurfer templates is through the "HTML Folder" that is found in the installed ScreenSurfer folder (should be visible directly on your Desktop). Open this folder by double-clicking, and then double-click on the template you wish to edit. All ScreenSurfer templates have an extension of .STML which indicates to the ScreenSurfer compiler that the file contains SurferScript. The first time you double-click to open an STML file, you may be asked to associate an editor with the STML extension. For the purposes of Folder interaction, the Notepad.exe program makes a good choice; you may also specify another editor if you have a preference.

Where are the Template files?
The template files all reside in a single directory by default, which is specified in the DevCenter Administration Settings page. Following installation, this directory is "/ScreenSurfer/hostserver/templates". When you create a new file in this directory, it will automatically be compiled the next time you start ScreenSurfer or request a compile from the DevCenter, simply by having the .STML extension.

You can also specify a list of files which may reside in one or more directories by creating a file list and specifying that in the DevCenter Administration Settings Page. To specify a file list, you prefix the file path and name with the "@" symbol, as in:

   @d:\ScreenSurfer\hostserver\mytemplates\compile.lst
The "compile.lst" file then would contain one line for each directory, individual template file or additional list files you want compiled, in the order in which you want them compiled. This is a standard text file that you can create with any editor, such as notepad. For example, it could look like:
d:\ScreenSurfer\hostserver\mytemplates\global.stml
d:\ScreenSurfer\hostserver\mytemplates\personal.stml
d:\ScreenSurfer\hostserver\mytemplates\inventory.stml
d:\ScreenSurfer\hostserver\mytemplates\orders.stml
d:\ScreenSurfer\hostserver\joeswork
This will compile four files in the mytemplates directory, as well as all the files in the directory joeswork. Note that duplicate files are not compiled; the first file of a given name encountered during the compile will be used and any subsequent duplicates will be flagged with a warning by the compiler and ignored.

Note that in addition to directories and full file names, you can also include additional listing files, once again identifying them with the leading @ symbol.

What's in a Template File

Each ScreenSurfer template contains one or more Sections of SurferScript; the sections of SurferScript are identified with the <TESECTION> tag. When you edit a ScreenSurfer template, you are typically working with the same kind of text you are working with when composing and editing HTML pages; there are just more than one "pages" in a single template.

Editing ScreenSurfer Templates Since ScreenSurfer template files contain basically HTML tags and HTML tag extensions, you can edit them using any editor or composer you would typically use for HTML editing. A recommended editor for this purpose is Allaire HomeSite, which can be downloaded for trial use from the Allaire Web Site. HomeSite has extensible tag definitions, and a set of HomeSite extensions specifically designed for development in SurferScript are planned for availability during 1998 (you can also create your own fairly quickly to produce a tab containing your "favorite" SurferScript tag extensions).

Another simple HTML editor is the development editor in Microsoft's Visual C++ or VisualDev environment which has good HTML editing characteristics (with color coding of tags, comments and so on). If you have no editor available, the Windows "Notepad" editor will do in a pinch, although it lacks many features that will make your life easy as you work with multiple and/or large template files.

Lesson #4 of this tutorial, Basic Customization contains more details on how you can use a variety of techniques to both generate template sections with the DevCenter and create/modify sections with editors.

Organizing Template Files
Lesson #3 describes how template sections (identified using the <TESECTION> tag) are executed due to a ScreenSurfer Event. At this point in the tutorial, it is important to understand that you should organize the sections and group them appropriately.

Another key feature to understand is that you can define sections of re-usable code with a very simple <TESECTION name> tag, you can identify a block of SurferScript which can be executed in any template using <TEPUTSECTION templatename.sectionname>.

Understanding template section organization Some template organization guidelines:

  • Realize that that a template file is a development component; variable and section names are "local" in many cases to a template file
  • Try to align template files with expected patterns of development; don't mix a business transaction screen in the same template as the logon screen, for example
  • Group sections around functional areas. You may even have a single template for each screen, containing the screen event section along with a number of supporting sections.
  • Use re-usable sections whenever possible and the <TEPUTSECTION> tag to call them

Exercise 1.8

End of Exercise 1.8

Visual Surfer IntroductionLesson 2. 3270/5250 Display Characteristics