Print source code from the IDE
#3
I'm not sure how many lines of code you have to send to the printer but if it's not that many I simply use the LPRINT statement. Using the Find Replace, I first change all Print to LPrint and then all the other lines of code which do not have a Print statement I just insert LPRINT " at the beginning of the line. After printing I put the code back to it's original. The more code you want to print the more tedious this is but it works.

IE Original Code

A = 5
B = 33.3
C = 123

If B > C then exit sub
if C > B then 
    F = A * B
    Print F
End If


Using SEARCH - FIND - REPLACE
  Find Print
  Replace with LPrint

Using Copy Paste - Insert LPrint " at the beginning of each line. 

Code to  printer now looks like this

LPrint "A = 5"
LPrint "B = 33.3"
LPrint "C = 123"

LPrint "If B > C then exit sub"
LPrint "if C > B then "
    LPrint "F = A * B"
    LPrint F
LPrint "End I"


It would be nice if there was a print to printer option in the IDE tools but I understand PRINT is a monster on it's own to deal with. Not sure if this helps you at all.
Reply


Messages In This Thread
Print source code from the IDE - by Kernelpanic - 11-26-2022, 10:45 PM
RE: Print source code from the IDE - by mnrvovrfc - 11-26-2022, 11:51 PM
RE: Print source code from the IDE - by Dimster - 11-27-2022, 02:40 PM
RE: Print source code from the IDE - by bplus - 11-27-2022, 03:42 PM
RE: Print source code from the IDE - by mnrvovrfc - 11-27-2022, 07:05 PM
RE: Print source code from the IDE - by bplus - 11-27-2022, 06:17 PM
RE: Print source code from the IDE - by mnrvovrfc - 12-10-2022, 07:47 AM
RE: Print source code from the IDE - by Dimster - 12-10-2022, 07:00 PM
RE: Print source code from the IDE - by SMcNeill - 12-10-2022, 08:33 PM
RE: Print source code from the IDE - by bert22306 - 12-10-2022, 09:08 PM
RE: Print source code from the IDE - by Pete - 12-11-2022, 10:27 PM
RE: Print source code from the IDE - by bplus - 12-12-2022, 03:46 AM
RE: Print source code from the IDE - by mnrvovrfc - 12-12-2022, 08:50 AM
RE: Print source code from the IDE - by SMcNeill - 12-12-2022, 09:43 AM
RE: Print source code from the IDE - by Pete - 12-12-2022, 03:44 PM



Users browsing this thread: 7 Guest(s)