View Full Version : Persoalan Mengenai Visual Studio.NET
Avicenna
15-04-02, 07:14 PM
Assalamualaikum,
With the release and momentum of Visual Studio.NET and .NET framework, building windows applications in .NET and the developing .NET components seems to be, easier and powerful.
I am looking for a primary programming language, I was learning C and C++ but, I do not know if C# is a serious alternative.
I got 97.5% for both C and C++ programming. I'm on my 2 months semester break, and i'd like to use my free time to enhance my programming skill.
Q1: I am really confused about the emerging of C#. If you do not program for the internet, what is the advantage of switching from C++ to C#?
Personally, generic programming with templates and STL (not supported by c#) is far more important than garbage collection (not supported by c++).
Q2. Is it true that Visual C++ is fading away?
Q3. Microsoft is driving .NET, C# and Visual Basic.NET all the way. So, which one should i choose, Visual C# .Net or Visual C++ .Net?
Q4. Is there anybody who knows what plans microsoft has for MFC, will it eventually die replaced by BCL in .net or some other class library?
Q5. What is the relevance or is there any incentive of still sticking to MFC?
Any view out there is most welcome. I really like to hear from you about this. Please answer in any language you feel comfortable, English or Malay. I'm sorry if the question sounds stupid.
Thanks.
W'salam...
I'm not entirely qualified to answer these questions, since I'm not a Windows developer, but I'll try.
Posting Asal oleh Avicenna
Q1: I am really confused about the emerging of C#. If you do not program for the internet, what is the advantage of switching from C++ to C#?
C# was designed to be a "Java killer". Currently Java is the lingua franca of portible Internet-based web service applications, and .NET is a contender in that area.
Personally, generic programming with templates and STL (not supported by c#) is far more important than garbage collection (not supported by c++).
C# isn't a replacement for C++, it's more like a challenger to Java. C++ (and C too) will still be used to create "big" applications like word processors, database servers and Operating Systems. C# is for the web programming arena, a more "lightweight" kind of programming.
Q2. Is it true that Visual C++ is fading away?
I don't think Microsoft would do that. C++ is still a hugely popular and important language, and thousands of developers use it.
Q3. Microsoft is driving .NET, C# and Visual Basic.NET all the way. So, which one should i choose, Visual C# .Net or Visual C++ .Net?
Hmm...not sure.
Q4. Is there anybody who knows what plans microsoft has for MFC, will it eventually die replaced by BCL in .net or some other class library?
The MFC is the building blocks behind Windows apps, it has to be supported for backward compatibility at least... I don't think anything in .NET can replace MFC.
Q5. What is the relevance or is there any incentive of still sticking to MFC?
Sure, if you want to develop Windows-only applications.
Any view out there is most welcome. I really like to hear from you about this. Please answer in any language you feel comfortable, English or Malay. I'm sorry if the question sounds stupid.
Thanks.
I'm sorry if my answers sound stupid... hehe...
I think bro Hazman would be a good person to answer this better :)
-= Obi-Wan =-
Avicenna
16-04-02, 01:00 AM
Thanks Obi-Wan_Kenobi :), anyone else?
Q1: I am really confused about the emerging of C#. If you do not program for the internet, what is the advantage of switching from C++ to C#?
productivity. C# offers somekind of power with the produvtivity of visual basic.
Q2. Is it true that Visual C++ is fading away?
No. Visual C++ is alive and kicking, Microsoft plan for some mod to MFC, and for certain things VC++ is the only way to go, for example when having a resource intensive application and or computational.
Q3. Microsoft is driving .NET, C# and Visual Basic.NET all the way. So, which one should i choose, Visual C# .Net or Visual C++ .Net?
Visual C#.Net, you have a backgroud in C++, it's natural tendency wehn migrating to .Net with C#. C# was designed with .Net in mind , even ASP.Net is written in C#, C# has a very bright future.
Q4. Is there anybody who knows what plans microsoft has for MFC, will it eventually die replaced by BCL in .net or some other class library?
i don't know much, but there's some
Q5. What is the relevance or is there any incentive of still sticking to MFC?
MFC offers flexibilty and tightly to the OS when you building Windows App.
regards
Avicenna
17-04-02, 01:58 AM
Hmmm..... so, should i learn Win32 API before MFC?
Avicenna, any chance of you learning Java and adding it to your programming skill set?
I'm unqualified to answer your questions. Like Obi-Wan_Kenobi said, Hazman would be a more qualified person. I just hope that you are aware of other options and may one day, try a few of them out to broaden you horizon.
For me, I believe ms will always innovate and these innovations will usually not be backwards compatible. This is what I have gone thru when using VB ver 3.0 until ver 6.0 (vbx to ocx to active x), before I jumped ship to Java. They do this to other products as well, such as their os and office suite.
Posting Asal oleh Avicenna
Hmmm..... so, should i learn Win32 API before MFC?
Well, I don't think too much of MFC. It's very poorly designed (it was once described as how <i>not</i> to design a class library).
I prefer using a library that's open and portable, such as wxWindows (http://www.wxwindows.org/).
MFC isn't the <i>only</i> way to write Windows programs.
-= Obi-Wan =-
Avicenna
17-04-02, 03:14 PM
hamdi, making transition from C++ to Java would not be a problem, the thing is i heard a lot bad things about Java, for example Java programs use about double the memory of comparable C++ programs to store the data (because Java utilize automatic garbage collection, C# will follow the same thing, automatic garbage collection). What is wrong with writing a delete statement at the end of a program :)
LimeWire is a good example of Java program. Use lots of resource and memory.
Java, with the current language features, will never be as fast as C++. This pretty much means that it's not a sensible choice for high-performance software. Well that's what i know about Java, since you have jumped ship to Java, maybe you know it better.
Obi-Wan_Kenobi, MFC is very poorly designed, tell bro. Hazman that :).
Thanks for the link.
Posting Asal oleh Avicenna
hamdi, making transition from C++ to Java would not be a problem, the thing is i heard a lot bad things about Java, for example Java programs use about double the memory of comparable C++ programs to store the data (because Java utilize automatic garbage collection, C# will follow the same thing, automatic garbage collection). What is wrong with writing a delete statement at the end of a program :)
It can lead to dangling pointers and stuff. Memory management is very error-prone. Try doing a delete on a pointer that has already be deallocated. Nasty bugs! ;)
There is a place for every language. Not every project can be done in Java, and not every project should be done in C++.
Obi-Wan_Kenobi, MFC is very poorly designed, tell bro. Hazman that :).
Thanks for the link.
Oh I think he knows my opinions on the matter ;)
In any case, I didn't say that. Many programmers have (including the creator of C++, Bjarne Stroustrup) have said the same.
-= Obi-Wan =-
PianKoon
18-04-02, 01:00 AM
Jez wanna ask you all opinion, what would be the future for the Java and the other open source systems when .NET is released?
It seems that Microsoft strategy is getting stronger, which seems to overwhelm its competitors. I'm still havent decide, whether to go for .NET or the Java/open source.What I mean is to learn the technology before I enter my career world.
panji_alam
18-04-02, 02:14 AM
I think java/open source still have the future...IT literacy is the main factor and microsoft with their ease to use product but very expensive cost will no longer to dominant a market....
We know that the main reason why microsoft become a leader...coz of this simple word "userfriendly"(but not to us..as a developer and administrator).
Java...not just for general application. U can learn it for Java servlet/JSP,Ginie(betul ke aku eja), java bean and so on...there's a lot of potential of java and it up to u to explore that thing. OK..ADIOS AMIGOS!
Avicenna, balance is the key here.
If what you want is high execution speed and low memory utilization at runtime, then use assembly language.
I need to clarify some things:
1. Java's execution is NOT slow. A highly optimised complex algo in Java is about 90% as fast as a highly optimised C++ code for the same complex algo. This is just for the algo and not including any gui. Is that not fast enough?? If you require faster execution, then even C++ is not enough. Better use assembly lang then.
2. Memory has always been an issue with Java, much like performance. Luckily memory is very cheap now. Putting that aside, newer versions of the java runtime is always pushing the performance up and memory utlization down. And there has been some progress. Some slower then others. But, you get this improvements transparantly. No need to change/recompile your code.
3. Java's standard gui (swing) is slow. Agreed. But, differentiate overall Java and swing. A swing expert can optimise swing so that the gui performance and memory usage is acceptable. Ibm has come out with their own java gui (eclipse) that utilizes the native gui a lot, and thus, gives a very impressive gui performance.
Java gives me a good balance of:
1. good productivity, developing alone and also in a team. The java class lib are fantastic. The open source or free tools that complement development such as ant (highly customised make tool), junit (unit testing), jikes (extremely fast compiler), jbuilder (not open source but rather good ide) and cvs (not java, good version control sw).
2. good control. Java gives me something like a hybrid. It's not as high level as vb and it's not as low level as C++. It's somewhere in between.
3. good OOAD. I was very fortunate to have learned and put to practical use, java and OOAD about the same time. Many materials on OOAD that I bought 1 year back when I tried OOAD with vb, suddenly make sense. I have the key to actually realize good reusability (classses, even components) using OOAD, in a way I never could with vb. Java puts prominant OOADP to the fore front in terms of visibility such as Java's interface (equivalent to, I think, C++ virtual class).
4. fast enough. I'm currently doing web based applications and, do it properly, Java jsp/servlets can match asp/php, no problem.
5. good maintenance thru good OOAD. Developing is one thing, maintaining and further enhancement is another thing, a very big thing.
6. portable. Do it once, run it almost anywhere without any major changes. Very nice. Also, if an application need to run faster, just change to whatever better hardware of your choice.
7. embeddable. J2ME is hot in japan.
8. applicable in a very wide scope. The same java knowledge is the base for developing :
a. normal applications (n tier)
b. web based applications (n tier)
c. embeddable devises
d. enterprise applications (n tier)
e. smart card applications
I cencerely do not know of any other language that has this wide a scope and advantage. For me, a very nice balance.
Avicenna
18-04-02, 12:59 PM
Oh god, im really pissed off, I've wrote lotsss of thing about Java and somehow it asked me to re-login, when i did, everything is gone. Everything which makes me sick to write it again, something about Java has no const keyword, no multiple inheritance, something about C#, comparison etc etc etc. Bincang.net cookies expired on periodic basis? I need some fresh air...
Anyway, It makes no sense writing a large application in assembly. Most real-world assembly code that is written consists of small modules that programmers link to program writen in other languages.
Hmmmmm..... Java's Garbage collector takes care of unused memory, but what about files, sockets, bandwidth and similar resources which need to be disposed of as soon as they are not used any more? In C++ we can do that painlessly by using reference counting smart pointers and destructors.
Anyway, thanks hamdi (and Paji Alam). :)
I faced the same thing. Luckily for me, I haven't started writing yet.
To reply, if what you want is a constant, then Java has static final which is roughly equivalent to that.
Multiple inheritance is .... a blessing to some, a devil to others. Java has multiple interface inheritance but not multiple implementation inheritance. 99% of the time, you would not need to do multiple inheritance, UNLESS, you stick to the OOAD school which uses mainly inheritance in their design. I learned about this when I started learning OOAD. Luckily, I'm more inclined towards Peter Coad's way of OOAD and uses association much much more then inheritance. And, this is now mainstream in the OO world. Use single inheritance when needed and it's logical to do so. Use multiple inheritance even less.
Avicenna
18-04-02, 01:32 PM
hamdi, i've updated my previous posting, read it again :).
Hmmm, I missed some questions...
I also have used sockets and files, but in Java and yes, we have to release those resources ourselves, and I don't find it any problem at all.
One important thing Avicenna. C++ is C++. Java is Java. To use C++ effectively, you need to think in a certain way/mode that is most efficient to get the maximum fun and productivity from C++. Same goes for Java. Java has it's own concept and ideas, and to use it to it's fullest, you need to understand or think in Java.
Do not drive a car like you would a motorbike. I have stated why I prefer Java. I know it has many limitations, but it has a good balance.
I know that there are many C++ programmer who either move totally to Java or use both, from following the discussion in javalobby since 3 years ago.
In fact, my OO mentor who is still an avid C++ guy, who still says that C++ is the best and who still say that Java will never beat C++ in terms of speed and power, who, in the last few projects that I was involved with him, choose Java, simply because it was cost effective for him (he required an orb, java has a simple and free orb) and much faster for him, at a slightly advance Java level, to develop compared to developing in C++, which he is an expert (> 10 yrs).
It's your choice really, of what prog. lang. that you want to learn. Just don't lock yourself in. Know your options. Broaden your horizon.
For me, I plan to take up python some time since it's a loose type prog lang. BTW, I'm no C++ expert, only 2 yrs ++ and that was 7 yrs back, in the borlandc ver 3.5 days.
Cau.
Avicenna
18-04-02, 02:16 PM
Hamdi, gotcha point. Thank you for sharing your thoughts, I sincerely appreciate it.
sorry lari dari soalan sikit
hamdi,
1) Dlm OOAD.. kebiasaanya kita perlu buat use case dahulu atau class diagram..
2) Untuk buat OOAD perlukah seseorang tu mahirkan UML konsep, kemudia baru boleh buat OOAD
w'salam
ryzam, peringkat awal saya belajar OO, saya kekok krn mengikut Peter Coad, tindak2 ada, step tiada. Lebih kpd keadaan dan comfort level. Setelah 3 tahun guna OO, saya setuju dgn dia. Tapi, lain orang, lain cara mereka.
Utk saya, saya suka mula dgn use case dulu baru class diagram / object model. Katakan ada perjumpaan dgn domain expert selama 3 hari. Cuba schedulekan utk jumpa hanya waktu pagi je. Waktu petang, buat modeling. Modelkan requirements yg dah diberi oleh domain expert tersebut. Tak perlu tunggu sampai habis dpt semua requirements baru nak model.
Sebabnya ialah, saya selalu timbul soalan2 tambahan semasa buat modeling. Jadi, keesokan harinya, saya akan tanya lagi kpd domain expert ini. Hehe, kadang kala, requirements domain expert bertentangan antara satu requirements dgn satu requirements yg lain. Saya selalunya perasan ini masa buat model.
UML hanyalah notation. Ia sebenarnya sangat berguna, tapi bukanlah suatu kewajipan/pra syarat utk dimahirkan sebelum buat ooad. Saya sampai la ni, masih tak mahir semua diagram2 uml. Tiada keperluan. Gunalah mana2 diagram yg sesuai, tak perlu guna semua diagram2 yg ada. Class diagram adalah permulaan yg baik. Kemudian, tambahlah sequence diagram. Senang2 70% keperluan diagram kita boleh di handle oleh kedua2 diagram ini.
godekgodek
18-04-02, 06:08 PM
Whatever it is , to me, I choose the right tools for my job/project .
Java is undoubtly a very innovative and great technology in the computing arena. You will not regret if you learn it. Peope who master Java , get high pay nowadays .
As for myself, I don't have any experience in Java ( maybe because I am a fanatic of C and C++) . I am doing software development under Linux platform which is the best platform for C/C++ system software engineers.
p/s : Java might be your be choice if you are focussing on business oriented software, but not system software such as OS, device drivers etc. Well, things may changes with boom of J2ME .
panji_alam
18-04-02, 10:53 PM
J2ME agak hot kat japan pasal teknologi wireless.....especially bila 3G wireless lahir...hmmm begitu cepat die org implement bende tu...dulu japan hanya technology follower skrg..dah tergolong dlm big thinker....
Posting Asal oleh godekgodek
Whatever it is , to me, I choose the right tools for my job/project .
As for myself, I don't have any experience in Java ( maybe because I am a fanatic of C and C++) . I am doing software development under Linux platform which is the best platform for C/C++ system software engineers.
Well said... :)
I'm also a Linux/UNIX systems programmer myself, and I'm glad to see that we're not completely extinct yet (at least in Malaysia).
-= Obi-Wan =-
godekgodek, satu setuju dgn pendapat anda. Dan memang, skop penggunaan Java tidak termasuk dlm skop os/low level spt yg saya maksudkan dlm 8 point saya tentang skop2 Java. Hanya, dgn kelapan2 point itu, saya jangka, sudah merangkumi 80% keseluruhan jenis2 sw development.
Obi-Wan_Kenobi, saya adalah penyokong Linux. Saya amat berharap Linux dan mereka yg mahir menggunakannya, lebih2 lagi, yg mahir dalamannya serta kernal nya, ada dan terus wujud utk kepentingan bersama. Semoga awak dan godekgodek dpt teruskan perjuangan utk memahirkan diri, utk kepentingan umat.
panji_alam, awak dah lama guna Java? Fokus awak kat mana? J2SE, J2ME atau J2EE?
hamdi, saya sekrang nie tgh explore buku Craig Larman Applying UML and Patterns - An Introduction to Object-Oriented Analysis and Design and the Unified Process, buku nie kira baguslah memenuhi kefahaman org yanag macam saya ..yang 0 dlm OOAD.. :)
..buku nie chatid yang bagi cadangan.... harga RM128
ryzam, buku tu memang bagus, baik utk permulaan, mahupun pertengahan macam saya ni. Saya pun ada buku tu, errr, company punya la. :)
panji_alam
21-04-02, 08:36 PM
hamdi...
saya takle lama sgt dlm java ni..mula pakai java dlm sekitar 1998...pastu serius balik dlm sekitar thn 2000. Tapi banyak dlm academic purpose..cth mcm AI punyer application dan lain2..
Tak de pengalaman lagi guna java utk enteprise...pasal buku tu...bole citer skit yg menarik dlm buku tu...rasa mcm nak beli...
panji_alam, seingat saya, buku tu menggabungkan OOAD dan methodologi OO. Dari aspek OOAD, ia juga cuba terangkan konsep2 yg lebih advance spt design patterns. Methodologi OO dia berbeza sikit dpd rup, tapi boleh kira masih tergolong dlm cabang rup juga la.
Overall it's a good book.
vBulletin® v3.7.1, Copyright ©2000-2008, Jelsoft Enterprises Ltd.