Data Validation and Error Trapping
Tipcorner - binary file access
Updating the Open Source Editor
Spotlight on Polar Coordinates
polar1.bas by Nally
atari2.bas by Nally
polar coordinate demo
[runtimeIcon]
filedialog "Choose Icon","*.ico",icoFile$
if icoFile$="" then wait
shortFile$=SeparateFile$(icoFile$)
filePath$=SeparatePath$(icoFile$)
files filePath$,shortFile$, info$()
'check file size - must be 766 for 16-color icon:
if info$(1,1) <> "766" then
notice "Not a 16-color icon!"
wait
end if
filedialog "Choose runtime engine","*.exe",runexe$
if runexe$="" then wait
'open icon file and read into a string variable:
open icoFile$ for input as #iconfile
saveicon$=input$(#iconfile, lof(#iconfile))
close #iconfile
'open the runtime engine, seek to the proper
'location, and write the icon info at that spot:
open runexe$ for binary as #bin
seek #bin, 21664
print #bin, right$(saveicon$,744)
close #bin
notice "Icon has been included in ";runexe$
wait