Jump to content

REXX Tips & Tricks:Development Tools: Difference between revisions

From EDM2
No edit summary
Ak120 (talk | contribs)
mNo edit summary
 
(4 intermediate revisions by 2 users not shown)
Line 1: Line 1:
These sections contain information about some REXX development tools, e.g. VX/REXX.
These sections contain information about some REXX development tools, e.g. VX/REXX.


(Well, at this time the section about VX/REXX is the only one - but with some help of others there may be more in the future.)  
(Well, at this time the section about VX/REXX is the only one - but with some help of others there may be more in the future.)


==VX/REXX ODK==
==VX/REXX ODK==
'''* Name''' VX/REXX Object Development Tool
See: [[VX-REXX Object Development Kit]]
* '''Version'''
* '''Author''' Watcom
* '''Distrib.''' ?
* '''Type''' Toolkit for C programmers
* '''Price''' -
* '''Source''' Internet
 
* '''Name:''' VXODK.*
* Note /w source
 
This is the Object Development Tool for VX/REXX from Watcom. You need this if you want to build new objects for VX/REXX.
 
Please note that I do not know if the distribution of the toolkit is legal.


==VX/REXX Buglist==
==VX/REXX Buglist==
This section is written & Copyright by [[Bastian Maerkisch]]
This section has been moved to its own page, see: [[Bastian Märkisch]]: [[Inofficial VX-REXX buglist]]
 
====Inofficial VX/REXX buglist (1.08.2001)====
 
---------- * ----------
 
ComboBox / DropDownComboBox object:
 
these objects don't handle the LM_INSERTMULTITEMS PM messages (unlike 'ordinary' PM combo boxes)
 
fix: send this message to child with id 0x instead
 
---------- * ----------
 
ComboBox object:
 
combo boxes no longer accept input from keyboard if they have a 'KeyPress' event routine assigned
 
fix: [if you know any, please submit!]
 
---------- * ----------
 
Accelerators: [feature ;)]
 
accelerators of windows with the 'Visible' property set to '0' don't have their accelerators deactivated.
 
fix: [if you know any, please submit!]
 
---------- * ----------
 
KeyString property:
 
[at least on german keyboards] the comma on the numeric key block is always assigned '{Del}' independent from current NumLock setting
 
fix: [if you know any, please submit!]
 
---------- * ----------
 
PostEvent method: [undocumented bahaviour]
 
'FocusObject' parameter is defined for retrieval by VRInfo [not documented] [there might be even more - not checked]
 
---------- * ----------
 
Button / Verify Event: [feature]
 
if a button has 'NoPointerFocus' set to '1' this disables the generation of 'Verify' events when the button is activated
 
fix: you might consider to fix this behaviour by adding the following code to the button's 'Click' event routine
 
<pre>
AnyButton_click: procedure        /* important: only local signal handler */
    object = VRInfo( "Object" )
    verified = VRInfo( "Verified" )      /* object of previous verify, if any */
    focus  = VRMethod( "Screen", "GetFocusWindow", "Object" )
                                        /* get real focus object */
 
    if VRGet( object, "NoPointerFocus" ) & \        /* handle verifies ? */
      (verified \= focus) & \                      /* verified it before ? */
      (focus \= '') then do                  /* is there a focus object ? */
 
      signal on syntax name AnyButton_Syntax
      verify = VRGet( focus, "Verify" )
      signal off syntax
                      /* rude way to determine if object has a verify event, */
                      /* could have used 'ListProperties' method instead    */
 
      if verify \= '' then do            /* does object have verify event ? */
        ok = VRMethod( focus,  "PostEvent", "Verify" )
                                        /* post verify event to focus object */
        ok = VRMethod( object, "PostEvent", "Click", "Verified", focus_window )
                              /* re-post click event to button  and give    */
                              /* the verify event routine a chance to cancel */
        return
      end
    end
  AnyButton_Syntax:
 
    /* go on with the real work */
    /* ... */
  return
</pre>
---------- * ----------
 
VRLoadSecondary function:
 
standard 'VRLoadSecondary' in section 'Main' generates NoValue exceptions
 
fix: replace VRLoadSecondary in Main section with the following code
 
<pre>
VRLoadSecondary:
      __vrlsWait = abbrev( 'WAIT', translate(arg(2)), 1 )
      if __vrlsWait then
          call VRFlush
      if arg(3,"Exists") then
          __vrlsParent = arg(3)
      else
          __vrlsParent = VRWindow()
      /*    __vrlsParent = VRInfo( 'Window' ) */
      __vrlsHWnd = VRLoad( __vrlsParent, VRWindowPath(), arg(1) )
      if __vrlsHWnd = '' then signal __vrlsDone
      if \ __vrlsWait    then signal __vrlsDone
      call VRSet __vrlsHWnd, 'WindowMode', 'Modal'
      if( symbol('__vrlsWindows.0') \== 'VAR' ) then
          __vrlsTmp = 1
      else
          __vrlsTmp = __vrlsWindows.0 + 1
      __vrlsWindows.__vrlsTmp = VRWindow( __vrlsHWnd )
      __vrlsWindows.0 = __vrlsTmp
      do while( VRIsValidObject( VRWindow() ))
          __vrlsEvent = VREvent()
        interpret __vrlsEvent
      end
      __vrlsTmp = __vrlsWindows.0
      __vrlsWindows.0 = __vrlsTmp - 1
      call VRWindow __vrlsWindows.__vrlsTmp
      __vrlsHWnd = ''
  __vrlsDone:
  return __vrlsHWnd
</pre>
---------- * ----------
 
VX/REXX IDE and ObjectRexx:
 
VX/REXX's routine to retrieve error information from a program 'VRERRTXT' crashes on line 3, no error information
 
---------- * ----------
 
C/S edition bugs
 
---------- * ----------
 
Query object: [severe] the 'RowData' method does not check if there actually is data available; if not calling 'RowData' might cause system hangs!
 
fix: check for data first (e.g. with 'MoveFirst')
 
---------- * ----------
 
Query object and QueryManager:
 
the 'Search' method and QueryManager interpret all colons in SQLStatement as references to variables even if they are inside strings
 
fix: [not known]
 
---------- * ----------
 
QueryManager:
 
query manager can't properly handle references to stem variables in 'SQLStatement'
 
fix: just ignore it - the 'Query' object can handle them
 
---------- * ----------
 
Query object: Bound variables
 
only numeric fields are properly supported by the 'BindVar' method, since no string delimiters are placed around the value. This leads to errors when interpreting the generated events.
 
fix: no general fix - don't use it, use 'RowData' method instead
 
If you really need to use it you might consider the following: Use a specific naming convention for bound variables: e.g. 'BoundVar'xxxx Insert the following code into the main loop in 'Main' section:
 
<pre>
      ...
      do while( \ VRGet( _VREPrimaryWindow, "Shutdown" ) )
        _VREEvent = VREvent()
 
        /* hack for bound vars */
        if abbrev(_VREEvent,'BoundVar',8) then do
          parse var _VREEvent __FixVar__ '=' __FixValue__
          _VREEvent = __FixVar__  "= '" || strip(__FixValue__,'L') || "'"
        end
 
        interpret _VREEvent
      end
      ...
</pre>
[btw.: Does anybody know why it was implemented using events in the first place?]
 
 


==DrDialog Buglist==
==DrDialog Buglist==
See the main [[DrDialog]] listing for known issues.


This section contains a list of known bugs in DrDialog.
[[Category:REXX Tips & Tricks]]
 
"There is a problem running DrDialog programs under Object REXX if they use DrsAide (as shipped) controls. Because Object REXX parses the entire file before running, many times syntax errors which would go undetected under "Classic" REXX are in fact detected. There is just such a syntax error in the DrsAide utility.
 
To fix the problem, open the DRSAIDE.RES file from the DrDialog File Menu option. Double-Click the ICONBUTTON (the only control visible other than the DIALOG). The DrRexx Code editor should appear with the ICONBUTTON section open. Click the "Drop-" tab and use the spin-button under the edit window to bring up the Class code. At the very end, on its own line, type END. Save the file. And now everything should work."
 
Source: [[Thos Davis]]
 
---------- * ----------
 
Note (07/04/2003):
 
The slidercontrols of DrDialog are buggy.
 
Workaround: Use the Scrollbars instead
 
Thanks to [[Klaus Staedtler]] for this information
 
---------- * ----------
 
[[Category:Scripting Articles]]

Latest revision as of 03:52, 16 December 2019

These sections contain information about some REXX development tools, e.g. VX/REXX.

(Well, at this time the section about VX/REXX is the only one - but with some help of others there may be more in the future.)

VX/REXX ODK

See: VX-REXX Object Development Kit

VX/REXX Buglist

This section has been moved to its own page, see: Bastian Märkisch: Inofficial VX-REXX buglist

DrDialog Buglist

See the main DrDialog listing for known issues.