You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.
Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.
By Simon Phillips (firstname.lastname@example.org)
7. SR-Message box
SR-Email plugin allows the DBPro application to send email using SMTP and using the pop3 commands in this set to receive the last email sent to an account.
This function will connect to any SMTP email server, if it connects a 1 is returned if 0 is returned then the connection failed. IP$ is the host address e.g. mail.0z0.co.uk, username is the username and password is password.
This Command allows you to setup the email message with your email address which must match the email address link to the account you have connected to, email to is the email address you want to send to and finally the subject is the subject of the email.
SREAddlnSMTP “email message”
This will add a new line to the body of the email that you had just created. Email message is the message to go onto the line is you leave it blank then a blank line is added.
The Command will send the email that you have created using the SREAddlnSMTP and SRESetup. You must be connected to the SMTP server in order for this Command to work.
This will disconnect you from the SMTP server you are currently connected to, if you are not connected to a server the Command will fail.
The SREConnectpop3 Command is just the same as the SREConnectSMTP if a 1 is retuned it connected if a 0 is retuned then it was unable to connect. IP$ is the host address e.g. Mail.0z0.co.uk. The username is the username and password password.
This Command gets the last message sent to your pop3 account it then downloads it and saves it into a folder as the filename you give it above. It is saved in html format.
This command will disconnected you from the current pop3 server much the same as the SREDisconnectSMTP server.
This command will return the number of messages that are available for download you should use this with the SREGetmailpop3 to ensure you are downloading a message that exists.
SR-Printer plugin for DBPro allows the darkbasic application to use the printer that is set as your default printer. You are able to print text anywhere on the page also you are able to print the screen that is currently showing to the printer this will allow you to print anything shown on your dbpro application.
Will get the list of printers that your are able to print out of using commard SRPNumberofprinters and SRPprintername to get the name and the number of printers in the list.
This will return the number of printers that SRPGetprinterlist found use this with SRPprintername to get the name of a printer.
This will return a start of the printer found run this command over and over until you have got to the SRPnumberofprinters if you carry on running it after this a 0 will be returned.
The command will set a new printer to print from use SRPPrintername to get the name of the printer then use this command to set it for printing. The driver string is normal WINSPOOL however it is not allways.
The Command will create a new text doc ready for you to add text to you do not need this Command if you are going to use the SRPprintscreen Command as this Command will create it's own and print out.
This command will change the color of the text you want to add to a page Number to color chart shown below.
SRPAddtext “Text to add”,x,y,textsize
This will add a bit of text to the page you have created with the SRPStartdoc. The x and y int's are for you to tell the page where you would like to place the text on the page e.g. 10,60 the textsize is the same as font size in word it makes it bigger or smaller depending on the number.
SRPAddimage “image name”,x,y
This command will add a bmp or jpg image to the page you have created, you must have used SPRStartdoc before using this command or it will falue.
This will Change the font for the text you are going to add to the page e.g. Courier New. You must run this Command before adding the text to the page or it will only change for the next text added.
Will create a new page for the next bit of text you add to a page, once you run this Command you will be unable to return to the first page if you had to add anything else to that page.
This Command will tell the printer how many copy's of the doc you are creating it wants it to print out.
Will give the doc a title the title must be a string and used before you print the doc.
This will start printing the doc that you have created with the commands above.
The Command will add a screenshot of what ever is showing on the page to the page you are creating for printing.
This command will return a string of the current printer driver.
This command will return a string of the printer name.
SR-FTP plugin allows you to connect to any ftp server, change dir download files and put files.
This function will connect to any FTP server, if a 1 is returned it successfully connected if 0 then unable to connect.
This function will return a 1 if the connection was successful and you are connected otherwise a 0 is returned.
This command will check if a dir exists on the ftp server that you are connected to. If a 1 is returned then it does exist if a 0 then it does not exist.
This will change the dir one the ftp server make sure the dir exists with SRFDirexist command before running this or it may error.
This will change the dir up one level.
This will check if a file exists in the current dir of the ftp server.
Will delete a dir on the ftp server.
Will create a dir on the ftp server the dir name must not exist or an error will be returned.
This command is used with the SRFFindnext and SRFGetfilename to search the server for files use this command to generate the list then the SRFGetfilename and SRFFindnext to get the names out of the list that the first command has created.
Use this with the SRFFindnext and SRFFindfirst to get the names of the files on the ftp server. SRFFindfirst will start the search and the SRFFindnext to continue it.
This command will continue the search if a -1 is returned then that is the last file in the list for searching and then you should not call the SRFGetfilename command after the -1 has been returned otherwise a 0 is returned.
Will download a file from the ftp server the localfilename must be the same name as the file on the ftp server however it can be placed into any folder on your computer.
This will upload a File to the ftp server from a local file.
Will disconnect you from the FTP server you were disconnected.
Will change the port that the ftp server is going to connected onto you do not need to set this if the ftp server uses port number 21 .
SRPaddtext "Hello world", 5, 5, 10
SRPaddtext "Hello world", 5, 5, 10
cls rgb(255, 255, 255)
ink 0, 0
text 0, 0, "Hello world"
Login to post a reply