i need to program

If you have questions about any aspect of QBasic programming, or would like to help fellow programmers solve their problems, check out this board!

Moderators: Pete, Mods

Post Reply
User avatar
Deleter
Veteran
Posts: 119
Joined: Sat May 07, 2005 7:31 pm

i need to program

Post by Deleter »

Its been a year or so since i've programmed, and it really stinks. here's my dilemma: Microsoft Windows 2000 Proffessional Edition.
It really doesn't like QB. I didn't see a search function for these forums, so I hope I'm not asking a question that's been asked already. I can run the program, but it soon crashed (within a minute) giving me some error. If anyone has any suggestions, I'd be gratefull to hear them.
Thanks for replying, and sorry if this has been asked already.
MystikShadows
Veteran
Posts: 703
Joined: Sun Nov 14, 2004 7:36 am
Contact:

Post by MystikShadows »

Hi Deleter and welcome to Pete's QBasic Site.

A good alternative would be to give FreeBasic a try http://www.freebasic.net

it's as close as you can get to the QBasic syntax. It compiles, it does Windows Console, Windows GUI (with the API), DOS 32 bits and Linux...basically today it's considered, by many as the next evolutionary step for us QB coders :-).

I don't think you'll regret making the move at all. Have a look at it. it's definitaly worth the mouse click. Remember that Freebasic is a compiler. you an either use your favorite editor or better yet...take a look a FBIDE by VonGodric at http://fbide.sourceforge.net/ and IDE especially for FreeBasic.

These two combined is sure to not only kick you right out the door, pillows and all...but you'll be glad to be outside ;-). It's an awesome combination. I know you won't regret this at all :-).
When God created light, so too was born, the first Shadow!

MystikShadows

Need hosting? http://www.jc-hosting.net

Interested in Text & ASCII development? Look no further!
http://www.ascii-world.com
Guest

Post by Guest »

O_O THANKS A MILLION! I had downloaded freebasic, but was completely lost as to what to write code with...this will help me get started again. now as far as freebasic, any links to converting qb to fb? or just tutorials?
Thanks alot, Deleter
User avatar
Deleter
Veteran
Posts: 119
Joined: Sat May 07, 2005 7:31 pm

Post by Deleter »

whoops, forgot to sign in, lol. i like this program, but is there a way to make it fullscreen? a 320x200 box just doesn't cut it.
thanks
User avatar
Kyle
Veteran
Posts: 107
Joined: Thu Apr 14, 2005 2:41 pm

Post by Kyle »

Of course. read up on the SCREEN statement here : http://freebasic.net/keywords.php?pagenum=5#214

The fourth parameter is a switch for fullscreen. You can also change the resolution, colour depth and the number of pages you need.
Guest

Post by Guest »

aha, this reference will be usefull, didn't think to look on their site, duh.
However, anytime i change the video pages, the program will run and all, but upon exit my program, the IDE will crash saying invalid memory was referenced or something. i realize this is a beta still, so is there a fix or not?
User avatar
Kyle
Veteran
Posts: 107
Joined: Thu Apr 14, 2005 2:41 pm

Post by Kyle »

Hmm, never had that error. Does it give an error code or segment or something? Talk to v1c on QBNews or Freebasic.tk if you can.
Z!re
Veteran
Posts: 887
Joined: Wed Aug 04, 2004 11:15 am

Post by Z!re »

Deleter, post your code.

Also, look in the Docs folder, it should be in your FB installed directory.

Also, make sure you ran Install.bat, or used the FB Automatic Setup System, available from the Plantasy Studios site, link is in my signature.
I have left this dump.
User avatar
Deleter
Veteran
Posts: 119
Joined: Sat May 07, 2005 7:31 pm

Post by Deleter »

its little more than an example i pulled off the freebasic site
It's obviously not freebasic though , since the program compiles and runs, But when i close the window, the IDE crashes.

Code:
randomize timer
' Set good old 320x200 in 8bpp mode, but with 2 pages
SCREEN 13,,2
COLOR ,15
DIM x AS INTEGER
x = -40
' Let's work on page 1 while we display page 0
SCREENSET 1, 0

DO
CLS
Getmouse mx, my ,, buttons
LINE (x, 80)-(x + 39, 119), int(rnd*256), BF
pset (mx,my),1
x = x + 1
IF (x > 319) THEN x = -40
' Wait for vertical sync
WAIT &h3DA, 8
' Copy work page to visible page
SCREENCOPY
LOOP WHILE INKEY$ = ""
Z!re
Veteran
Posts: 887
Joined: Wed Aug 04, 2004 11:15 am

Post by Z!re »

Are you sure you have the latest version of FBIDE?

Are you using VonGodrics IDE or some other?
I have left this dump.
User avatar
Deleter
Veteran
Posts: 119
Joined: Sat May 07, 2005 7:31 pm

Post by Deleter »

Yes I'm using vondrics and assuming .33 is the newest version, then yes, i have then newest version.
User avatar
Kyle
Veteran
Posts: 107
Joined: Thu Apr 14, 2005 2:41 pm

Post by Kyle »

What kind of error does it give? Is it the IDE's own error or a Windows one saying it needs to close and asking for an error report? I've been getting the latter quite a bit now, but I don't know why.
User avatar
Deleter
Veteran
Posts: 119
Joined: Sat May 07, 2005 7:31 pm

Post by Deleter »

the latter. says that the program is referencing memory that cannot be reached or sumsuch. if i just run it with F5 , it doesn't crash, and sometimes it crashes, sometimes not with F9 (full compile + run)
User avatar
Kyle
Veteran
Posts: 107
Joined: Thu Apr 14, 2005 2:41 pm

Post by Kyle »

Yeah, I used to get the same thing. Might be a bug in the IDE.
VonGodric

Post by VonGodric »

Hello, yeah I'm afraid that it is bug of the IDE itself. There's no fix at the moment for this becouse I haven't worked on 0.3 line of IDE anymore. But check fbide.sourceforge.net around 15th of this month -fbIde 0.4 will be released then -if everything goes well.
User avatar
Deleter
Veteran
Posts: 119
Joined: Sat May 07, 2005 7:31 pm

Post by Deleter »

sounds good. :)
Post Reply