Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Who uses the BAS files
#11
I 've patched QB.EXE file so it shows ANY file extention by default
url=http://zerodivide.h15.ru/cyclone.html]Cyclone v2.5.2 GUI For QBasic 4.5/7.1[/url]
Explorer For DOS
Reply
#12
I always save my programs as text files with the .bas extension.
(Sometimes QB will screw up and corrupt a file saved as a quickbasic file, and it has pissed me off more than once :evilSmile

Cya,

Nemesis
Reply
#13
Interesting! I opened Wordpad, then opened qb.exe, and found two instances of ".bas". The first seemed to be associated with the .obj and .exe extensions, the second seemed to be by itself. Can one change one of these to to ".???" or, perhaps, to ".* " and have all extensions appear in the File, Open direcories? Or, must one go elsewhere to do the necessary change to the default extension.
Ralph, using QuickBASIC 4.5 and Windows XP Home Edition and Service Pack 2, with HP LaserJet 4L printer.
Reply
#14
Hard to say what those two instances go to. My guess however would be that one is for opening and the other for saving. There is a slim chance it could be passed to the compiler, but I'm more inclined to think that QB passes the current file with it's extension instead.
Reply
#15
Quote:QB can load any other file, so why use bas)? i always use text files and open them with qb.....
Using the .BAS file extension for Basic, Quickbasic, and QBasic source programs is a well established convention, just like .C is for C source programs, .ZIP is for zipped files, and .EXE and .COM are for executable files, among many other conventions.

In Basic, BasicA, and GWBasic you could not load your source program into these interpretive compliers unless the file extension was .BAS. The same is true for QuickBasic, which does not accept a source file for compilation unless it has a .BAS extension.

You have discovered that QBasic accepts a .TXT extension. That's fine if it offers you some kind of flexibility. But beware, you are breaking away from the convention. When you review all your QB source programs, not all of them will have the .BAS extension. If you have other files other than QB source that have a .TXT extension, you will need to identify them manually. This is especially true when you want to backup all your source code to a backup device.

You could use the .TXT extension while you're developing and testing, but I suggest that at the end, when you have you're final version, copy it to a .BAS just for uniformity.
*****
Reply
#16
To add to Moneo's post, there is no problem with saving a file with a .bas extension in QuickBASIC, but as text, so it can be edited with any text editor.
Ralph, using QuickBASIC 4.5 and Windows XP Home Edition and Service Pack 2, with HP LaserJet 4L printer.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)