DecemberChild Posted July 27, 2004 Posted July 27, 2004 I've been programming in VB.NET for some time now, and before that I programmed in VB6. The thing is that I don't want to program VB.NET the rest of my life. I know how to use OOP and so on, which I hope may help me converting to another language. I've been thinking of programming languages such as C++ and C#.. C# seems nice with the GUI-Designer (which I recognize from VB.NET too ;).. ), but on the other hand, I have no experience in C# (and only very little in C++). ...So I have a couple of questions: 1. What are the bigger advantages / disadvantages of C# and C++ compared to each other? 2. One of the reasons I would like to change from VB.NET is because of the lack of information regarding DirectX-programming. Most of it seems to be for C++. How big are the differenses between the languages in DX-programming? 3. C# has an GUI-builder which I already know. I've tried the dialoguebased builder in C++.NET and didn't like it at all.. The question is: Is it worth the effort to learn how to program Window-GUI's in C++ or is it just a waste of time? 4. I've seen some code in C# and it looked very similar to C++-code. How big are the code-differenses? I don't know if one or more of these questions may be stupid, but I have absolutely no C#-experience, and as i said.. very little C++-experience where I have only typed a few consolebased programs and learned how to use If- and for-statements and so on. Only a little basics ;). So I hope you will be a little indulgent with my poor knowledge of these systems ;). Thanks in advance. /Eric Lavesson. Quote
bri189a Posted July 27, 2004 Posted July 27, 2004 When .NET came out I transferred from VB6 to C#. I'm glad I did. I look at VB.NET and it seems so convoluted to me; I understand it, and that's the nice part about .NET...the libraries are the same, but the syntax is so odd. C# and C++ syntax are almost exact; the only major differance is the switch statement, and it's just a minor element of it. Once you get into C# you will find that it flows off your fingers tips so much better and you can see OO so much more clearly. I may be wrong because I don't use it; but I don't think VB supports operator overloading, whereas C# does; it has come in useful to me a few times. Also you can work with pointers and address and things that I don't think you can do in VB. Again all you VB'ers reading this, I don't use your language (unless I have to) so I may be mistaken. With direct x, if you understand C#, you'll understand 99% of what you see in C++.NET... or at least be on the right track. Also you'll be like myself, cross language capable (though you'll become rusty in VB like I did), but this becomes an assest to you because now you can look at code written in virtually any language and make sense of it, becasue C, C++, C#, JavaScript, and other all have very similiar syntax and features, VB doesn't off-shoot to much else that I know of. And it's just like spoken language, once you learn a second, the rest come quick. Definitely make the transition; VB.NET is as capable of C#, but C# is more intutitve to other languages out there. If your comfortable where you at though, then you should stay and VB; but it doesn't sound like your comfortable (that's why I switched). Quote
Administrators PlausiblyDamp Posted July 27, 2004 Administrators Posted July 27, 2004 As C# is also a .Net language you will probably find you are already familiar with a lot of the concepts from your VB.Net experience. All you will need to learn for C# will be the different syntax and one or two other features (like operator overloading). I would recomend any VB.Net developer to get some exposure to C# (just the same as I would recomend any C# developer get some VB.Net experience) as you will often find articles / samples in the other language than you are developing in ;) As to the benefits of the C# as opposed to VB.Net style everybody has their own opinion as to which they prefer (personally I have no real preference - each does pretty much the same job and the differences in functionality are getting less in the next version anyway), but that's all it is a personal preference for a language style. I have very little doubt this thread will end up with one or two postings passing of their own opinions as fact - I recomend you try C# and make up your own mind, after all any extra knowledge looks good on a CV ;) C++ on the other hand is a different kettle of fish entirely, and although the syntax is similat to C# (that was one of C# design ideas) the way C++ language operates is very different. For example C++ allows multiple inheritance while .Net doesn't, IIRC C++ doesn't have interfaces (abstract classes would be used instead) while .Net does. .Net has automatic memory management through the Garbage Collector while C++ leaves a lot of this open to you (pointer arithmetic, having to track / free memory allocations) I wouldn't discount learning C++ but it isn't going to be as easy as C#, and if I was considering C++ I would definately start with something simple (console based app, basic IO) rather than Windows / DirectX. Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.