Antwort schreiben...
 
Themen-Optionen Thema durchsuchen
Alt 13.10.2012, 09:59   #161
leecher
Moderator
SETNOTE

E r g e b n i s / R e s u l t

Set a new default notepad filename

B e s c h r e i b u n g / D e s c r i p t i o n

The function changes the searching order and filename of the current
notepad file.

Using this function, the developer can alter the current notepad file
name.

S y n t a x

Code:
bool = call('SETNOTE' , string)
P a r a m e t e r

string - a string containing the new notepad filename. A nickname
can be specified.

R e t u r n s

A boolean variable.

B e i s p i e l / E x a m p l e

Code:
attach 'SETUP'
a = call ('SETNOTE' , 'TEST:PROGRAM.TXT')  ! sets a new notepad filename
detach 'SETUP'
Q u e r v e r w e i s / C r o s s R e f e r e n c e
GETNOTE
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 10:00   #162
leecher
Moderator
SETVOL

E r g e b n i s / R e s u l t

Set a searching order volume / pathname.

B e s c h r e i b u n g / D e s c r i p t i o n

SETVOL changes a searching order volume / pathname to a new value.

The developer can alter where Open Access looks for, and saves it's data.

If you wanted to, the searching orders could be checked to see if they
contain A:\ using GETVOL. Then, if it did not exist, one of the pathnames
could be changed to A:\.

S y n t a x

Code:
bool = call('SETVOL' , searching_order_number , string)
P a r a m e t e r

searching_order_number - is a number in the range 1 to the number of
searching orders returned by GETNUMV.

Negative numbers are treated as positive ones
and using a number outside of the range will
return the name of the first nickname.

string - the new DOS path.

R e t u r n s

A boolean variable.

B e i s p i e l / E x a m p l e

Code:
attach 'SETUP'
put call('SETVOL' , 4 , 'C:\BACKUP')     ! searching order 4 is changed
					 ! to C:\BACKUP\ 
detach 'SETUP'
Q u e r v e r w e i s / C r o s s R e f e r e n c e
GETVOL
GETNUMV
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 10:02   #163
leecher
Moderator
GETTIME

E r g e b n i s / R e s u l t

Give the title of one of the time zones

B e s c h r e i b u n g / D e s c r i p t i o n

When <desk:F8> is displayed, three time zones are shown, complete with
their titles.

GETTIME returns one of these titles. The developer can record this
value or can search for a time zone.

S y n t a x

Code:
string = call('GETTIME' , timezone)
P a r a m e t e r

timezone - is a number in the range 0 - 2.

0 = Current Time time zone
1 = Time Zone 1
2 = Time Zone 2

R e t u r n s

A string containing the time zone title.

B e i s p i e l / E x a m p l e

Code:
attach 'TIME'
put call ('GETTIME' , 0)   ! prints 'Current Time' 
put call ('GETTIME' , 1)   ! prints 'MUNICH' 
put call ('GETTIME' , 2)   ! prints 'LONDON'
detach 'TIME'
Q u e r v e r w e i s / C r o s s R e f e r e n c e
SETTIME
Angehängte Dateien
Dateityp: oac TIME.OAC‎ (16.0 KB, 3x aufgerufen)
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 10:03   #164
leecher
Moderator
GETZONE

E r g e b n i s / R e s u l t

Give the offset of one of the time zones

B e s c h r e i b u n g / D e s c r i p t i o n

When <desk:F8> is displayed, three time zones are shown, complete with
their titles. Two of the time zones are offset from the current time
by an integer amount.

GETZONE returns one of these offsets. The developer can record this
value before changing it.

S y n t a x

Code:
value = call('GETZONE' , timezone)
P a r a m e t e r

timezone - is a number in the range 1 - 2.

1 = Time Zone 1
2 = Time Zone 2

R e t u r n s

An integer containing a timezone offset.

B e i s p i e l / E x a m p l e

Code:
attach 'TIME'
put call ('GETZONE' , 1)   ! prints the offset of the first timezone
put call ('GETZONE' , 2)   ! prints the second timezone offset
detach 'TIME'
Q u e r v e r w e i s / C r o s s R e f e r e n c e
SETZONE
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 10:05   #165
leecher
Moderator
SETTIME

E r g e b n i s / R e s u l t

Set the title of one of the time zones

B e s c h r e i b u n g / D e s c r i p t i o n

When <desk:F8> is displayed, three time zones are shown, complete with
their titles.

SETTIME changes one of these titles to whatever the developer requires.
Combined with the SETZONE function, the timezones can be altered from
within a program.

S y n t a x

Code:
bool = call('SETTIME' , timezone , string)
P a r a m e t e r

timezone - is a number in the range 0 - 2.

0 = Current Time time zone
1 = Time Zone 1
2 = Time Zone 2

string - the new timezone title. Strings are truncated to 15 characters

R e t u r n s

A boolean value.

B e i s p i e l / E x a m p l e

Code:
attach 'TIME'
put call ('SETTIME' , 0 , 'Paris')   ! sets 'Current Time' to 'Paris' 
detach 'TIME'
Q u e r v e r w e i s / C r o s s R e f e r e n c e
GETTIME
SETZONE
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 10:06   #166
leecher
Moderator
SETZONE

E r g e b n i s / R e s u l t

Set the offset of one of the time zones

B e s c h r e i b u n g / D e s c r i p t i o n

When <desk:F8> is displayed, three time zones are shown, complete with
their titles. Two of the time zones are offset from the current time
by an integer amount.

SETZONE can change the offset of one of these timezones.

S y n t a x

Code:
bool = call('SETZONE' , timezone , offset)
P a r a m e t e r

timezone - is a number in the range 1 - 2.

1 = Time Zone 1
2 = Time Zone 2

offset - is an integer value in the range -23 to 23

R e t u r n s

A boolean value.

B e i s p i e l / E x a m p l e

Code:
attach 'TIME'
put call ('SETZONE' , 1 , -1)   ! sets the offset of the first timezone
				! one hour behind 
put call ('SETZONE' , 2 , 1)    ! sets the second timezone offset to one
				! hour ahead 
detach 'TIME'
Q u e r v e r w e i s / C r o s s R e f e r e n c e
GETZONE
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 10:07   #167
leecher
Moderator
TIME_OFF

E r g e b n i s / R e s u l t

Turn off the on-screen clock

B e s c h r e i b u n g / D e s c r i p t i o n

TIME_OFF undoes the effect of TIME_ON and turns off the clock.

S y n t a x

Code:
bool = call('TIME_OFF')
P a r a m e t e r

There are no parameters for this procedure

R e t u r n s

A boolean value.

B e i s p i e l / E x a m p l e

Code:
attach 'TIME'
x = call('TIME_OFF')       ! the clock is now off
detach 'TIME'
Q u e r v e r w e i s / C r o s s R e f e r e n c e
TIME_ON
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 10:08   #168
leecher
Moderator
TIME_ON

E r g e b n i s / R e s u l t

Display a constantly ticking clock on the screen

B e s c h r e i b u n g / D e s c r i p t i o n

This powerful function will display a clock on the screen. It will
keep ticking until you turn it ogg.

If you place it in the top left or right corners then it will not
interfer with any normal display.

One drawback of turning the clock on is that the desk has to be
disabled.

S y n t a x

Code:
bool = call('TIME_ON' , row , column)
P a r a m e t e r

row - an integer value descriping the line the clock appears on
column - an integer value.

R e t u r n s

A boolean value.

B e i s p i e l / E x a m p l e

Code:
attach 'TIME'
x = call ('TIME_ON' , 1 , 1)        ! turns the clock on
detach 'TIME'
Q u e r v e r w e i s / C r o s s R e f e r e n c e
TIME_OFF
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 11:28   #169
leecher
Moderator
CHARKEY

E r g e b n i s / R e s u l t

Checks for a character in the keyboard buffer and returns it

B e s c h r e i b u n g / D e s c r i p t i o n

This function checks if there is a character waitinig in the keyboard buffer. If so, it is returned, otherwise an empty string is returned.

S y n t a x

Code:
ckey = call('charkey')
P a r a m e t e r

R e t u r n s

A string with containing the character.
The string ~~~ is returned if K_UNDO (ESC) is pressed
The string ||| is returned if K_DO (F10) or K_RETURN (Return) is pressed

B e i s p i e l / E x a m p l e

Code:
attach "keybuff"
xpos = 10 
ckey = "" 
while ckey <> "~~~" and ckey <> "|||" and xpos < 30 
   ckey = call('charkey')
   if  ckey <> "" and ckey <> "~~~" and ckey <> "|||" 
       put at xpos,7 ckey
       xpos = xpos + 1 
       put at xpos+1,7 " " 
   end if 
end while
Angehängte Dateien
Dateityp: oac KEYBUFF.OAC‎ (14.0 KB, 3x aufgerufen)
Dateityp: txt KEYBUFF.TXT‎ (1.2 KB, 3x aufgerufen)
leecher ist offline   Mit Zitat antworten
Alt 13.10.2012, 11:33   #170
leecher
Moderator
PASSW

E r g e b n i s / R e s u l t

Reads a Password at the specified position of the screen.

B e s c h r e i b u n g / D e s c r i p t i o n

This function reads a password of length pwdlen from the keyboard at the specified position xpos, ypos on the screen and hides the typed characters with the given hidechar.
Maximum length of password is 15 characters.

S y n t a x

Code:
pwd = call('passw',xpos,ypos,hidechar,pwdlen)
P a r a m e t e r

xpos - The x position on the screen where to read the characters
ypos - The y position on the screen where to read the characters
hidechar - The character used for hide the typed characters
pwdlen - The length of the password

R e t u r n s

A string with containing the character.
The string ~~~ is returned if K_UNDO (ESC) is pressed
The string ??? is returned if K_HELP (F1) is pressed

B e i s p i e l / E x a m p l e

Code:
pwd = ''
xpos = 21 
ypos = 12 
hidechar = '-'
pwdlen = 5       ! specify length of password 

put at 5,12 'Enter Password: ' 
pwd = call('passw',xpos,ypos,hidechar,pwdlen)
!pwd = (*STR) call('passw',xpos,ypos,hidechar,pwdlen)   ! for compiler
if  length(pwd) > 0
    if  pwd = '???'
        put at 5,14 'HELP KEY was pressed'
    else if pwd = '~~~'    
        put at 5,14 'ESC KEY was pressed'
    else    
        put at 5,14 'The password is : ', pwd
    end if    
    p = true
    get p 
end if 
detach "keybuff"
leecher ist offline   Mit Zitat antworten


Antwort schreiben...

Themen-Optionen Thema durchsuchen
Thema durchsuchen:

Erweiterte Suche