'
' Forum Code-Tag-Fix v1.1 by Mike McLaren, K8LH
'
' replaces <tab> characters with spaces (tabs = 8).
' does not alter your source file.
'
' Instructions
'
' 1 - select your source file from the File Dialog
' 2 - select output text displayed in console window
' 3 - copy to clipboard using <ctrl-C> or <edit> <copy>
' 4 - paste between code tags in your Forum post
'
' JustBASIC v1.01
'
filedialog "Source File?", "*.asm", fileName$
if fileName$ <> "" then
open fileName$ for input as #f
while eof(#f) > -1
line input #f, aLine$ : hpos=1
for x = 1 to len(aLine$)
if (mid$(aLine$,x,1)<>chr$(9)) then
print mid$(aLine$,x,1); : hpos=hpos+1
else
while hpos MOD 8 <> 0
print " "; : hpos=hpos+1
wend
print " "; : hpos=hpos+1
end if
next x
print
wend
close #f
end if
end