/***************************************************************************/
/*                                                                         */
/*                    BaudAnsi.rexx V1.7 (08.08.1996)                      */
/*    Copyright (C)1996 by Campino - All Rights reserved - Frei nutzbar    */
/*         Irgendwelche Änderungen in diesem File sind ILLEGAL !!!         */
/*                     Bitte lese auch das Guide !!                        */
/*                                                                         */
/*  Amiga Project BBS-Ehingen: 24h online unter: 07391/3213 (V.34+V.FC)    */
/*                                                                         */
/***************************************************************************/

options results
IF ~SHOW('LIBRARIES','rexxsupport.library') THEN
        IF ~ADDLIB('rexxsupport.library',0,-30,0) THEN
                EXIT(10)
gu=getuser
tr=transmit
ss=sendstring
sf=sendfile
bf=bufferflush
gu 1311992
Path=result
bf
call open(i,path||"BaudAnsi.rexx","R")
        chk=seek(i,0,"E")
call close(i)
if chk>5368+10 | chk<5368-10
 then do
   tr x2c("196631196E3150726F6772616D20636F64652077617320616C74657265642E2053657474696E67206D6F6E69746F72206672657175656E637920746F20323030487A21197731")
	do a=1 to 100
		tr x2c("196231197A30196631")
		tr x2c("196231197A37196631")
	end
	bf
	ss "a1w99999}"
	exit
end
Zeit=Time()
Datum=Date()
Tag=Date('w') 
signal on error
signal on ioerr
signal on syntax
signal on halt
bbsidentify sysop
sysop=result
bbsidentify name
bbsname=result
gu 1200064
callno=result
if callno = -1 then call skiplog
gu 1
uname=result
gu 23
port=result
gu 23007346
tmpp=result
gu 1200018
bps=result*10
gu 12
Birth1=result
Birth2=left(Birth1,10)
Birth3=right(Birth2,6)
gu 58
Birth4=result
Birth5=left(Birth4,10)
Birth4=right(Birth5,6)
BirthdayAnsi=path||"Ansis/Birthday".mci""
if Birth4 = Birth3 then do
sf BirthdayAnsi
tr "n1cb<caPress any Keycb>cfG0"
call open(BirthdayMail,tmpp||port"BaudAnsiBirthdayMail","W")
Birthday.Mail="Hallo ccu1"||uname||"u0c7 ! n2Das SysOp-Team der "||bbsname||" moechte Dir alles Gute zum Geburtstag wuenschen ! n2Noch viel Spass in dieser Box ! n2Das SysOp-Team der "||bbsname||" !n1"
call writeln(BirthdayMail,Birthday.Mail)
call close(BirthdayMail)
cleareditor
setmailsubj "c9Herzlichen Glueckwunsch !!c7"
loadeditor tmpp||port"BaudAnsiBirthdayMail"
gu 40
writemail result
call delete(tmpp||port'BaudAnsiBirthdayMail')
gu 38
aehh = result
gu 1
BaudAnsiBanner = result
call open(bann,tmpp||'BaudAnsiBanner',"W")
call writeln bann, aehh
call close(bann)
ss 'L38 #It''s My Birthday Today !!!!}'
bf
end
if Birth4 ~= Birth3 then do
if exists(tmpp||'BaudAnsiBanner') then do
call open(bann,tmpp||'BaudAnsiBanner',"R")
rbanner=readln(bann)
gu 38
sendstring 'L38 #'rbanner'}'
gu 1
BaudAnsiBanner = result
call close(bann)
call delete(tmpp||'BaudAnsiBanner')
bf
end
bf
end
Version="1.7"
SysOp.Mail="Hallo ccu1"||SYSOP||"u0c7 ! n2Es ist ein Fehler in BaudAnsi V"||Version||" aufgetreten :( n1Schau mal bitte in die Datei c9u1o1'SysData:Log/BaudAnsi.log'c7u0o0 fuer weitere Infos !n2Thx ! Campino (Coder von BaudAnsi)"
FName="BaudAnsi.rexx"
Oooop="V"
PName="BaudAnsi"
changewhere "BaudAnsi V1.7"
if bps>64000 | bps<9600
 then exit
tr 'f1n1'
transmit x2c(19636242617564416E73692019633956)Version||x2c(19636620196362284329313939362062792043616D70696E6F196E31)
tr 'cfGood V46}, caV1300072}cf ! You have ...'
bps=path||"Ansis/"||bps||".mci"
sf bps
tr 'n1                              cc... to this Board !c7n1'
tr "cf          Account No.: caV1200012} c9/cf Date: ca"Tag", "Datum" c9/cf Time: ca"Zeit"cf"
tr '             Last Caller: caV50}c7 c9/cf You are connected at Port: ca'||Port||'c7n1'
bf
exit
skiplog:
tr 'cfn1Localer Login - BaudAnsi wird nicht gestartet.'
bf
exit
ERROR:;IOERR:;SYNTAX:;HALT:
tr 'n2c9********************************************************************************c7'
err="Fehler in Zeile: "sigl "Code:" errortext(rc) "Filename: "||FName||" Version: V"||Version||""
logentry ('Error in BaudAnsi.')
tr ''
tr "n1c9 "err
tr ''
tr 'c9Wichtig:'
tr 'caBitte informiere den SysOp ('||SYSOP||') ueber diesen Fehler !'
tr 'Teile Ihm bitte die cbZeileca, cbCodeca, cbFilenameca und die cbVersionca mit !'
tr 'Vielen Herzlichen Dank fuer Deine Muehe !!c7n1'
if exists("SysData:Log/BaudAnsi.log") then open(ba,"SysData:log/BaudAnsi.log","A")
        else open(ba,"SysData:log/BaudAnsi.log","W")
call writeln(ba,"BaudAnsi Error: "Err)
call close(ba)
call open(SysOpMail,tmpp||port"BaudAnsiSysMail","W")
call writeln(SysOpMail,SysOp.Mail)
call close(SysOpMail)
cleareditor
setmailsubj "BaudAnsi V"||Version||""
loadeditor tmpp||port"BaudAnsiSysMail"
writemail 1
call delete(tmpp||port'BaudAnsiSysMail')
bf
end
tr 'n1c9********************************************************************************c7'
tr 'c6Druecke irgendeine Taste !c7n1 g0'
bf
exit

/***************************************************************************/
/*                                                                         */
/*                               The End.                                  */
/*                                                                         */
/***************************************************************************/
