Which BASIC is more compatible with Quick Basic

Just starting out? Need help? Post your questions and find answers here.
sgsong
User
User
Posts: 11
Joined: Sat Jan 07, 2006 5:45 am

Which BASIC is more compatible with Quick Basic

Post by sgsong »

PureBasic or PowerBasic? I am thinking about porting some numerical computation code from QB to the Windows platform. I know the choice has to be wither Pure or Power, but do not have enough information to decide between them as for the amount of hand coding effort. Thanks!

Shige
dagcrack
Addict
Addict
Posts: 1868
Joined: Sun Mar 07, 2004 8:47 am
Location: Argentina
Contact:

Post by dagcrack »

Well PB4 is up to the task, give it a try.
! Black holes are where God divided by zero !
My little blog!
(Not for the faint hearted!)
Nik
Addict
Addict
Posts: 1017
Joined: Fri May 13, 2005 11:45 pm
Location: Germany
Contact:

Post by Nik »

FreeBasic has nealy 100% compatability, but who want's compatibility with a dinosaure :lol:
So take PB and get a langauge which uses () for procedures which is the only right way imho
josku_x
Addict
Addict
Posts: 997
Joined: Sat Sep 24, 2005 2:08 pm

Post by josku_x »

Well, it's up to you, sgsong.

PureBasic 4 is much easier to learn and to understand than PowerBasic. I have used PowerBasic for 2 months as I was working for a company, but they switched to Visual Basic (don't know why)..

However, many users in this forum have ported codes from other language to Pure, without much issues. Also, Pure doesn't need include files like in C or PowerBasic.

Here's also a little demonstration how Pure and Power are different:
Declaring constants:

PureBasic: #MyConstant = Value
PowerBasic: %MyConstant = Value

Calling functions/procedures:

PureBasic: Function(Parameter1, Parameter2)
PowerBasic: Function "Parameter1, Parameter2"
As a former Power guy, I can say that Pure looks much better and easier. Also, you can use the Windows API easily using Pure, you don't need to declare most of the API functions like in Power.

Pure supports now doubles, so math calculations are now easier to do with decimal numbers.
sgsong
User
User
Posts: 11
Joined: Sat Jan 07, 2006 5:45 am

Post by sgsong »

josku_x wrote:Well, it's up to you, sgsong.

Pure supports now doubles, so math calculations are now easier to do with decimal numbers.
Yes. For what I do, this is very important.
Mike Stefanik
User
User
Posts: 53
Joined: Wed May 03, 2006 6:34 am
Location: California, United States
Contact:

Post by Mike Stefanik »

Also, you can use the Windows API easily using Pure, you don't need to declare most of the API functions like in Power.

To be fair to PowerBASIC, that's not an issue either. They include the header files for the Windows API, you just need to add the following to the beginning of your program:

Code: Select all

#IF NOT %DEF(WINAPI)
#INCLUDE "WIN32API.INC"
#ENDIF
There are strengths and weaknesses to both languages, so it really comes down to what meets your individual needs the best. Asking which is better is like asking which flavor of ice cream is better, chocolate or vanilla. It's largely a matter of personal taste, they're both good.
Mike Stefanik
sockettools.com
thefool
Always Here
Always Here
Posts: 5875
Joined: Sat Aug 30, 2003 5:58 pm
Location: Denmark

Post by thefool »

Its also a question of if you want a growing language or something wich havent been updated for long time...
Matt
Enthusiast
Enthusiast
Posts: 447
Joined: Sat May 21, 2005 1:08 am
Location: USA

Post by Matt »

I use to be able to use powerbasic on my computer, but when I try to compile I get this error:

Title: 16 bit windows subsystem
Message:
C:\WINDOWS\SYSTEM32\AUTOEXEC.NT. The system file is not suitable for running MS-DOS and Microsoft Windows applications. Choose 'Close' to terminate the application.

It use to work, now I get this error when compiling with PowerBasic. I also get this error using some other applications... anyone know how I can fix this?
josku_x
Addict
Addict
Posts: 997
Joined: Sat Sep 24, 2005 2:08 pm

Post by josku_x »

Mike Stefanik wrote:Also, you can use the Windows API easily using Pure, you don't need to declare most of the API functions like in Power.

To be fair to PowerBASIC, that's not an issue either. They include the header files for the Windows API, you just need to add the following to the beginning of your program:

Code: Select all

#IF NOT %DEF(WINAPI)
#INCLUDE "WIN32API.INC"
#ENDIF
There are strengths and weaknesses to both languages, so it really comes down to what meets your individual needs the best. Asking which is better is like asking which flavor of ice cream is better, chocolate or vanilla. It's largely a matter of personal taste, they're both good.
I almost never used win32api includes in PowerBasic, I always declared each function as it would speed up things. Also, as I said, PureBasic doesn't need includes :wink:
Konne
Enthusiast
Enthusiast
Posts: 434
Joined: Thu May 12, 2005 9:15 pm

Post by Konne »

The problem with PB is that if you want to work I this sector later PB will help you almost nothing in a job interview or something like that. On the onther hand I believe that PB is much cheaper.
Apart from that Mrs Lincoln, how was the show?
Fred
Administrator
Administrator
Posts: 18162
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Post by Fred »

I hardly doubt than PowerBasic will help in this case either. To found a job, later the best of either VisualBasic or any java/c# like languages.
Nik
Addict
Addict
Posts: 1017
Joined: Fri May 13, 2005 11:45 pm
Location: Germany
Contact:

Post by Nik »

On the other hand it is far away from impossible to learn visualbasic after you are good in Purebasic. The important thing is just to get your head around the general concepts (even if languages like c# abandon the pointer as one of the most important things) like pointers, functions, and structured code. Even if Purebasic is not oop it's isn't hard to get ones head around oop if you know the background, I suspect you will be even better than pure oop guys since they often don't have an idea that an object is just a structure with functions and maybe a VTable. So I think knowing how to do oop with a non OOP langauge makes you a better OOP user than every pure Java user.
thefool
Always Here
Always Here
Posts: 5875
Joined: Sat Aug 30, 2003 5:58 pm
Location: Denmark

Post by thefool »

Correct. Learning PB will give you an advantage later, as it often involves in learning things on a bit lower level, wich is cool. I often work directly with things, and thats just great!

For some tools/things, this is THE way to deal with it easly and comfortable. If you have more than 1 thing in your pocket; Purebasic, assembler and C#, i believe you are good set for dealing with many tasks.

(even if the company doesnt use any of above languages, but c++ or delphi, knowing the others will help you. Purebasic is my "way" to handle things by hand. And doing that gives you more knowlegde about stuff..)

Fred, since you seem to be reading this thread first let me tell you that purebasic is really nice, and let me ask if you are thinking of going towards a 64bit compiler (now FASM seems to support it) in the later 4.0 dists, after linux and macosx versions are done or in beta..? :)
Last edited by thefool on Sun May 14, 2006 8:58 pm, edited 1 time in total.
dioxin
User
User
Posts: 97
Joined: Thu May 11, 2006 9:53 pm

Post by dioxin »

I think PowerBASIC syntax is closer to QB than Pure Basic and for numerical computations I'd use PowerBASIC.

I also find PowerBASIC easier to learn, maybe because I'm more used to it.
PowerBasic: Function "Parameter1, Parameter2"
That's misleading, PowerBASIC uses Function(Parameter1, Parameter2) with parameters in ().
Quotes are only used to specify the name of the function when it's being exported and as the export name is a literal string would you not expect it to be in quotes? How does Pure Basic specify a function's export name?
Pure supports now doubles, so math calculations are now easier to do with decimal numbers.
Power supports doubles and Extended precision (80 bit) floating point and lots of other number formats.
if you want a growing language or something wich havent been updated for long time...

Until this month Pure Basic was just as "out of date" as PowerBASIC. No decent product is going to go through a major re-write or upgrade more than every year or ywo. Just because Pure Basic has had the most recent update doesn't mean other BASICs are dying.

Paul.
thefool
Always Here
Always Here
Posts: 5875
Joined: Sat Aug 30, 2003 5:58 pm
Location: Denmark

Post by thefool »

dioxin wrote:
if you want a growing language or something wich havent been updated for long time...

Until this month Pure Basic was just as "out of date" as PowerBASIC. No decent product is going to go through a major re-write or upgrade more than every year or ywo. Just because Pure Basic has had the most recent update doesn't mean other BASICs are dying.

Paul.
I dont know about the others, but the comment from a pure powerbasic user was that purebasic is far more updated, and that powerbasic doesnt have any bugs because it havent been updated for long time.
Personally i think powerbasic looks outdated, but this is not a definition.

Seriously, the news on the homepage are several years back..
and the copyright notice at bottom, havent been updated since 2005 (not long time since, but again, its more than 5 months!!)
Also powerbasic for windows costs about the same price as visual C# standard from microsoft, and it doesnt even contain a good gui editor.

But perhaps the powerbasic is closer to Qb, because its older. But for numerical computations, i would use PUREBASIC. why? simple.. try to code your thing in both and compare..
Post Reply