'
'This chapter menu
'^^^^^^^^^^^^^^^^^^^^^^
'
'!short:Abort (e) --> do_nothing
'!short:AboutOff (lKeepCursor) --> true/false
'!short:AboutOn (cProgName,nVersion,nYear,[cUser],[cAuthor]) --> true
'!short:ATailDel (aArray) --> xDeletedItem
'!short:ATrueDel (aArray,[nPosition]) --> xDeletedItem
'!short:ATrueIns (aArray,[nPosition],[xValue]) --> aArray
'!short:AValid (oGet,aArray,[bBlock],[lEmptyAllowed]) --> true/false
'!short:AWidth (aArray,[bWidth]) --> nWidth
'!short:BlueDanu () --> nil
'!short:BoxShadow (nRow,nCol,nRow2,nCol2,[cColor]) --> true
'!short:CanEditHelp (new) --> true/false
'!short:Color2Num (cColor,[lSwap]) --> n_DOS_Attr
'!short:Convert (cOldPsw,LenField,lScramble) --> cNewPassword
'!short:CopyOneDbf (cName) --> copy_of_OneDbf
'!short:ChangeAssoc (Txt,VarName,N) --> true/false
'!short:CreateIndex (e,lContinue) --> true/false
'!short:DateLimit (cDate) --> nil/old_cDate
'!short:DaysInMonth (Month,Year) --> nDays
'!short:DbfValid (cName,oGet,cDbfName,[nOrder],bBlock,[lEmpty]) --> true/false
'!short:DoBreak (o) --> do_nothing
'!short:DOut (cMsg) --> nil
'!short:EditGetMsg (oGet,[lCanEdit]) --> true
'!short:EditGet (oGet,[lCanEdit]) --> true
'!short:EditIt (xValue,cMsg,cPicture,[nRow],[nCol],[cColor],[lIsPsw]) --> xRetVal
'!short:ErrorMessage (oError) --> cDescription
'!short:FInfoShow (FName,R,C,Rs,Cs,Clr,Shadow) --> true/false
'!short:GetActiveMenu () --> current_active_menu_object
'!short:GetAlias (cFullFileName) --> a:\dir\ALIAS.dbf
'!short:GetBack (cColor) --> cBackColor
'!short:GetField (cFullFieldName) --> sel->FIELD
'!short:GetFore (cColor) --> cForeColor
'!short:GetKey (nSecs) --> nInkeyCode
'!short:GetLastDbf () --> last_object_of_Dbf
'!short:GetNewRepName () --> new_report_name
'!short:GetOneDbf (cName) --> object_of_OneDbf
'!short:GetSelect (cFullFieldName) --> SELECT->fld
'!short:GetTList () --> TList
'!short:GetVList () --> VList
'!short:GetWList () --> WList
'!short:GoodBye () --> true
'!short:GoodRun (cmd) --> true
'!short:HelpAssoc (Txt,VarName,N) --> N
'!short:HelpField () --> true/false
'!short:HelpKeys () --> true/false
'!short:HelpReserved (nNew,nAdd) --> nOldValue
'!short:IEval (nCount,bBlock) --> xValue
'!short:IncludeFunctions () --> true
'!short:InKeyWait ([nSecs]) --> nKey
'!short:ListAsArray (cList,[cDelimiter]) --> aList
'!short:LogClear () --> true/false
'!short:LogOff () --> true/false
'!short:LogOn () --> true/false
'!short:LogSet (nUsers) --> nUsers
'!short:Memo (bVar,lEdit,[cTitle],[R],[C],[RSize],[CSize],[CurSize],[Clr],[lShd])
'!short:MidStr (S,l,r) --> cString
'!short:NetCreateFrom (cFile1,cFile2,[lContinue]) --> true/false
'!short:NetDbAppend ([lContinue]) --> true/false
'!short:NetDbCreate (cFile,aStructure,[lContinue]) --> true/false
'!short:NetDbDelete ([lContinue]) --> true/false
'!short:NetDbRecall ([lContinue]) --> true/false
'!short:NetDbUseArea (new,rdd,db,a,shex,ro,[lContinue]) --> true/false
'!short:NetFErase (cFile,[lContinue]) --> true/false
'!short:NetFLock ([lContinue]) --> true/false
'!short:NetIndexOn (cFile,cKey,[bKey],[lUnique],[lContinue]) --> true/false
'!short:NetLimit (new) --> old
'!short:NetPack ([lContinue]) --> true/false
'!short:NetReIndex ([lContinue]) --> true/false
'!short:NetRLock ([lContinue]) --> true/false
'!short:NetSetIndex (cListFiles,[lContinue]) --> true/false
'!short:NetZap ([lContinue]) --> true/false
'!short:OAlert (cMessage,[aOptions],[nRow]) --> nChoice
'!short:ObjectDone ([lContinue]) --> true
'!short:ObjectInit ([clr],cPrgName,nVersion,nYear,[cUser],[cAuthor],[cLine]) --> nil
'!short:PageLength ([nNewRows]) --> nOldRows
'!short:PauseKey ([nSecs]) --> nKey
'!short:PopBreak () --> code_block
'!short:PrintCodes (cCtrlCode) --> true
'!short:PrintFile (cFileName) --> nil
'!short:PrintOff () --> nil
'!short:PrintOn () --> nil
'!short:PushBreak (Br) --> nil
'!short:ReadHelpVar (vn) --> VarName
'!short:RefreshRow () --> nil
'!short:RefreshTable () --> nil
'!short:RepaintDesktop () --> nil
'!short:RestartTask () --> true/false
'!short:RestDatabase () --> nil
'!short:RestDOut () --> nil
'!short:RestHelpIdx () --> true
'!short:RestScr (aScreenArray) --> true
'!short:SaveDOut (cMsg) --> nil
'!short:SaveHelpIdx (aNewIdx) --> true
'!short:SaveScr ([nRow1],[nCol1],[nRow2],[nCol2]) --> aScreenArray
'!short:SetDateTime ([lNew]) --> true/false
'!short:SetDialog ([lNew]) --> true/false
'!short:SetDMsg ([cNew]) --> true/false
'!short:SetErrFile ([cNewFileName]) --> cOldFileName
'!short:SetHelpIdx ([lNew]) --> true/false
'!short:SetLastKey (nKey) --> nKey
'!short:SetLastTask ([<NewTask>]) --> task_object
'!short:SetMemoWrap ([lNew]) --> true/false
'!short:SetQuickEsc ([lNew]) --> true/false
'!short:SetShowText ([lNew]) --> true/false
'!short:SetShowTime ([lNew]) --> true/false
'!short:ShowText ([cNew]) --> cOld
'!short:ShowTime ([cNewTime]) --> cCurrentTime
'!short:SkipDeleted() --> true/false
'!short:StuffKey (nKey) --> true
'!short:StuffKeys (cKeys) --> true
'!short:SwapColor (cColor) --> cSwappedColor
'!short:SwapDatabase (cAlias, nOrder) --> nil
'!short:SwapEGALines() --> nil
'!short:SwapVGALines() --> nil
'!short:TestAllDbfReIndex () --> true
'!short:TopBreak () --> code_block
'!short:UserID ([cUserID]) --> cUserID
'!short:UserLevel (new) --> nUserLevel
'!short:UserNo (new) --> UserNo
'!short:WEval (bExpression,bBlock) --> true/false
'
'
'####################################################################################
!short:Abort (e) --> do_nothing
^BAbort (e) --> do_nothing:
~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Displaying of error allert text and quitting of the program, an emergency
program exit.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
e: Can be an error_object, or text string to display as error allert.

Return value:
~~~~~~~~~~~~~
nil.

Source code is in file  Errorsys.prg.

!seealso:


'####################################################################################
!short:AboutOff (lKeepCursor) --> true/false
^BAboutOff (lKeepCursor) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Restores the screen saved by AboutOn().

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lKeepCursor: If true, the cursor is restored to size and shape of saved when
             AboutOff() was called.

Return value:
~~~~~~~~~~~~~
true - if the screen was saved by AboutOn()
false - nothing to restore the AboutOn() function was not called

Source code is in file  Object1.prg

!seealso: AboutOn


'####################################################################################
!short:AboutOn (cProgName,nVersion,nYear,[cUser],[cAuthor]) --> true
^BAboutOn(cProgName,nVersion,nYear,[cUser],[cAuthor]) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
1.The screen is stored for restoring by AboutOff()
2.Initial sytem window is painted
3.Clipper switch set to default value(date,confirm,...)
4.Help system activation
5.System necessary classes registration
6.Date and time request.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cProgName: program name to be painted in big capitals to initial screen
nVersion:  program version number
nYear:     creation year
cUser:     registered user name
cAuthor:   author name (symbol)

Return value:
~~~~~~~~~~~~~
allways true.

Source code is in file  Object1.prg

!seealso: AboutOff


'####################################################################################
!short:ATailDel (aArray) --> xDeletedItem
^BATailDel(aArray) --> xDeletedItem:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Last array element delete.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
aArray: the array identifier of which last element should be deleted

Return value:
~~~~~~~~~~~~~
deleted element value.

Source code is in file  Object3.prg

!seealso: ATrueDel ATrueIns


'####################################################################################
!short:ATrueDel (aArray,[nPosition]) --> xDeletedItem
^BATrueDel(aArray,[nPosition]) --> xDeletedItem:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Selected array element delete.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
aArray:    array of which is the element to delete
nPosition: element to delete position, if none the last element is to delete.

Return value:
~~~~~~~~~~~~~
deleted element value.

Source code is in file  Object3.prg

!seealso: ATailDel ATrueIns


'####################################################################################
!short:ATrueIns (aArray,[nPosition],[xValue]) --> aArray
^BATrueIns(aArray,[nPosition],[xValue]) --> aArray:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
the value xValue is inserted to aArray to nPosition. The elements above index
nPosition are moved one position higher, the array size is incremented by 1.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
aArray:    array to which is the element to insert
nPosition: position, where to insert the xValue, the default value is to
           insert to the last array position.
xValue:    value to be inserted to array, default nil.

Return value:
~~~~~~~~~~~~~
array incremented by one element

Source code is in file  Object3.prg

!seealso: ATailDel ATrueDel


'####################################################################################
!short:AValid (oGet,aArray,[bBlock],[lEmptyAllowed]) --> true/false
^BAValid(oGet,aArray,[bBlock],[lEmptyAllowed]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Current value Get:VarGet() is validated, if not valid the choose of valid
array values is offered to user to select the right value. Selected value is
written to Get object (Get:VarPut(...)). When testing if the Get:VarGet()
is valid, is it compared with value of expression Eval(bBlock,e), where e
is obtaining the values of aArray.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
oGet:          clipper object of GET class
aArray:        valid items array for comparing with Get:VarGet()
bBlock:        code block converting the aArray elemnet to value for
               comparation with Get:VarGet(). default is {|e|e} - no
               conversion direct compare
lEmptyAllowed: if true the valid data for Get:VarGet is the result of
               function Empty(Get:VarGet()), else the Get:VarGet() value
               must be in aArray.

Return value:
~~~~~~~~~~~~~
true  if the value is valid
false if the value is not valid.

Remarks:
~~~~~~~~
Tato funkcia pouziva object vytvoreny z triedy Choice.

Source code is in file  Object3.prg

!seealso: DbfValid c_choice.ngo:Choice


'####################################################################################
!short:AWidth (aArray,[bWidth]) --> nWidth
^BAWidth(aArray,[bWidth]) --> nWidth:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
returns the aArray width (for array of strings the length of the longest
string in array).

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
aArray:  any array (default is array of strings)
bBlock:  code block for aArray element to its length conversion,
         default is {|e|Len(e)}

Return value:
~~~~~~~~~~~~~
aArray width

Source code is in file  Object3.prg

!seealso: ListAsArray ATrueDel ATailDel ATrueIns


'####################################################################################
!short:BlueDanu () --> nil
^BBlueDanu () --> nil:                                                           :
~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Plays a Blue Danube valtzer until a key is pressed.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
nil

Source code is in file  Object3.prg.

!seealso: GoodBye


'####################################################################################
!short:BoxShadow (nRow,nCol,nRow2,nCol2,[cColor]) --> true
^BBoxShadow(nRow,nCol,nRow2,nCol2,[cColor]) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
the shadow is painted around the window with coordinates nRow,nCol,nRow2,
nCol2 in cColor.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nRow:   upper window border
nCol:   left window border
nRow2:  bottom window border
nCol2:  right window border
cColor: shadow color, default is border (third SetColor() item)

Return value:
~~~~~~~~~~~~~
true

Source code is in file  Object3.prg

!seealso: ListAsArray c_box.ngo:Box c_win.ngo:Win c_window.ngo:Window


'####################################################################################
!short:CanEditHelp (new) --> true/false
^BCanEditHelp (new) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Get-set function for enabling - disabling of help text editation.
If (without parameters) returns true, the editation is enabled, if false it
is disabled. Default value is true (editation enabled).

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
new: true or false.

Return value:
~~~~~~~~~~~~~
true/false.

Source code is in file  Object2.prg.

!seealso: HelpField HelpAssoc ChangeAssoc ReadHelpVar HelpReserved


'####################################################################################
!short:Color2Num (cColor,[lSwap]) --> n_Byte_DOS_Attr
^BColor2Num(cColor,[lSwap]) --> nByte_DOS_Attr:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Clipper (char) color to numerical DOS color conversion.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cColor:     value for conversion
lSwap:      if true, the foreground with background colors are exchanged,
            default is false

Return value:
~~~~~~~~~~~~~
DOS color attribute

Source code is in file  Object3.prg

!seealso: BoxShadow


'####################################################################################
!short:Convert (cOldPsw,LenField,lScramble) --> cNewPassword
^BConvert (cOldPsw,LenField,lScramble) --> cNewPassword:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Encryption or decryption (according of the lScramble value) of cOldPsw
password variable, with ascii character simple shift. The return value
length is set to LenField.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cOldPsw:   Text string for decryption.
LenField:  Decrypted string length.
lScramble: True if to decrypt, false if to encrypt.

Return value:
~~~~~~~~~~~~~
Decrypted/encrypted text string.

Source code is in file  c_dbf.prg.

!seealso: c_dbf.ngo:Dbf c_menu.ngo:Menu


'####################################################################################
!short:CopyOneDbf (cName) --> copy_of_OneDbf
^BCopyOneDbf (cName) --> copy_of_OneDbf:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
In last defined Dbf class object is such OneDbf class object searched for,
which o:Name is equal to recieved parameter. If it is found, it returns
its copy, if not the process is aborted.


Parameter description:
~~~~~~~~~~~~~~~~~~~~~
cName: object name (Alias() of some opened database file) which is to search
       for in last defined class Dbf object.

Return value:
~~~~~~~~~~~~~~~~~~
object_of_OneDbf

Source code is in file  c_dbf.prg.

!seealso: c_dbf.ngo:Dbf


'####################################################################################
!short:ChangeAssoc (Txt,VarName,N) --> true/false
^BChangeAssoc (Txt,VarName,N) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
It enables to assign a new index to help database to some asociation string
describing edited variable (usualy a edited variable name). The edited
variable can be assigned a name for help window title.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
Txt:     association string, system name of edited variable
VarName: user name of edited variable (title)
N:       index (RecNo()) to help database

Return value:
~~~~~~~~~~~~~
true if the exchange was succesffull, false if the association string Txt
was not found in array Association.(Association is a static array defined
in Object2.prg, filled by HelpAssoc(...) function.

Source code is in file  Object2.prg.

!seealso: HelpAssoc ReadHelpVar HelpField


'####################################################################################
!short:CreateIndex (e,lContinue) --> true/false
^BCreateIndex (e,lContinue) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
New index file is created, its data are set according array e, it is network
capable. If the creation failed and lContinue is true it returns false, if
lContinue is false, it can continue in a program only if creation was success.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
e:         {cName,cFile,cKey,lUnique}:
           cName: menu item name to activate the index,
           cFile : index file name,
           cKey: index key,
           lUnique indicates if the index is unique.
lContinue: if true, we can continue even when the index was not created

Return value:
~~~~~~~~~~~~~
True if creation succeeded, otherwise false.

Source code is in file  c_dbf.prg.

!seealso: c_dbf.ngo:Dbf


'####################################################################################
!short:DateLimit (cDate) --> nil/old_cDate
^BDateLimit (cDate) --> nil/old_cDate:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
It is get-set function, (if activated without a parameter, it returns last
stored value, if activated with a parameter it is stored). If no date is set
it returns nil (the program will operate even without set date). If the set
date is less then system date the program is aborted after setting of the
password.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cDate: date as a text string (example: DateLimit("31.12.92"))

Return value:
~~~~~~~~~~~~~
nil

Example:
~~~~~~~~
 function Main(...)            //your program begin
   ...
   NetLimit(1)                 //one user at time
   DateLimit("31.12.99")       //program will be operatible till 31.12.1999
   ...
   object oD of Dbf init ...
   ...


Source code is in file  Object3.prg.

!seealso:


'####################################################################################
!short:DaysInMonth (Month,Year) --> nDays
^BDaysInMonth (Month,Year) --> nDays:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
For a given month count its days.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
Month: month as a number 1 .. 12
Year:  year set as four digits (i.g. 1992), if nothing set, is taken from
       Date()

Return value:
~~~~~~~~~~~~~
number of days of set month

Source code is in file  Object3.prg.

!seealso:


'####################################################################################
!short:DbfValid (cName,oGet,cDbfName,[nOrder],bBlock,[lEmpty],[aFields]) --> true/false
^BDbfValid(cName,oGet,cDbfName,[nOrder],bBlock,[lEmpty],[aFields])  --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Current value Get:VarGet() is validated, if not valid the window with
valid data to select (from database cDbfName) is diplayed.Selected value is
written to Get object (Get:VarPut(..)). When validating of the Get:VarGet()
the database cDbfName is seeked. After the end of search is the status of
databases before the activating of this command restored.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cName:         displayed data window name
oGet:          clipper object of GET class
cDbfName:      seeked database alias name
nOrder:        if set then before the seek is the SET ORDER TO nOrder command
               performed(setting of the active index).
bBlock:        code block to return the value for storing to Get object.
               When performing this code block the selected database is
               cDbfName and RecNo() points to selected record.
lEmpty:        if true the valid data for Get:VarGet is also the result of
               function Empty(Get:VarGet()), otherwise Get:VarGet() must be
               found in the database cDbfName.
aFields:       Array of strings with field_names (column names) of database
               cDbfName, whitch are to be displayed for selection, if invalid
               field value was entered.

Return value:
~~~~~~~~~~~~~
true  if the data value is valid
false if the data value is not valid

Remarks:
~~~~~~~~
This function uses the object of UpBrowse class.

Source code is in file  Object3.prg

!seealso: AValid c_updbro.ngo:UpDBrowse


'####################################################################################
!short:DoBreak (o) --> do_nothing
^BDoBreak (o) --> do_nothing:
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Performs immediately the BREAK command.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
o: error_object which if set is passed as a parameter to the command

Return value:
~~~~~~~~~~~~~
nil

Source code is in file  errorsys.prg.

!seealso: PushBreak PopBreak ob_comma.ngo:"BEGIN BREAK"


'####################################################################################
!short:DOut (cMsg) --> nil
^BDOut(cMsg) --> nil:
~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
If it is enabled to write to dialog line, the centered text is written there.
The text is stored by later use with function SetDMsg(). The colors are
m->Color:Menu[nNormal], the SetColor() remains unchanged , the cursor too.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cMsg:  text to write to dialog line

Return value:
~~~~~~~~~~~~~
nil

Remarks:
~~~~~~~~
Use of dialog line can be disabled by SetDialog() function.

Source code is in file  Object3.prg

!seealso: SetDialog SaveDOut RestDOut


'####################################################################################
!short:EditGetMsg (oGet,[lCanEdit]) --> true
^BEditGetMsg(oGet,[lCanEdit]) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The help text is written to dialog line, help system is set on and the Get
object can be viewed or edited. (EditGet() is activated)

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
oGet:     clipper object to view / edit.
lCanEdit: true if the editation of GET object is enabled.

Return value:
~~~~~~~~~~~~~
true

Remarks:
~~~~~~~~
Use of dialog line can be disabled by the function SetDialog().

Source code is in file  Object3.prg

!seealso: EditGet HelpKeys


'####################################################################################
!short:EditGet (oGet,[lCanEdit]) --> true
^BEditGet(oGet,[lCanEdit]) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Get object value can be edited or viewed. This function replaces the original
Clipper system GETSYS.prg .

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
oGet:     clipper object to view / edit.
lCanEdit: true if the edit of GET object is enabled.

Return value:
~~~~~~~~~~~~~
true

Remarks:
~~~~~~~~
This functiion was written because the original GETSYS.prg was too slowly.

Source code is in file  Object3.prg

!seealso: EditGetMsg HelpKeys


'####################################################################################
!short:EditIt (xValue,cMsg,cPicture,[nRow],[nCol],[cColor],[lIsPsw]) --> xRetVal
^BEditIt (xValue,cMsg,cPicture,[nRow],[nCol],[cColor],[lIsPsw]) --> xRetVal:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
It enables to edit the desired value in a window. It is usedfor single data item
entry. For example date and time set, record number to GOTO ...

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
xValue:      value to edit
cMessage:    text as edited value name
cPicture:    picture maskfor edited value
nRow:        row to place the editing window, default is the center of the
             screen.
nCol:        column to place the editing window, default is the center of
             the screen.
cColor:      window color, default is m->Color:Edit
lIsPasword:  if true, the '*' are displayed instead of entered characters
             to protect the password set

Return value:
~~~~~~~~~~~~~
edited value

Remarks:
~~~~~~~~
It requires the public non Clipper object m->Color to exist to take the
colors from it.

Source code is in file  Object3.prg

!seealso: EditGetMsg EditGet HelpKeys ob_basic.ngo:m->Color c_color.ngo:Color


'####################################################################################
!short:ErrorMessage (oError) --> cDescription
^BErrorMessage (oError) --> cDescription:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The description of clipper object of Error class is generated, it is standard
clipper function (see the manuals)

Source code is in file  ErrorSys.prg

!seealso: ob_comma.ngo:"BEGIN BREAK" ob_comma.ngo:BREAKIF


'####################################################################################
!short:FInfoShow (FName,R,C,Rs,Cs,Clr,Shadow) --> true/false
^BFInfoShow(FName,R,C,Rs,Cs,Clr,Shadow) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
  It enables to select the file after the FName mask and to view it by
  the FInfo class object. The R,C,Rs,Cs,Clr,Shadow  parameters are
  transferred down to method Init of Box class. They give position,
  size and color of viewed file window. The window title is created
  by function FinfoShow() by the selected filename.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
FName   select mask
R       upper window border row
C       left window border column
Rs      number of window rows (without the border and the shadow)
Cs      number of window columns (without the border and the shadow)
Clr     clipper color definition (text string)
Shadow  logical value to set the window shadowed (true) or no

Return value:
~~~~~~~~~~~~~
the function returns true if there was selected correct file to view, and
performed the FInfo class object.

Source code is in file  C_FInfo.prg

!seealso: c_finfo.ngo:FInfo


'####################################################################################
!short:GetActiveMenu () --> current_active_menu_object
^BGetActiveMenu() --> current_active_menu_object:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Returns the active manu object. (usualy single for a program)

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
akctive menu object

Source code is in file  C_Menu.prg

!seealso: c_menu.ngo:Menu


'####################################################################################
!short:GetAlias (cFullFileName) --> a:\dir\ALIAS.dbf
^BGetAlias (cFullFileName) --> a:\dir\ALIAS.dbf:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The filename is extracted from the pathname and extension.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cFullFileName: full file name with pathand extension.

Return value:
~~~~~~~~~~~~~
sole file name as alias for a database file opening.

Source code is in file  Object3.prg

!seealso: GetField GetSelect


'####################################################################################
!short:GetBack (cColor) --> cBackColor
^BGetBack (cColor) --> cBackColor:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
From set colors extracts the background color.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cColor: clipper string color

Return value:
~~~~~~~~~~~~~
background color part

Example:
~~~~~~~~
? GetBack("w/n+")   //outputs: "n+"

Source code is in file  Object3.prg

!seealso: GetFore SwapColor


'####################################################################################
!short:GetField (cFullFieldName) --> sel->FIELD
^BGetField (cFullFieldName) --> sel->FIELD:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
From full filedname takes only the name of the field.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cFullFieldName: full database fieldname (select->field)

Return value:
~~~~~~~~~~~~~
only the field part without the select part of fieldname

Example:
~~~~~~~~
? GetField("select->field")   //outputs: "field"

Source code is in file  Object3.prg

!seealso: GetSelect GetAlias


'####################################################################################
!short:GetFore (cColor) --> cForeColor
^BGetFore (cColor) --> cForeColor:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
From set colors extracts the foreground color.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cColor: clipper string color

Return value:
~~~~~~~~~~~~~
foreground color part

Example:
~~~~~~~~
? GetFore("w/n+")   //outputs: "w"

Source code is in file  Object3.prg

!seealso: GetBack SwapColor


'####################################################################################
!short:GetKey (nSecs) --> nInkeyCode
^BGetKey (nSecs) --> nInkeyCode:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
It replaces the clipper function InKey(), but when waiting for keypressing
is the time displayed (if enabled by SetShowTime()), and the text set by
ShowText() function is displayed (if enabled by SetShowText()).

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nSecs: number of seconds to wait for a keypressing if 0 - unlimited wait,
       if nil - no waiting.

Return value:
~~~~~~~~~~~~~
nInkeyCode: keypressed code, if no key pressed returns 0

Source code is in file  Object3.prg

!seealso: ShowText ShowTime SetShowTime SetShowText


'####################################################################################
!short:GetLastDbf () --> last_object_of_Dbf
^BGetLastDbf() --> last_object_of_Dbf:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Returns current (last defined) Dbf class object.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
current (last defined) Dbf class object.

Source code is in file  C_Dbf.prg

!seealso: c_dbf.ngo:Dbf


'####################################################################################
!short:GetNewRepName () --> new_report_file_name
^BGetNewRepName () --> new_report_file_name:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The unique filename for report storing is created from first four characters
"SysR" following with four digits, to produce the dos - unique filename in
current directory, with TXT extension.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
unique filename for the report.

Source code is in file  c_info.prg.

!seealso: c_info.ngo:Info c_finfo.ngo:FInfo c_report.ngo:Report


'####################################################################################
!short:GetOneDbf (cName) --> object_of_OneDbf
^BGetOneDbf(cName) --> object_of_OneDbf:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The object of OneDbf class is searched, which database is opened in cName
workarea, cName is alias name for the area. If found returns the object,
if not returns nil.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cName  alias - selects the area for OneDbf class object

Return value:
~~~~~~~~~~~~~
object of OneDbf class or nil


Source code is in file  C_Dbf.prg

!seealso: c_dbf.ngo:Dbf


'####################################################################################
!short:GetSelect (cFullFieldName) --> SELECT->fld
^BGetSelect (cFullFieldName) --> SELECT->field:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Full fieldname select part is extracted.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cFullFieldName: full database fieldname (select->field)

Return value:
~~~~~~~~~~~~~
select part of the fieldname

Example:
~~~~~~~~
? GetSelect("select->field")   //outputs: "select"

Source code is in file  Object3.prg

!seealso: GetField GetAlias


'####################################################################################
!short:GetTList () --> TList
^BGetTList() --> TList:
~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
  The Tlist array is returned (all task class derived objects and its
  children stack).

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
all task class derived objects and its children stack

Source code is in file  C_Task.prg.

!seealso: c_task.ngo:Task


'####################################################################################
!short:GetVList () --> VList
^BGetVList() --> VList:
~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Returns View objects stack.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
view objects stack


Source code is in file C_View.prg

!seealso: c_view.ngo:View


'####################################################################################
!short:GetWList () --> WList
^BGetWList() --> WList:
~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Returns the array used as windows stack. The active window should be on the
top.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
Window class alive object list

Source code is in file  c_window.prg

!seealso: c_window.ngo:Window


'####################################################################################
!short:GoodBye () --> true
^BGoodBye () --> true:
~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The text "Good Bye" is written to the screen and the song is playing till
the keypressed.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true

Source code is in file  Object3.prg.

!seealso: BlueDanu


'####################################################################################
!short:GoodRun (cmd) --> true
^BGoodRun (cmd) --> true:
~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Clipper RUN command is performed in indenpendent module to optimise
the memory usage.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cmd: parameter send to command line interpreter (COMMAND.COM).

Return value:
~~~~~~~~~~~~~
true

Source code is in file  Objec4.prg.

!seealso:


'####################################################################################
!short:HelpAssoc (Txt,VarName,[N]) --> N
^BHelpAssoc (Txt,VarName,[N]) --> N:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The unique system name of Txt variable and its user name VarName and
the index to help database are stored to to Association array. This array
is used by the HelpField() function as context sensitive help text for
current edited field or menu item. If N was set, all parameters are appended
to Association array, if not, N is searched in the array for.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
Txt:    System (unique) identifier;
        there are following names used by the library:
          ALIAS->FIELD    for each database field
          SYS:->VARNAME   memory variables used for the objects of ABrowse
                          class
          MEMORY->VARNAME where the varname is the name of the memory
                          variable used in methods AddBlock(...) of Browse
                          class and its descendants.
VarName: is the user name displayed in help window as its title.
N:       is the index to help database, which text is written to the help
         window.

Return value:
~~~~~~~~~~~~~
help database index

Source code is in file  Objec2.prg.

!seealso: ChangeAssoc HelpField HelpReserved ReadHelpVar


'####################################################################################
!short:HelpField () --> true/false
^BHelpField () --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Context sensditive help for edited data or current menu item, selected from
Association array by the function HelpAssoc(ReadHelpVar()).

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil, activated commonly by SHIFT_F1.

Return value:
~~~~~~~~~~~~~
True, if the help text was found and displayed.

Source code is in file  Object2.prg.

!seealso: ReadHelpVar HelpAssoc ChangeAssoc HelpKeys


'####################################################################################
!short:HelpKeys () --> true/false
^BHelpKeys () --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
This function is activated when user pressed F1 key or SHIFT-F1. It presents
the used keys description as help for the user. Displayed are the text
strings selected by SaveHelpIdx() funct.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true

Remarks:
~~~~~~~~
The text strings are stored in twodimensional array in HelpKeys() function.
Displayed are the subarrays selected by the SaveHelpIdx(). The input
parameter is the index list to array of text strings inside of HelpKeys().

Example:
~~~~~~~~
     SaveHelpIdx( {1,2,5,6} )
     HelpKeys()
     RestHelpIdx()
     ...
The SaveHelpIdx() function stores the current information about the subarrays
to display, and prepares the subarrays 1,2,5 and 6 to be displayed by
HelpKeys(). Activating of it is the help text dispplayed (the subaarrays
1,2,5 and 6). The restHelpIdx() function restores the previous status of
help displaying.

Source code is in file  Object2.prg

!seealso: SaveHelpIdx RestHelpIdx


'####################################################################################
!short:HelpReserved (nNew,nAdd) --> nOldValue
^BHelpReserved (nNew,nAdd) --> nOldValue:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Have a look on the following eexamples:

HelpReserved(nNew)
There are nNew items reserved in help database for your aplication.
The RecNo() of help databse will be 1 .. nNew.

HelpReserved(,nAdd)
The reserved items are appended with next nAdd items.

HelpReserved()
It returns the numbr of reserved items in help database.

Warning!
The initioalising of objects of Dbf,View,Mnu classes causes the reeservetion
of items in help database. If you want to have your own memvars and help text
conected to them, make the reservation before the object of Dbf class is
created. By HelpAssoc() function dd the variable name and other parameters
to Association array, and after the creation of GET object select the right
get:Name to be identical and unique with your variable name.

Example:
~~~~~~~~
//creation of a help
HelpAssoc("MEMORY->MYVAR",My variable",HelpReserved(,+1))
object oD of Dbf init ...   //databse object created
...
...
//creation and editation of My variable
LOCAL MyVar:=Space(10)
LOCAL g:=GetNew(....)
g:Name:="MEMORY->MYVAR"
EditGet(g) //the library OBJECT.lib maintains the help system function
...


Return value:
~~~~~~~~~~~~~
number of reseved help database items

Source code is in file  Objec2.prg.

!seealso: HelpField HelpAssoc ChangeAssoc ReadHelpVar HelpKeys


'####################################################################################
!short:IEval (nCount,bBlock) --> xValue
^BIEval (nCount,bBlock) --> xValue:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~

repeats nCount times performing of code block bBlock.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nCount:  number of repetitions of performing the bBlock
bBlock:  the code block to perform nCount times

Return value:
~~~~~~~~~~~~~
the result of last code block performing

Remarks:
~~~~~~~~
It is a form of FOR loop.

Example:
~~~~~~~~
     IEval(3,{|i|QQOut(i)})
     ...
Writes the numbers 1, 2 a 3.

Source code is in file  Object3.prg

!seealso: WEval


'####################################################################################
!short:IncludeFunctions () --> true
^BIncludeFunctions () --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
It serves for linking all useable functions to the *.exe file to make
them useable in user index and filters definitions.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true

Source code is in file  Object3.prg.

!seealso:


'####################################################################################
!short:InKeyWait ([nSecs]) --> nKey
^BInKeyWait ([nSecs]) --> nKey:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The same as InKey(), but if it was pressed a key which activates a code block
set by SetKey(), this code block is performed. Inkey() only returns the key
code InkeyWait() returns it too and if there is assigned code block it is
performed.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nSecs: time (in seconds) how long to wait for a keypressing

Return value:
~~~~~~~~~~~~~
keypressed code

Example:
~~~~~~~~
     SetKey(K_F1,{||HelpKeys()})
     ? InKeyWait(0)
     ...
It hangs on the F1 key the function HelpKeys() and waits for a keypressing.
if there was pressed a F1 key the HelpKeys() function is performed and the
inkey code of F1 code is printed, if there was other key pressed (without
assigned a function), only a pressed key code is printed.

Source code is in file  Object3.prg

!seealso: PauseKey StuffKey StuffKeys SetLastKey


'####################################################################################
!short:ListAsArray (cList,[cDelimiter]) --> aList
^BListAsArray (cList,[cDelimiter]) --> aList:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The string is converted to an array.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cList:      text string to convert
cDelimiter: elements delimiter, default is ','

Return value:
~~~~~~~~~~~~~
array of elements created from a text string

Example:
~~~~~~~~
     x:=ListAsArray("a,b,c,d")  //x:={"a","b","c","d"}
     ...

Source code is in file  Object3.prg


'####################################################################################
!short:LogClear () --> true/false
^BLogClear () --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Clears the counter of working users.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true if the counter was cleared

Remarks:
~~~~~~~~
Counter is a ViewID field in the first record in OBasic1.dbf

Example:
~~~~~~~~
    select OBasic1
    Go 1
    ? Obasic1->ViewID   //the current working users number is printed

Source code is in file  Object3.prg

!seealso: LogOn LogOff


'####################################################################################
!short:LogOff () --> true/false
^BLogOff () --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Decrements the current number enabled to work by one.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true if it was success to decrement by one

Remarks:
~~~~~~~~
Counter is the ViewId field of first record in OBasic1.dbf. After first
starting of the program it is Performed LogOn() automaticaly, after finishing
of program the LogOff(). The LogXXX functions are used for reindex after first
running when a emergency (aborted) finish of the program was detected.
The most interesting use of LogXXX functions is in Dbf class in method Open()
If you end the program indenpendently by own quit command, don't forget to
perform the LogOff() befor a quit. More conveenient is to let the program
to end it by itself.

Example:
~~~~~~~~
    LogOff()
    ? "Quitting..."
    quit

Source code is in file  Object3.prg

!seealso: LogOn LogClear c_dbf.ngo:Dbf


'####################################################################################
!short:LogOn () --> true/false
^BLogOn () --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Increase of the user counter by one.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true if increasing of the user counter was done, otherwise false.

Remarks:
~~~~~~~~
Counter is the ViewId field of first record in OBasic1.dbf. After first
starting of the program it is Performed LogOn() automaticaly, after
finishing of program the LogOff(). The LogXXX functions are used for
reindex after first running when a emergency (aborted) finish of the
program was detected. The most interesting use of LogXXX functions
is in Dbf class in method Open(). If you end the program indenpendently
by own quit command, don't forget to perform the LogOff() befor a quit.
More conveenient is to let the program to end it by itself.

Source code is in file  Object3.prg

!seealso: LogOn LogClear c_dbf.ngo:Dbf


'####################################################################################
!short:LogSet (nUsers) --> nUsers
^BLogSet (nUsers) --> nUsers:
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
If performed without parameters, it returns the current working user
count, if performed with parameter, the max. user working the same time
is set.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nUsers:

Return value:
~~~~~~~~~~~~~
number of concurent working users

Source code is in file  Object3.prg.

!seealso: LogOn LogOff LogClear


'####################################################################################
!short:Memo (bVar,lEdit,[cTitle],[R],[C],[RSize],[CSize],[CurSize],[Clr],[lShd])
^BMemo (bVar,lEdit,[cTitle],[R],[C],[RSize],[CSize],[CurSize],[Clr],[lShd]):
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The memo field is edited or viewed, or any text defined with get/set
code block.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
bVar:      get/set code block created i.g. by FieldWBlock(), it is the
           item to edit
lEdit:     true it can be edited
cTitle:    editation window title, default is "Text"
R:         top edit window border (default- cursor position)
C:         left edit window border (default - cursor position)
RSize:     edited window size, row count, default is MaxRow()/3
CSize:     edited window size, col count, default is MaxCol()/2
CurSize:   system attempts to position the window nearest to the R,C
           coordinate not to cover the CurSize() characters on this
           coordinate.
Clr:       window color, default is m->Color:Edit or m->Color:View
lShd:      true if to paint a shadow, default is true for color monitors,
           false for mono.

Return value:
~~~~~~~~~~~~~
edited text

Remarks:
~~~~~~~~
for color definition is a public non-clipper object m->Color used.

Source code is in file  Object3.prg

!seealso: SetMemoWrap EditGetMsg c_color.ngo:Color ob_basic.ngo:m->Color


'####################################################################################
!short:MidStr (S,l,r) --> cString
^BMidStr (S,l,r) --> cString:
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Returns a text string S shortened of l-1 character from left and r-1
from right. It returns a middle of the text string from a position l
to a position r.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
S:  text string to shorten from both sides
l:  character number to shorten from the left side
r:  character number to shorten from the right side

Return value:
~~~~~~~~~~~~~
shortened string

Example:
~~~~~~~~
    ? MidStr("1-Hello-21",2,3)  //-Hello- is printed

Source code is in file  Object3.prg

!seealso:


'####################################################################################
!short:NetCreateFrom (cFile1,cFile2,[lContinue]) --> true/false
^BNetCreateFrom (cFile1,cFile2,[lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
It is a functional equivalent of NET CREATE ... FROM ...

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cFile1:    database file name to create
cFile2:    databse file name of database file describing the dbf file
           structure to create.
lContinue: if true it can be continued in a program after failed
           cursor creation.

Return value:
~~~~~~~~~~~~~
true if the database files was corectly created
false it is nat possible to create the file

Source code is in file  Object3.prg

!seealso: NetDbCreate ob_comma.ngo:"NET CREATE"


'####################################################################################
!short:NetDbAppend ([lContinue]) --> true/false
^BNetDbAppend ([lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET APPEND BLANK ... command

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~

lContinue: if true the program can continue, also when
           file creation failed.

Return value:
~~~~~~~~~~~~~
true if the record was appended to a file.

Source code is in file  Object3.prg

!seealso: NetDbDelete NetDbRecall ob_comma.ngo:"NET APPEND BLANK"


'####################################################################################
!short:NetDbCreate (cFile,aStructure,[lContinue]) --> true/false
^BNetDbCreate (cFile,aStructure,[lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Net variant of Clipper command DbCreate()

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cFile:       database file name to create
aStructure:  dbf file structure describing the file structure to create
lContinue:   if true it can be continued also when creation failed.

Return value:
~~~~~~~~~~~~~
True if the file was correctly created

Source code is in file  Object3.prg

!seealso: NetCreateFrom ob_comma.ngo:"NET CREATE"


'####################################################################################
!short:NetDbDelete ([lContinue]) --> true/false
^BNetDbDelete ([lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET DELETE command, the selected record of
selected database is marked for deletion

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true you can continue after the deleted marking failed

Return value:
~~~~~~~~~~~~~
true if the record is marked for deleting
false if the deleted marked sign  production failed

Source code is in file  Object3.prg

!seealso: NetDbRecall NetDbAppend ob_comma.ngo:"NET RECALL" ob_comma.ngo:"NET DELETE"


'####################################################################################
!short:NetDbRecall ([lContinue]) --> true/false
^BNetDbRecall ([lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET RECALL command
recalls the records marked as deleted, inverse to NetDBDelete()
function. For detailed description see commands.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true, it can continue whether the recall failed or no.

Return value:
~~~~~~~~~~~~~
true if the recall succeeded, false if no.

Source code is in file  Object3.prg

!seealso: NetDbDelete NetDbAppend ob_comma.ngo:"NET DELETE" ob_comma.ngo:"NET RECALL"


'####################################################################################
!short:NetDbUseArea (new,rdd,db,a,shex,ro,[lContinue]) --> true/false
^BNetDbUseArea (new,rdd,db,a,shex,ro,[lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
functional variant of NET USE command
The same as clipper function DBUseArea() but serves the network problems,
with same parameters except of lContinue.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true, it can continue whether the net use failed or no

Return value:
~~~~~~~~~~~~~
true if databse opening succeded false if no

Source code is in file  Object3.prg

!seealso: NetIndexOn NetSetIndex ob_comma.ngo:"NET USE"


'####################################################################################
!short:NetFErase (cFile,[lContinue]) --> true/false
^BNetFErase (cFile,[lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET ERASE command described in commmands part

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cFile:     filename to delete
lContinue: if true, it can continue whether the erase failed or no

Return value:
~~~~~~~~~~~~~
true if the file was deleted false if no

Source code is in file  Object3.prg

!seealso: ob_comma.ngo:"NET ERASE"


'####################################################################################
!short:NetFLock ([lContinue]) --> true/false
^BNetFLock ([lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET FLOCK command

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true, it can continue whether the flock failed or no

Return value:
~~~~~~~~~~~~~
trueif the file was locked false if no

Source code is in file  Object3.prg

!seealso: NetRLock NetReIndex ob_comma.ngo:"NET FLOCK" ob_comma.ngo:"NET RLOCK"


'####################################################################################
!short:NetIndexOn (cFile,cKey,[bKey],[lUnique],[lContinue]) --> true/false
^BNetIndexOn (cFile,cKey,[bKey],[lUnique],[lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET INDEX ON command, decribed in command chapter

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cFile:     index file to create
cKey:      index key in form of string
bKey:      index key as a code block, if nothing is set the function
           creates it
lUnique:   sets the index to unique, if nothing set the value is taken
           from system SET UNIQUE ON/OFF
lContinue: if true, it can continue whether the index creation failed
           or no

Return value:
~~~~~~~~~~~~~
true if index file was created, false if no

Source code is in file  Object3.prg

!seealso: NetReIndex ob_comma.ngo:"NET INDEX ON" ob_comma.ngo:"NET REINDEX"


'####################################################################################
!short:NetLimit (new) --> old
^BNetLimit (new) --> old:
~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The get set function to maintain the maximal allowed user number to run
the program default 999.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
new: maximal allowed user number

Return value:
~~~~~~~~~~~~~
old: maximal allowed user number

Example:
~~~~~~~~
NetLimit(2) //must be set before the function OBjectInit(...)
            //program has two users

Source code is in file  Object3.prg.

!seealso: LogOn LogOff LogSet


'####################################################################################
!short:NetPack ([lContinue]) --> true/false
^BNetPack ([lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET PACK command, described in commands chapter

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true, it can continue whether the pack failed or no

Return value:
~~~~~~~~~~~~~
true if pack succeeded false if no

Source code is in file  Object3.prg

!seealso: NetZap NetReIndex ob_comma.ngo:"NET PACK" ob_comma.ngo:"NET ZAP" ob_comma.ngo:"NET REINDEX"


'####################################################################################
!short:NetReIndex ([lContinue]) --> true/false
^BNetReIndex ([lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET REINDEX command, described in commnads chapter

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true, it can continue whether the reindex failed or no

Return value:
~~~~~~~~~~~~~
true if reindex succeeded, false if no

Source code is in file  Object3.prg

!seealso: NetIndexOn NetSetIndex ob_comma.ngo:"NET REINDEX" ob_comma.ngo:"NET INDEX ON"


'####################################################################################
!short:NetRLock ([lContinue]) --> true/false
^BNetRLock ([lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET RLOCK command described in command chapter

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true, it can continue whether the net rlock failed or no

Return value:
~~~~~~~~~~~~~
true if the record was locked, false if no

Source code is in file  Object3.prg

!seealso: NetFLock NetDbAppend NetReIndex ob_comma.ngo:"NET RLOCK" ob_comma.ngo:"NET FLOCK"


'####################################################################################
!short:NetSetIndex (cListFiles,[lContinue]) --> true/false
^BNetSetIndex (cListFiles,[lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
functional variant of NET SET INDEX command described in commands
chapter.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cListFiles: idex file list to be opened in form :
            "File1,File2,File3,...,FileN"
lContinue:  if true, it can continue whether the index opening failed
            or no

Return value:
~~~~~~~~~~~~~
true if the index open succeeded, false if no

Source code is in file  Object3.prg

!seealso: NetIndexOn NetReIndex ob_comma.ngo:"NET SET INDEX" ob_comma.ngo:"NET INDEX ON"


'####################################################################################
!short:NetZap ([lContinue]) --> true/false
^BNetZap ([lContinue]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Functional variant of NET ZAP command, described in commnds chapter

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true, it can continue whether the function failed or no

Return value:
~~~~~~~~~~~~~
true if the zap succeeded, false if no

Source code is in file  Object3.prg

!seealso: NetPack NetReIndex ob_comma.ngo:"NET ZAP" ob_comma.ngo:"NET PACK" ob_comma.ngo:"NET REINDEX"


'####################################################################################
!short:OAlert (cMessage,[aOptions],[nRow]) --> nChoice
^BOAlert (cMessage,[aOptions],[nRow]) --> nChoice:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
In cause of deadlock of my computer when issuing the Alert() command
I wrote the OAlert(). The difference is in used colors and in nRow
parameter to set the start row of alert window.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cMessage: string to display in a alert window; the semicolon (;) ia a
          line separator
aOptions: array of options to select {"option1","option2"...},
          default {"OK"}
nRow:     the strt row of alert window, default is centr of the screen

Return value:
~~~~~~~~~~~~~
number of selected option from aOptions array or zero (0) if ESC was pressed

Source code is in file  Object3.prg

!seealso: c_mnu.ngo:Mnu c_menu.ngo:Menu c_choice.ngo:Choice


'####################################################################################
!short:ObjectDone ([lContinue]) --> true
^BObjectDone ([lContinue]) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
If lContinue is false, the databases are closed and the original dos
screen is restored. If lContinue is true or nil the databases are
closed, user is logged off, and the original dos screen is restored,
it should be one of the last commands before the end of the program.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lContinue: if true, it can continue whether the function failed or no

Return value:
~~~~~~~~~~~~~
true

Source code is in file  Object3.prg

!seealso: ObjectInit


'####################################################################################
!short:ObjectInit ([clr],cPrgName,nVersion,nYear,[cUser],[cAuthor],[cLine]) --> nil
^BObjectInit ([clr],cPrgName,nVersion,nYear,[cUser],[cAuthor],[cLine]) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Public library variables are defined, basic library classes are
registered, the m->tColor variable, public object m->Color are set on
the value of command line parameters, the F1 and SHIFT F1 keys are set
to help system, the basic program screeen is painted, the date and time
is requested (if SetDateTime()==true). All parameters except of clr are
send to AboutOn() function for painting of information program screen.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
clr:       parameter of command line, sets the monitor type, see the
           m->tColor variable
cPrgName:  program name of up to 8 characters
nVersion:  version number
nYear:     creation year
cUser:     registered user name
cAuthor:   author copyright string
cLine:     special comment line

Return value:
~~~~~~~~~~~~~
true

Remarks:
~~~~~~~~
Example of use are in DEMO1.prg and DEMO2.prg

Source code is in file  Object3.prg

!seealso: AboutOn ObjectDone ob_basic.ngo:m->tColor ob_basic.ngo:m->Color c_color.ngo:Color


'####################################################################################
!short:OutputDevice (What,[iAdditive]) --> nil
^BOutputDevice(What,[iAdditive]) --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Clipper output device is switched to monitor, printer or file.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
What:      can obtain values OD_SCREEN, OD_PRINTER (screen output,
           or printer output - the object.ch defined constants)
           or can be a file name to redirect the output
lAdditive: logical variable to supress the screen output

Return value:
~~~~~~~~~~~~~
procedure returns nil

Example:
~~~~~~~~
    OutputDevice(OD_PRINTER)
    ? "WE ARE PRINTING TO PRINTER..."
    OutputDevice(OD_SCREEN)
    ? "WE ARE PRINTING TO THE SCREEN..."
    OutputDevice("text.txt")
    ? "WE ARE PRINTING TO A FILE..."

Source code is in file  object3.prg.


'####################################################################################
!short:PageLength ([nNewRows]) --> nOldRows
^BPageLength ([nNewRows]) --> nOldRows:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Internal static variable contains a number lines pre page for reports.
If performed without a parameters, it returns the current lines/page,
with a parameter it stores as new value lines/page.


Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cNewRows: new value lines pre page for reports.


Return value:
~~~~~~~~~~~~~
current number lines/page.


Source code is in file Object3.prg

!seealso: PrintFile PrintOn PrintOff OutputDevice


'####################################################################################
!short:PauseKey ([nSecs]) --> nKey
^BPauseKey ([nSecs]) --> nKey:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The same as the InKeyWait(),but if the activating key was pressed, we
wait for a new key pressing. The code block set by SetKey() is performed
and returns a keypressed code.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nSecs: time is seconds how long to wait for keypressing

Return value:
~~~~~~~~~~~~~
keypressed code

Example:
~~~~~~~~
     SetKey(K_F1,{||HelpKeys()})
     ? PauseKey(0)
     ...
Hangs on F1 key a HelpKeys() function and waits for a keypressing. If
F1 key was pressed the HelpKeys() function is performed and continues
the waiting wor a keypress. If there was another key pressed its code
is displayed.

Source code is in file  Object3.prg

!seealso: InKeyWait StuffKey StuffKeys SetLastKey


'####################################################################################
!short:PopBreak () --> code_block
^BPopBreak () --> code_block:
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The last item of internal error subroutines stack is popped (the code
block of error status handle) and returned to calling function. It
serves for BEGIN BREAK ... END BREAK commands.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
error status serving code block

Source code is in file  ErrorSys.prg.

!seealso: PushBreak DoBreak ob_comma.ngo:"BEGIN BREAK"


'####################################################################################
!short:PrintCodes (cCtrlCode) --> true
^BPrintCodes (cCtrlCode) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The control codes from a cCtrlCode string are send to printer, the print
head position maintains unchanged, the correct values of PRow() a PCol()
functions are returned.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cCtrlCode: control codes to send to a printer

Return value:
~~~~~~~~~~~~~
true

Example:
~~~~~~~~
     PrintCodes("@")   //printer reset

Source code is in file  Object3.prg

!seealso: PrintOn PrintOff PrintFile OutputDevice


'####################################################################################
!short:PrintFile (cFileName) --> nil
^BPrintFile (cFileName) --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Send the file into a printer.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cFileName: this file must be sended into a printer.

Return value:
~~~~~~~~~~~~~
nil

Example:
~~~~~~~~
     PrintFile("MyFile.txt")   //send MyFile.txt into a printer.

Source code is in file  Object3.prg

!seealso: PrintCodes PrintOn PrintOff OutputDevice


'####################################################################################
!short:PrintOff () --> nil
^BPrintOff () --> nil:
~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Switch output device into screen.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
none

Return value:
~~~~~~~~~~~~~
nil


Source code is in file  Object3.prg

!seealso: PrintCodes PrintOn PrintFile OutputDevice


'####################################################################################
!short:PrintOn () --> nil
^BPrintOn () --> nil:
~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Switch output device into printer.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
none

Return value:
~~~~~~~~~~~~~
nil


Source code is in file  Object3.prg

!seealso: PrintCodes PrintOff PrintFile OutputDevice


'####################################################################################
!short:PushBreak (Br) --> nil
^BPushBreak (Br) --> nil:
~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The internal error subroutines stack is pushed the new item Br (error
status serving code block), for the use by BEGIN BREAK ... END BREAK
commands.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
Br: item pushed to the stack

Return value:
~~~~~~~~~~~~~
nil

Source code is in file  ErrorSys.prg.

!seealso: PopBreak DoBreak ob_comma.ngo:"BEGIN BREAK"


'####################################################################################
!short:ReadHelpVar (vn) --> VarName
^BReadHelpVar (vn) --> VarName:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
ReadHelpVar() returns the last item of its internal stack (edited
variable name).

ReadHelpVar("VarName")
The internal stack is pushed a "VarName" parameter, used for activating
of a sensitive help for edited variable name obtain. (PUSH)

ReadHelpVar("")
The last item of internal stack is popped.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
vn: edited variable name

Return value:
~~~~~~~~~~~~~
edited variable name

Source code is in file  Object2.prg.

!seealso: HelpField HelpAssoc ChangeAssoc HelpReserved


'####################################################################################
!short:RefreshRow () --> nil
^BRefreshRow () --> nil:
~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
For a edited object of view class is edited line refreshed. It is used
after a change of a field in validation.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
nil

Example:
~~~~~~~~
     RefreshRow()   //row refresh

Source code is in file  Object3.prg

!seealso:  RefreshTable


'####################################################################################
!short:RefreshTable () --> nil
^BRefreshTable () --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
For edited object of view class is whole visible part refreshed. It is
used after a change of fields in validation. When used with filter set
it can last a long time !

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
nil

Example:
~~~~~~~~
     RefreshTable()   //display refresh

Source code is in file  Object3.prg

!seealso:  RefreshRow


'####################################################################################
!short:RepaintDesktop () --> nil
^BRepaintDesktop () --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
It perform redrawingg for all screen area.
(Can be used after return from DOS.)


Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
nil


Source code is in file  C_Window.prg



'####################################################################################
!short:RestartTask () --> true/false
^BRestartTask() --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Last active task restart. The task swapper takes the last active task
and starts the VProcess() of it. The Task:Process() method is realy
activated.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true if there is a task to activate otherwise false.

Source code is in file  c_task.prg

!seealso: c_task.ngo:Task


'####################################################################################
!short:RestDatabase () --> nil
^BRestDatabase () --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Restores original state of the databases, previously saved with function
SwapDatabase(...).

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
nil

Source code is in file Object3.prg

!seealso: SwapDatabase


'####################################################################################
!short:RestDOut () --> nil
^BRestDOut () --> nil:
~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
If it is enabled to write to dialogue line, its stored (by SaveDout())
text is restored.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
nil

Remarks:
~~~~~~~~
Output to dialogue line can be supressed by SetDialog() function, the
use of SavedOut() RestDOut() functions can be in more levels. You can
several times call the SaveDout() and restore the data by the same
number of RestDOut() calls.

Source code is in file  Object3.prg

!seealso: SetDialog SaveDOut DOut SaveScr RestScr


'####################################################################################
!short:RestHelpIdx () --> true
^BRestHelpIdx () --> true:
~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
If SetHelpIdx()==true the subarray to display in HelpKeys() information
is restored. This information must be stored by SaveHelpIdx().

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true

Remarks:
~~~~~~~~
It is possible to use functions SaveHelpIdx() and RestHelpIdx() in more
levels by repeatedly calling the first and for restoring the second
function.

Source code is in file  Object2.prg

!seealso: HelpKeys SaveHelpIdx SetHelpIdx


'####################################################################################
!short:RestScr (aScreenArray) --> true
^BRestScr (aScreenArray) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The screen is restored, cursor shape and position, colors and the  text
from the aScreeenArray created by SaveScr().

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
aScreenArray: array of data saved by SaveScr()

Return value:
~~~~~~~~~~~~~
true

Example:
~~~~~~~~
    local aS:=SaveScr()    //screen save
    cls                    //erase
    InKey(0)               //wait for keypress
    RestScr(aS)            //screen restore

Source code is in file  Object1.prg

!seealso: SaveScr SaveDOut RestDOut DOut


'####################################################################################
!short:SaveDOut (cMsg) --> nil
^BSaveDOut (cMsg) --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
If it is enabled to output to dialogue line, the centered text is
displayed to it The text is stored for further use by SetMsg() and
(diferention to DOut()) the text for restoring by RestDout() is stored.
The used colors are m->Color:Menu[nNormal], SetColor() is unchanged and
the cursor shape and position too.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cMsg:  text for dialog line output

Return value:
~~~~~~~~~~~~~
nil

Remarks:
~~~~~~~~
The dialog line output can be supressed by SetDialog() function, the
use of SavedOut() RestDOut() functions can be in more levels. You can
several times call the SaveDout() fun. and restore the data by the same
number of RestDOut() calls.

Source code is in file  Object3.prg

!seealso: SetDialog DOut RestDOut SaveScr RestScr


'####################################################################################
!short:SaveHelpIdx (aNewIdx) --> true
^BSaveHelpIdx (aNewIdx) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
If is SetHelpIdx()==true the subfields to display information is stored
for display by HelpKeys(). More deep description is in describing of
HelpKeys().

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
aNewIdx:  array of subfields to display index.

Return value:
~~~~~~~~~~~~~
true

Remarks:
~~~~~~~~
It is possible to use functions SaveHelpIdx() and RestHelpIdx() in more
levels by repeatedly calling the first and for restoring the second
function.

Source code is in file  Object2.prg

!seealso: HelpKeys RestHelpIdx SetHelpIdx


'####################################################################################
!short:SaveScr ([nRow1],[nCol1],[nRow2],[nCol2]) --> aScreenArray
^BSaveScr ([nRow1],[nCol1],[nRow2],[nCol2]) --> aScreenArray:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The screen is saved (cursor, colors, text) to aScreeenArray.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nRow1: upper border of region to store
nCol1: left border ...
nRow2: bottom border ...
nCol2: right border ...
default is the whole screen

Return value:
~~~~~~~~~~~~~
aScreenArray:  array to store the data

Example:
~~~~~~~~
    local aS:=SaveScr()    //screen stored
    cls                    //erased
    InKey(0)               //wait for keypress
    RestScr(aS)            //screeen restore

Source code is in file  Object1.prg

!seealso: RestScr SaveDOut RestDOut DOut


'####################################################################################
!short:SetDateTime ([lNew]) --> true/false
^BSetDateTime ([lNew]) --> lOldValue:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Serves as a switch, if set to true (if returns true) the ObjectInit()
requires the date and time input, if false then no request.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lNew: new value to set the switch

Return value:
~~~~~~~~~~~~~
true/false

Example:
~~~~~~~~
    ? SetDateTime()        //the value of the switch
    SetDateTime(true)      //set the switch to true
    ? SetDateTime()        //returns true

Source code is in file  Object3.prg

!seealso: ObjectInit


'####################################################################################
!short:SetDialog ([lNew]) --> true/false
^BSetDialog ([lNew]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
serves as a switch, if set to true (if returns true) the dialog line
output and change is enabled, if false it is disabled.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lNew: new value to set the switch

Return value:
~~~~~~~~~~~~~
true/false

Example:
~~~~~~~~
    ? SetDialog()        //the value of the switch
    SetDialog(true)      //set the switch to true
    ? SetDialog()        //returns true

Source code is in file  Object3.prg

!seealso: DOut SaveDOut RestDOut


'####################################################################################
!short:SetDMsg ([cNew]) --> true/false
^BSetDMsg ([cNew]) --> OldString:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
serves as a switch, if set to true (if returns true), the dialog line
output is ensbled, if false it is disabled

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lNew: new value to set the switch

Return value:
~~~~~~~~~~~~~
true/false

Example:
~~~~~~~~
    ? SetDMsg()        //the value of the switch
    SetDMsg(true)      //set the switch to true
    ? SetDMsg()        //returns true

Source code is in file  Object3.prg

!seealso: DOut SaveDOut RestDOut


'####################################################################################
!short:SetErrFile ([cNewFileName]) --> cOldFileName
^BSetErrFile ([cNewFileName]) --> cOldFileName:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Internal static variable contains a filename of error output. If
performed without a parameters, it returns the file name,
with a parameter it stores it as a new file name for error output.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cNewFileName: new filename for error output

Return value:
~~~~~~~~~~~~~
new filename for error output


Source code is in file  ErrorSys.prg

!seealso: ob_comma.ngo:"SET ERRORS FILE"


'####################################################################################
!short:SetHelpIdx ([lNew]) --> true/false
^BSetHelpIdx ([lNew]) --> true/false
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Serves as a switch, if set to true (if returns true), there is enabled
to change a information displayed by HelpKeys(), if set to false the
change is disabled.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lNew: new value to set the switch

Return value:
~~~~~~~~~~~~~
true/false

Example:
~~~~~~~~
    ? SetHelpIdx()        //the value of the switch
    SetHelpIdx(true)      //set the switch to true
    ? SetHelpIdx()        //returns true

Source code is in file  Object3.prg

!seealso: HelpKeys SaveHelpIdx RestHelpIdx


'####################################################################################
!short:SetLastKey (nKey) --> nKey
^BSetLastKey (nKey) --> nKey:
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The functional variant of SET LAST KEY ... command, the nKey number is
set to return this number from the LastKey() function until is a key
pressed or until a new set by SetLastKey().

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nKey:  key code to return by LastKey() function

Return value:
~~~~~~~~~~~~~
returns the value set as nKey

Example:
~~~~~~~~
    ? LastKey()          //returns last keypressed value
    SetLastKey(K_ENTER)  //LastKey() is set to ENTER value
    ? LastKey()          //returns a Enter key value ( K_ENTER)

Source code is in file  Object3.prg

!seealso: StuffKey StuffKeys InKeyWait PauseKey ob_comma.ngo:"SET LASTKEY"


'####################################################################################
!short:SetLastTask ([<NewTask>]) --> task_object
^BSetLastTask ([<NewTask>]) --> task_object:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Object NewTask is set to last active task, after leaving the main menu
this task is restarted. If no parameter set it returns the last active
task.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
NewTask    last active object identificator

Return value:
~~~~~~~~~~~~~
posledny aktivny object (uloha)

Source code is in file  c_task.prg

!seealso: c_task.ngo:Task


'####################################################################################
!short:SetMemoWrap ([lNew]) --> true/false
^BSetMemoWrap ([lNew]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
serves as a switch, if set to true (if returns true) it is enabled
word_wrap in memo item edit (Memo() fun.), if false it is disabled.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lNew: new value to set the switch

Return value:
~~~~~~~~~~~~~
true/false

Example:
~~~~~~~~
    ? SetMemoWrap()        //the value of the switch
    SetMemoWrap(true)      //set the switch to true
    ? SetMemoWrap()        //returns true

Source code is in file  Object3.prg

!seealso: Memo


'####################################################################################
!short:SetQuickEsc ([lNew]) --> true/false
^BSetQuickEsc ([lNew]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Serves as a switch, if set to true (if returns true), after pressing the
ESC the menu is imediately cancelled, if false the menu is returned one
level up.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lNew: new value to set the switch

Return value:
~~~~~~~~~~~~~
true/false

Example:
~~~~~~~~
    ? SetQuickEsc()        //the value of the switch
    SetQuickEsc(true)      //set the switch to true
    ? SetQuickEsc()        //returns true

Source code is in file  Object3.prg

!seealso: c_menu.ngo:Menu


'####################################################################################
!short:SetShowText ([lNew]) --> true/false
^BSetShowText ([lNew]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Serves as a switch, if set to true (if returns true), when waiting for
keypress the ShowText() text is displayed in upper right window corner,
if false no function.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lNew: new value to set the switch

Return value:
~~~~~~~~~~~~~
true/false

Source code is in file  Object3.prg

!seealso: ShowText ShowTime SetShowTime GetKey


'####################################################################################
!short:SetShowTime ([lNew]) --> true/false
^BSetShowTime ([lNew]) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
serves as a switch, if set to true (if returns true), when waiting for
keypress the time is displayed in upeer right screen corner, if false
nothing is displayed.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
lNew: new value to set the switch

Return value:
~~~~~~~~~~~~~
true/false

Source code is in file  Object3.prg

!seealso: ShowText ShowTime SetShowText GetKey


'####################################################################################
!short:ShowText ([cNew]) --> cOld
^BShowText ([cNew]) --> cOld:
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Text set as cNew parameter is stored, if the output is enabled by
SetShowText(), it is displayed to upper right screen corner.
This function is activated by every keypress.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cNew: text to store and display

Return value:
~~~~~~~~~~~~~
cOld: stored text.

Source code is in file  Object3.prg

!seealso: ShowTime SetShowText SetShowTime GetKey


'####################################################################################
!short:ShowTime ([cNewTime]) --> cCurrentTime
^BShowTime ([cNewTime]) --> cCurrentTime:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
If it is enabled to display a time by SetShowTime() function, this
function displays time.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cNewTime: Time to display, if nothing set the clipper time from Time()
function is used.

Return value:
~~~~~~~~~~~~~
cCurrentTime: displayed time text string

Source code is in file  Object3.prg

!seealso: ShowText SetShowText SetShowTime GetKey


'####################################################################################
!short:SkipDeleted() --> true/false
^BSkipDeleted() --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
RecNo() is set to a first current database record not marked as deleted.
If all database records are marked for delete it is set to Eof() and
returns false, if there is one not deleted record at least, his RecNo()
is set and returns true. The scan goes from the current record to the
end and then from begin.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true if a record was found, otherwise false


Source code is in file  OBject3.prg

!seealso: StuffKey StuffKeys


'####################################################################################
!short:StuffKey (nKey) --> true
^BStuffKey (nKey) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The keyboard queue is inserted a keycode to the front of it.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nKey:  keycode to insert the keyboard queue

Return value:
~~~~~~~~~~~~~
true

Source code is in file  Object3.prg

!seealso: StuffKeys InKeyWait PauseKey SetLastKey


'####################################################################################
!short:StuffKeys (cKeys) --> true
^BStuffKeys (cKeys) --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The keyboard queue is inserted a string, to the front position.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cKeys:  text string to insert the keybord queue

Return value:
~~~~~~~~~~~~~
true

Source code is in file  Object3.prg

!seealso: StuffKey InKeyWait PauseKey SetLastKey


'####################################################################################
!short:SwapColor (cColor) --> cSwappedColor
^BSwapColor (cColor) --> cSwappedColor:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Swap of fore-background colors

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cColor: text string to swap the colors

Return value:
~~~~~~~~~~~~~
new string with swapped colors

Example:
~~~~~~~~
    ? SwapColor("w/n+")  // output :"n+/w"

Source code is in file  Object3.prg

!seealso: GetFore GetBack


'####################################################################################
!short:SwapDatabase (cAlias, nOrder) --> nil
^BSwapDatabase (cAlias, nOrder) --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Switch to on workarea cAlias, make the "set order to nOrder".
Will be to save all need data for restore previous state of the database
system with function RestDatabase().

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cAlias: alias for the workarea that will be selected.
nOrder: index order in new selected workarea.

Return value:
~~~~~~~~~~~~~
nil

Example:
~~~~~~~~
    SwapDatabase("Ciselnik",2)
      go top
      while !Eof()
        if RecordOk()
          ProceedRecord()
        endif
        seek anything 
      endwhile
    RestDatabase()


Source code is in file Object3.prg

!seealso: RestDatabase


'####################################################################################
!short:SwapEGALines () --> nil
^BSwapEGALines () --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Switch current screen lines beetwen 25 / 43 lines, and redraw entire screen
after switching.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
nil

Source code is in file Object3.prg

!seealso: SwapVGALines


'####################################################################################
!short:SwapVGALines () --> nil
^BSwapVGALines () --> nil:
~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Switch current screen lines beetwen 25 / 50 lines, and redraw entire screen
after switching.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
nil

Source code is in file Object3.prg

!seealso: SwapEGALines


'####################################################################################
!short:TestAllDbfReIndex () --> true
^BTestAllDbfReIndex() --> true:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
It is used for postponing of database reindex to the time of
user index are set. The reindex is done by Menu:Init().

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
true


Source code is in file  C_Dbf.prg

!seealso: c_dbf.ngo:Dbf


'####################################################################################
!short:TopBreak () --> code_block
^BTopBreak () --> code_block:
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The copy of error subroutines stack top is returned - the code block
stored by PushBreak(). Serves for BEGIN BREAK ... END BREAK commands.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
nil

Return value:
~~~~~~~~~~~~~
top of error subroutines stack copy

Source code is in file  ErrorSys.prg.

!seealso: PushBreak PopBreak DoBreak ob_comma.ngo:"BEGIN BREAK"


'####################################################################################
!short:UserID ([cUserID]) --> cUserID
^BUserID ([cUserID]) --> cUserID:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
User ID is stored, to display in every start of a program. You can ask
for active username whwenewer you need after he enters his ID and
password.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
cUserID: user ID to store

Return value:
~~~~~~~~~~~~~
stored user ID


Source code is in file  ErrorSys.prg

!seealso: c_menu.ngo:Menu


'####################################################################################
!short:UserLevel (new) --> nUserLevel
^BUserLevel (new) --> nUserLevel:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
Get set function to store the privileges of active user (0...999), the
number is supervisor set with user ID and password. It can be used to
enable/disable the program parts according the user rights. For example
some database fields can be expelled from the view for some users (when
creting the view only the fields for privileged user are included in
it). Aplication programmer should call it without parameters to read
the active user privilege rights.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
new: new privilege rights level for active user

Return value:
~~~~~~~~~~~~~
number in a range 0...999: active user privilege rights

Source code is in file  ErrorSys.prg.

!seealso: UserNo UserID


'####################################################################################
!short:UserNo (new) --> UserNo
^BUserNo (new) --> UserNo:
~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The Object.lib library stores the Recno of user from the password
database (System1.dbf), it is aget-set function, when called without
parameters it returns the user number (RecNo)

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
mew order number (RecNo) of active user in user pasword database
(System1.dbf)

Return value:
~~~~~~~~~~~~~
order number (RecNo) of active user in user pasword database
(System1.dbf)

Source code is in file  ErrorSys.prg


'####################################################################################
!short:WEval (bExpression,bBlock) --> true/false
^BWEval (bExpression,bBlock) --> true/false:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Functions:
~~~~~~~~~~
The code block bBlock is performed until the result of
Eval(bExpression)==true, or result of Eval(bBlock)==false.

Parameter description:
~~~~~~~~~~~~~~~~~~~~~~
bExpression:    until this code block result is true the code block
                bBlock is performed again
bBlock:         code block to repeat

Return value:
~~~~~~~~~~~~~
true if terminated with bExpression
false if terminated with bBlock

Source code is in file  Object3.prg

!seealso: IEval

'
' eof (c)JHK 
'
