TO:    All Users
FROM:  Protoview Technical Support


    Here is an OWL sample program that shows how to manipulate the 
statusline in your application.  The key to this process is getting
a view handle to the statusline.  This is done in the StatusLi.cpp
constructor procedure.  The call

        hStatLine = vwGetView(HWindow);

will get you the view handle where hStatLine is of type VIEW and HWindow
is predefined for you by OWL.

    Once you have the view handle, make it global to other dialogs and
windows.  I chose to declare hStatLine extern in other module procedures.
Now that you have the view handle, the protoview function call

        vwSetViewDSLText(hStatLine,"Your message here.");

puts the text into the statusline. Note, ProtoGen+ created a previous
function call

        vwSetStatusLineID();

to IDC_STATUS1.

        This also shows how you can manually update an edit field in the 
statusline for further statusline messages.  You need to associate a
variable with the edit field (select DATA ELEMENTS from the workbench).
I chose Status2 as this variable.  Note that ProtoGen+ will generate the
variable as a class member variable to StatusLi.cpp.  This will cause a
LINK error if you try to declare Status2 extern in other modules.  To get
by this, in DATA ELEMENTS tell PG+ to NOT DEFINE this variable.  PG+ will
still generate a 

        vwSetFieldVar()

call, so it is imperative that you define it elsewhere.  I defined it
at the top of StatusLi.cpp, where it is not a class member variable.  In
this manner, Status2 can be declared extern in other modules.  Now all
that is needed are the two function calls

        lpstrcpy(STATUS2,"Your text here.");
        vwDoAppToScr(hStatLine,IDC_EDIT1);

to update this statusline.

        In order to understand the difference between the two, IDC_STATUS1
will automatically receive DSL messages from menu items while IDC_EDIT 
will not.







