Visual Basic 6 vs. Visual Basic.Net

QueHuong

Platinum Member
Nov 21, 2001
2,098
0
0
I heard they are very different, as opposed to .Net being a newer version of 6. I want to learn a simple language (already have a little experience in C++) that's easy to build GUI programs to run on Windows, mainly XP, and future Windows...so the language shouldn't be obsolete later on. Which one should I learn? And any recommendations for books?
 

thatbox

Senior member
Dec 5, 2002
253
0
76
I've just been looking through the diffs, and I didnt see anything major. Just little stuff, like newly required parentheses in function calls and the abilty to +=, -=, etc. But I'm a VB noob anyway, so I might not catch some of them.
 

BlueWeasel

Lifer
Jun 2, 2000
15,944
475
126
I am going through the same thing as you - I want to learn VB and decided to go with VB6 Pro over VB.net. I really just want to make relatively simple programs in Windows and maybe pick up VBA along the way.

I just bought a VB6 book from the FS/FT forums. I can't remember the exact title, but the author was John Smiley. It came recommended by several users around here for VB5 beginners.
 

tkdkid

Senior member
Oct 13, 2000
956
0
0
You can program as simple or as complex as you want in vb .net. If you want to program using the vb6 "style" then go ahead.

The advantage is that when you want to get into oop or do some design patterns and really extend your knowledge, vb .net can handle it.
 

igowerf

Diamond Member
Jun 27, 2000
7,697
1
76
I doubt it. The runtime files are widely available and VB6 is flexible enough to still be useful for a while. There are still people programming with VB 5.0 so I don't really see a problem. If you can find VB6 for cheap, I say go for it.

VB.net would give you a solid basis for any future Microsoft revisions though. I heard that the Standard Editions of VB.net and VC++.net are bad though. I can't remember why.
 

straubs

Senior member
Jan 31, 2001
908
0
0
I said this in another thread. Developing in .NET will force all the users of your software to download the .NET framework at a whopping 26 MB (AFAIK).

That is a pretty big difference! I can make pretty lengthy programs in VS 6.0 in under 200kb. If I ported this code to .NET, the end user would have to download 26 MB + 200kb... It's a one time deal, but still.
 

flamingsouls

Member
Oct 9, 1999
86
0
0
Developing in .NET would require your users to download the .NET framework....but if you use the technologies that I think .NET is suppose to be used for, such as web applications, then it doesn't require users to download anything. Developing in .NET is a huge difference than VB6. .Net is completely object oriented, and thus, more complex thinking can be used to develope applications.

But if you just want to do simple GUI's for Win32, then use VB6. If you want to integrate different peripherals, then .NET will be slicker and faster.


Just my experience.

Josh
 

straubs

Senior member
Jan 31, 2001
908
0
0
I think by far there are more "stand alone" applications than web apps developed in Visual Studio. But you are right, for WEB apps, it's probably better. However, if you're making a stand alone exe for downloading and running, VS6 will do it 26 MB smaller. I guess I just like bringing this up because I've never seen a compilers REQUIRE a freakin 26 MB "extra" framework just to run any program.... I know there has always been the VBRUN___.dll's in the past, etc, but they were never showstopping big like the .NET one is.

VS .NET will practically guarantee your code will not run on anything but windows, whereas with VS6 some simple #define code will make it cross platform. This point only applies if you care about other OS's than windows, of course. :)

Also, (I believe) you should be able to cut & paste your code from 6.0 into .NET at any time in the future and have it work. The reverse is not true.
 

flamingsouls

Member
Oct 9, 1999
86
0
0
^^^^^


Cutting and pasting code from VB6 does not always work. Simple things such as working with file I/O is not the same. So, if you are going to do .NET, learn the language from scratch, because while VB6 may be nice to know, it is a completely different ball game.

thx
Josh
 

Descartes

Lifer
Oct 10, 1999
13,968
2
0
I heard that the Standard Editions of VB.net and VC++.net are bad though. I can't remember why.

Then don't say it.

guess I just like bringing this up because I've never seen a compilers REQUIRE a freakin 26 MB "extra" framework just to run any program

Java requires the JRE; however, not as large as the .NET Framework. I see this issue as really moot, as if you're developing an application of value, installing the framework is a non-issue. Also, future platform releases will already have the framework installed.

VS .NET will practically guarantee your code will not run on anything but windows, whereas with VS6 some simple #define code will make it cross platform.

Huh? Yes, some simple #defines will make your code cross-platform in VC++ 6. I'm going to assume that was a joke. .NET is inherently cross-platform, it's just that implementations are not yet pervasive. Have a look at Mono for one example. Microsoft also has a shared-source implementation that runs on FreeBSD and Linux called "Rotor". There are implementations available for the Win Forms facets of .NET, ADO.NET, and even ASP.NET. Yes, .NET DOES run on other platforms, and it will only get better. Note that there are standards for .NET, including: the CLI, CLS, CTS, and CIL. All of the standards allow for cross-platform interoperability with the more significant subset of .NET. Have a look at the ECMA standard and of course MSDN.

Also, (I believe) you should be able to cut & paste your code from 6.0 into .NET at any time in the future and have it work.

Yes, there is a fairly powerful upgrade wizard, and it will even convert your web classes to ASP.NET pages in VS.NET 2k3, but there comes a time when evolving legacy code is simply no longer feasible.
 

eklass

Golden Member
Mar 19, 2001
1,218
0
0
Originally posted by: MindStorm
But will VB6 become obsolete any time soon?

it already has. MS has already started getting you VB nuts to migrate over to C#

if you go into VS .NET and go intot the help and look at some functions, let it display the code for C# and VB and you'll notice they're quite similar
 

straubs

Senior member
Jan 31, 2001
908
0
0
The point is that Microsoft will never really want them to be 100% cross-platform. We're talking about a convicted software monopolist here. In my understanding, .NET is cross-language, not really cross-platform. What happens when MS sues Mono? Goodbye non-Win32 .NET ports! I'm not sure why you're so convinced that the cross-platform interoperability "will only get better." The MS marketing folks sure say so, but looking at their track record, in all likelyhood, it will get worse... :(

I read this about Mono:
"Some C# programs can run on .NET and Mono - but not any appplication that uses the Microsoft .NET libraries (99.99% of them)
Microsoft released the source to an implementation that compiles and runs on Windows, FreeBSD and MacOS 10.2.
As per Microsoft license for this release, you can't do any comercial work with it. You can't modify it and distribute for comercial use.
It's useless."

If that's true, then it seems pretty limited.

It really seems like a mixed bag. Only time will tell. I am VERY wary of vendor lock-in when it comes to MS products. (as you can see ;)) Right now I can freely compile my code in bot VC++ and gcc no problem... I'd like to see that done in C#/.NET
 

pac1085

Diamond Member
Jun 27, 2000
3,456
0
76
I read this about Mono:
"Some C# programs can run on .NET and Mono - but not any appplication that uses the Microsoft .NET libraries (99.99% of them)
Thats wrong. For S.W.F, yeah, but that is getting implemented in mono by using wine. I've built many non-gui libraries and programs that compile fine with the Microsoft .NET framework and Mono. If you want a GUI, you can use Gtk-sharp which runs on many platforms.


As far as microsoft suing ximian for mono? I dont see it happening read this
 

igowerf

Diamond Member
Jun 27, 2000
7,697
1
76
Originally posted by: Descartes
I heard that the Standard Editions of VB.net and VC++.net are bad though. I can't remember why.

Then don't say it.

Just giving him a heads up, just in case. There's no need to get defensive. I checked the Amazon reviews and it seems that VB.net Standard just has limited support for VB6 projects. VB.net SE doesn't have the wizard to import and upgrade code. It also doesn't support legacy controls from VB6. Otherwise, it seems to be pretty solid. Since he seems to be starting from scratch, then VB.net Standard works fine.
 

onelin

Senior member
Dec 11, 2001
874
0
0
Keep in mind, VB 6.0 code will not be 100% compatible with .NET if you choose to migrate later. (Not that I'm insisting you choose .NET now, heh) Direct from MS they stated it's only 80% compatible, and my school chose not to buy VB .NET as a result. They are definitely pushing .NET, because they obviously won't sell you 6.0 anymore. What's a school to do for people still taking old VB app courses if people's code isn't going to work right between IDEs? People need to be able to back and forth between them IMO...but students often have no money and may only have access to an old compiler off campus.
 

Descartes

Lifer
Oct 10, 1999
13,968
2
0
Originally posted by: onelin0
Keep in mind, VB 6.0 code will not be 100% compatible with .NET if you choose to migrate later. (Not that I'm insisting you choose .NET now, heh) Direct from MS they stated it's only 80% compatible, and my school chose not to buy VB .NET as a result. They are definitely pushing .NET, because they obviously won't sell you 6.0 anymore. What's a school to do for people still taking old VB app courses if people's code isn't going to work right between IDEs? People need to be able to back and forth between them IMO...but students often have no money and may only have access to an old compiler off campus.

There are some fundamental misconceptions of what VB.NET is in the above...

VB.NET is not an IDE. VB.NET is a *revolution* in the language, not an evolution. Talking between VB6 code and VB.NET code is like trying to talk between Java and C (not C++) direct. Yes, just as Java can talk with C libraries through JNI, one can talk to VB6 libraries in VB.NET through the interop facilities in .NET.

You don't need to buy VB.NET, you can download it for free. Your concern about VB6 not being compatible with VB.NET sounds like it's more from an IDE-perspective, as the languages are entirely different.

Again, it's a revolution in the language. If you want to do .NET, do .NET. If you want to do VB6, do VB6. But please don't think that you could be able to do *both* with the same codebase.
 

onelin

Senior member
Dec 11, 2001
874
0
0
Well I suppose that's more clear. The problem being, you CAN'T stick to VB6 if you want to...unless you find someone selling a copy. So it's VB.NET or nothing, right? ;)

Didn't know it was free, though, that's a nice plus.

I guess I should have read the initial post more carefully, i.e. 'they are very different'.

Thanks for some insight on the matter, Descartes, please pardon my ignorant never never land thoughts on it all. :)
 

QueHuong

Platinum Member
Nov 21, 2001
2,098
0
0
Someone said VB.Net is OO, so will it be more similar to C++ or VB6? And poll added.

Dammit, how do you add a poll after you already created the thread?
 

everman

Lifer
Nov 5, 2002
11,288
1
0
How much experiance do you have with C++ really? I would go with that since so many programs are written in C and C++. I doubt it will ever be obsolete in your lifetime (there's still progs writtin in COBOL being used right now).
 

calpha

Golden Member
Mar 7, 2001
1,287
0
0
There's too many apps out there for vb6 to ever be obselete---

And the runtime files for VB used to be a big deal btw---

As far as 6 vs .NET----descartes had the best advice, and that's not to intermingle the two. I concur completely. Don't think "I can convert this to .NET later". There's conversion tools yes---but the point is, the whole fundamental of the langauge is redefined .NET. Everything besides the basic syntax is different.

as far as .NET being free--the only way I'm aware that it's free is b/c you can use command line compiles w/ the .net sdk (free), and create .exe's that way? Am I missing something else there?

I myself go by the following mantra:
Every other product version from Microsoft for a given product. I made an exception w/ VStudio 6.0.
Never EVER use a new Microsoft's product's first version.
 

QueHuong

Platinum Member
Nov 21, 2001
2,098
0
0
Ok, I'll clarify what I'm looking for. I don't have a lot of experience with C++, just up to AP Comp Sci.

As for which VB to choose, I'm looking for one that will let me create simple windows program quickly and easily. I'm not going to sell it nor am I making anything complex. Just something I can do as a hobby. I would like that language to still be in use for years. I already have VB6 from the Visual Studio Professional package I got at academic discount; and I have Visual Studio.Net Professional that I got free from that MS convention they had a while ago at different colleges...so I already have everything I need, except a good beginner's book.


 

straubs

Senior member
Jan 31, 2001
908
0
0
Originally posted by: MindStorm
Ok, I'll clarify what I'm looking for. I don't have a lot of experience with C++, just up to AP Comp Sci.

As for which VB to choose, I'm looking for one that will let me create simple windows program quickly and easily. I'm not going to sell it nor am I making anything complex. Just something I can do as a hobby. I would like that language to still be in use for years. I already have VB6 from the Visual Studio Professional package I got at academic discount; and I have Visual Studio.Net Professional that I got free from that MS convention they had a while ago at different colleges...so I already have everything I need, except a good beginner's book.


There are TONS of tutorials and guides one the web, complete with downloadable code and complete projects. If you need a book to read (or if that's easier for you to follow) there are tons of those as well.
 

Descartes

Lifer
Oct 10, 1999
13,968
2
0
Originally posted by: everman
How much experiance do you have with C++ really? I would go with that since so many programs are written in C and C++. I doubt it will ever be obsolete in your lifetime (there's still progs writtin in COBOL being used right now).

There are even new projects being implemented with Fujitsu Cobol .NET. Here is some more info...

Originally posted by: calpha
as far as .NET being free--the only way I'm aware that it's free is b/c you can use command line compiles w/ the .net sdk (free), and create .exe's that way? Am I missing something else there?

No, you're correct. Of course, why would Microsoft give away VS.NET for free? VS.NET is quite possibly the most advanced IDE to date. There are free alternatives, including Web Matrix for ASP.NET, and SharpDevelop a pretty good open-source IDE in C#. Also note that Microsoft is highly promoting Web Matrix even though it's free.

You can download the J2SE SDK for free, but many of the better IDEs are costly.