Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. C#

C#

Scheduled Pinned Locked Moved The Lounge
c++helpcsharptutorialquestion
36 Posts 17 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Steven Hicks n 1

    welll.... I've been working with C# and ASP.net solely for the last six months, I miss c++. Get a good book, maintain a seperate coding style for developing in c# than MFC. Try creating small applications. Take a look at the quickstarts and implement new features in them. However, C# is really nice about support built in for Regular expressions and collections. -Steven Hicks

    CPA

    CodeProjectAddict

    Actual Linux Penguins were harmed in the creation of this message.

    More tutorials: Ltpb.8m.com: Tutorials |404Browser.com (Download Link)

    N Offline
    N Offline
    Nitron
    wrote on last edited by
    #9

    (Steven Hicks)n+1 wrote: C# is really nice about support built in for Regular expressions and collections. is that like std::find_if and std::vector? :rolleyes: [edit] weird, this was supposed to go to s. hicks :~ [/edit] ~Nitron.


    ññòòïðïðB A
    start

    S 1 Reply Last reply
    0
    • G Gary Kirkham

      Nitron wrote: Does anyone else have this problem? Not really, like any other undertaking, how quickly you progress depends upon your attitude and desire. Not to say that there hasn't been frustration along the way. Nitron wrote: What book would you recommend to get into it? I found "C# for Experienced Programmers," from Deitel, to be very helpful. Gary Kirkham Forever Forgiven and Alive in the Spirit He is no fool who gives what he cannot keep to gain what he cannot lose. - Jim Elliot Me blog, You read

      N Offline
      N Offline
      Nitron
      wrote on last edited by
      #10

      Gary Kirkham wrote: I found "C# for Experienced Programmers," from Deitel, to be very helpful. thx! I'll check it out this weekend @ the bookstore. ~Nitron.


      ññòòïðïðB A
      start

      1 Reply Last reply
      0
      • N Navin

        Nitron wrote: I got used to doing everything the MFC way, now it's like I'm stuck. There's the real problem. To kick the MFC habit, you could try cold turkey, but I was successful with the gum. (There's also a patch.) I've been MFC-free for four years now, and have never felt better! The generation of random numbers is too important to be left to chance.

        S Offline
        S Offline
        stephen hazel
        wrote on last edited by
        #11

        Hey. That's not funny. My Grandpa died trying to quit mfc... I got no problem quitting mfc. It's repulsive. But i'd just like to see microsoft TRY to pry win32 out of my cold dead dusty hands... X|

        E 1 Reply Last reply
        0
        • S stephen hazel

          Nitron wrote: I just can't seem to get motivated to learn it. I feel the same as you. .net just seems like a step down as far as "purity"... Sure it's got everything including the kitchen sink, but there's just something uncool about it... Not that I wouldn't sacrifice my firstborn to have someone pay me to learn and use it, but, you know... As far as developing stuff for myself, I just don't like it yet. ...Steve

          J Offline
          J Offline
          Judah Gabriel Himango
          wrote on last edited by
          #12

          Steve Hazel wrote: .net just seems like a step down as far as "purity"... Compared to what? COM? MFC? VB6? Man, .NET blows all those away as far as purity goes: .NET is so consistent across all its APIs -- whether that be web services, web apps, client apps, distributed apps, Windows services -- the "pure", consistent, virgin feeling of .NET is what initially drew me to it. I was sick of all the bizarre twists and turns of Win32, MFC, and COM: different threading models, programming styles, memory managements, naming conventions, and API designs. When coming from all that, .NET was a total breath of fresh air to and really puts the former frameworks/APIs to shame in my mind. It is really a unification of many different application programming concepts, so that you can keep your code consistent, rather than having to deal with multiple frameworks with different programming styles. I think one of the reasons for this is the FxCop software that gets run on the framework, checking for design inconsistencies, propery naming conventions, and so on. It really gives .NET a streamlined, consistent feel that is far more "pure" than Microsoft's previous application framework attempts. Just my humble opinion. :)

          Tech, life, family, faith: Give me a visit. I'm currently blogging about: Homosexuality in Christianity Judah Himango

          M S O 3 Replies Last reply
          0
          • N Nitron

            (Steven Hicks)n+1 wrote: C# is really nice about support built in for Regular expressions and collections. is that like std::find_if and std::vector? :rolleyes: [edit] weird, this was supposed to go to s. hicks :~ [/edit] ~Nitron.


            ññòòïðïðB A
            start

            S Offline
            S Offline
            Steven Hicks n 1
            wrote on last edited by
            #13

            Looks like an db indexing issue chris. In reguards to the built insupport for collections its like Java with memory management and holding individual items. Also, its easier to build abstract data types and collections (based/inherited on List item/arraylist/whatnot). Regular expressions are a simple thing compaired to find_if, its like an SQL search query compaired to ilterating through all the rows and doing a string.find/indexof. Just a small note... if you don't watch out this will piss you off a lot (like it did for me at first) String.Replace returns the modifed string, unlike CString::Replace. -Steven

            1 Reply Last reply
            0
            • N Nitron

              I just can't seem to get motivated to learn it. Every time I get a small project that I think would be good to learn C#, I get frustrated because I don't even know how to read/write files and figure I could just do it faster in C++ anyway. Does anyone else have this problem? What book would you recommend to get into it? I've gone through the articles here, but I think I need more. I dunno, I got used to doing everything the MFC way, now it's like I'm stuck. It's still hard not to have a seperate .h and .cpp :~ ~Nitron.


              ññòòïðïðB A
              start

              B Offline
              B Offline
              Brian Delahunty
              wrote on last edited by
              #14

              C# and the .NET Platform by Andrew Troelsen. Inside C# by Tom Archer. Only two books you need. Regards, Brian Dela :-) Blog^ Co-author of The Outlook Answer Book... Go on, pre-order^ it today! Regular Expression Library builder^

              1 Reply Last reply
              0
              • S stephen hazel

                Hey. That's not funny. My Grandpa died trying to quit mfc... I got no problem quitting mfc. It's repulsive. But i'd just like to see microsoft TRY to pry win32 out of my cold dead dusty hands... X|

                E Offline
                E Offline
                eggie5
                wrote on last edited by
                #15

                Are you serious, because I laughed. If you are I feel bad... /\ |_ E X E GG

                S 1 Reply Last reply
                0
                • J Judah Gabriel Himango

                  Steve Hazel wrote: .net just seems like a step down as far as "purity"... Compared to what? COM? MFC? VB6? Man, .NET blows all those away as far as purity goes: .NET is so consistent across all its APIs -- whether that be web services, web apps, client apps, distributed apps, Windows services -- the "pure", consistent, virgin feeling of .NET is what initially drew me to it. I was sick of all the bizarre twists and turns of Win32, MFC, and COM: different threading models, programming styles, memory managements, naming conventions, and API designs. When coming from all that, .NET was a total breath of fresh air to and really puts the former frameworks/APIs to shame in my mind. It is really a unification of many different application programming concepts, so that you can keep your code consistent, rather than having to deal with multiple frameworks with different programming styles. I think one of the reasons for this is the FxCop software that gets run on the framework, checking for design inconsistencies, propery naming conventions, and so on. It really gives .NET a streamlined, consistent feel that is far more "pure" than Microsoft's previous application framework attempts. Just my humble opinion. :)

                  Tech, life, family, faith: Give me a visit. I'm currently blogging about: Homosexuality in Christianity Judah Himango

                  M Offline
                  M Offline
                  Marc Clifton
                  wrote on last edited by
                  #16

                  Judah Himango wrote: .NET is so consistent across all its APIs Right. That's why, DataColumn has a ColumnName property, not Name, as it is everywhere else in the API's. It's the inconsistencies that get you. And .NET has them as well. Marc My website
                  Latest Articles: Object Comparer String Helpers

                  1 Reply Last reply
                  0
                  • J Judah Gabriel Himango

                    Steve Hazel wrote: .net just seems like a step down as far as "purity"... Compared to what? COM? MFC? VB6? Man, .NET blows all those away as far as purity goes: .NET is so consistent across all its APIs -- whether that be web services, web apps, client apps, distributed apps, Windows services -- the "pure", consistent, virgin feeling of .NET is what initially drew me to it. I was sick of all the bizarre twists and turns of Win32, MFC, and COM: different threading models, programming styles, memory managements, naming conventions, and API designs. When coming from all that, .NET was a total breath of fresh air to and really puts the former frameworks/APIs to shame in my mind. It is really a unification of many different application programming concepts, so that you can keep your code consistent, rather than having to deal with multiple frameworks with different programming styles. I think one of the reasons for this is the FxCop software that gets run on the framework, checking for design inconsistencies, propery naming conventions, and so on. It really gives .NET a streamlined, consistent feel that is far more "pure" than Microsoft's previous application framework attempts. Just my humble opinion. :)

                    Tech, life, family, faith: Give me a visit. I'm currently blogging about: Homosexuality in Christianity Judah Himango

                    S Offline
                    S Offline
                    stephen hazel
                    wrote on last edited by
                    #17

                    ...purity... Judah Himango wrote: Compared to what? COM? MFC? VB6? Compared to C++/Win32, of course :) In terms of less code and close to the roots of the OS for the kinds of apps I like to write - small utility apps with some GUI, but not tons. Once .net isn't just another layer, i might change my mind. But since NT, I haven't really seen any layers rewritten or removed - just glommed on... Well, I -have- seen improvement. All I'm sayin' is before MS takes away win32, they better give me a good low level API to the OS. Well, I -hope- they will... Pray?

                    J 1 Reply Last reply
                    0
                    • N Nitron

                      I just can't seem to get motivated to learn it. Every time I get a small project that I think would be good to learn C#, I get frustrated because I don't even know how to read/write files and figure I could just do it faster in C++ anyway. Does anyone else have this problem? What book would you recommend to get into it? I've gone through the articles here, but I think I need more. I dunno, I got used to doing everything the MFC way, now it's like I'm stuck. It's still hard not to have a seperate .h and .cpp :~ ~Nitron.


                      ññòòïðïðB A
                      start

                      M Offline
                      M Offline
                      Marc Clifton
                      wrote on last edited by
                      #18

                      Nitron wrote: I get frustrated because I don't even know how to read/write files and figure I could just do it faster in C++ anyway. I had the exact same problem. You just have to push yourself through it. And besides, you're supposed to use XML for file I/O. ;P Nitron wrote: What book would you recommend to get into it? I wouldn't recommend a book. It's more a question of forcing yourself to do it. After reading a book, you'll still be stuck in "doing it". But, I must say, after having been "doing it" for a couple years now (geez, has it been that long???), I absolutely love C#. There's a few nits, of course. And keep in mind, C# is a language. .NET is a framework. There are many evils in the .NET framework, but there are also many joys. Frankly, I found a lot more joys with .NET than I ever did with MFC. Marc My website
                      Latest Articles: Object Comparer String Helpers

                      1 Reply Last reply
                      0
                      • E eggie5

                        Are you serious, because I laughed. If you are I feel bad... /\ |_ E X E GG

                        S Offline
                        S Offline
                        stephen hazel
                        wrote on last edited by
                        #19

                        ;)

                        1 Reply Last reply
                        0
                        • M Michael P Butler

                          Inside C# by Tom Archer was the book that hooked me into C#. I suffered from the same kind of problems you seem to be having. C# and .NET requires a slightly different way of thinking. It was actually MyXaml[^] that really got me into C#. It helped me realise the true power and flexiblity of the .NET framework. I was an MFC programmer for going on 10 years, it was hard to change but I've found it to be very worthwhile. Michael CP Blog [^] Development Blog [^]

                          G Offline
                          G Offline
                          Giles
                          wrote on last edited by
                          #20

                          Me too. I got hooked on exactly the same book. Though I waited for the second edition. Nice one Tom.


                          "Je pense, donc je mange." - Rene Descartes 1689 - Just before his mother put his tea on the table. Shameless Plug - Distributed Database Transactions in .NET using COM+

                          M 1 Reply Last reply
                          0
                          • G Giles

                            Me too. I got hooked on exactly the same book. Though I waited for the second edition. Nice one Tom.


                            "Je pense, donc je mange." - Rene Descartes 1689 - Just before his mother put his tea on the table. Shameless Plug - Distributed Database Transactions in .NET using COM+

                            M Offline
                            M Offline
                            Michael P Butler
                            wrote on last edited by
                            #21

                            Giles wrote: Me too. I got hooked on exactly the same book. Though I waited for the second edition. Nice one Tom. The book was so good, I bought both the first and second edition :-D Michael CP Blog [^] Development Blog [^]

                            G 1 Reply Last reply
                            0
                            • M Michael P Butler

                              Giles wrote: Me too. I got hooked on exactly the same book. Though I waited for the second edition. Nice one Tom. The book was so good, I bought both the first and second edition :-D Michael CP Blog [^] Development Blog [^]

                              G Offline
                              G Offline
                              Giles
                              wrote on last edited by
                              #22

                              I sneaked a peep in a book shop at the first edition, but knew there was already a second edition on the way, so I waited. I swaer to God, I had it as bed time reading for a week. I would have finished it quicker, but my wife would make me turn the light off. I love the twist at the end with the murder. :-D Good book, and recommened to any C++ programme like me who needed some convincing. Can't wait for the generics and anonymous functions. I'm not one for beta's though. I hate reinstalling machines.

                              M 1 Reply Last reply
                              0
                              • N Nitron

                                I just can't seem to get motivated to learn it. Every time I get a small project that I think would be good to learn C#, I get frustrated because I don't even know how to read/write files and figure I could just do it faster in C++ anyway. Does anyone else have this problem? What book would you recommend to get into it? I've gone through the articles here, but I think I need more. I dunno, I got used to doing everything the MFC way, now it's like I'm stuck. It's still hard not to have a seperate .h and .cpp :~ ~Nitron.


                                ññòòïðïðB A
                                start

                                P Offline
                                P Offline
                                PJ Arends
                                wrote on last edited by
                                #23

                                The total extent of my C# programming is modifing the code in this[^] article so it saves the settings to disk. I just really like C++ and MFC so I have no desire to learn C#. Supposedly the .NET framework is supposed to be easier to access from C++/MFC as of VC2005, so I will wait until it comes out to see what the big deal of the framework is.


                                "You're obviously a superstar." - Christian Graus about me - 12 Feb '03 "Obviously ???  You're definitely a superstar!!!" - mYkel - 21 Jun '04 "There's not enough blatant self-congratulatory backslapping in the world today..." - HumblePie - 21 Jun '05 Within you lies the power for good - Use it!

                                1 Reply Last reply
                                0
                                • S stephen hazel

                                  ...purity... Judah Himango wrote: Compared to what? COM? MFC? VB6? Compared to C++/Win32, of course :) In terms of less code and close to the roots of the OS for the kinds of apps I like to write - small utility apps with some GUI, but not tons. Once .net isn't just another layer, i might change my mind. But since NT, I haven't really seen any layers rewritten or removed - just glommed on... Well, I -have- seen improvement. All I'm sayin' is before MS takes away win32, they better give me a good low level API to the OS. Well, I -hope- they will... Pray?

                                  J Offline
                                  J Offline
                                  Judah Gabriel Himango
                                  wrote on last edited by
                                  #24

                                  Ok, that's an argument I've heard before. But why do you need to have an API close to the OS? Doesn't that tie you to a particular OS and make it more likely that you'll royally corrupt OS dealings, e.g. the memory of other processes? And how "low" is low, kernel calls? Or calls into a library which relies on the kernel? I always find it interesting that certain hardliners :-) have this need to be low-level. Reminds me of the "C++ is too slow & too abstracted! I'm going back to C/Asm!" bunk that was prevalent for sometime in the 90s. Oh well. As far as .NET being "another layer", that's partially true; it really depends on what you're doing. .NET Windows Forms (System.Windows.Forms) apps are a layer on Win32...but other APIs like System.Xml, or a vast number of web APIs relied on by ASP.NET are managed. This article[^] has some good info regarding WinFX, the "all-managed" principle API of Windows Longhorn. Like Win32, WinFX will have the ability to make system calls directly, bypassing the Win32 middleman. In actuality, new services specific to Longhorn will be available only through WinFX, at least initially, so I've heard.

                                  Tech, life, family, faith: Give me a visit. I'm currently blogging about: Homosexuality in Christianity Judah Himango

                                  S J 2 Replies Last reply
                                  0
                                  • G Giles

                                    I sneaked a peep in a book shop at the first edition, but knew there was already a second edition on the way, so I waited. I swaer to God, I had it as bed time reading for a week. I would have finished it quicker, but my wife would make me turn the light off. I love the twist at the end with the murder. :-D Good book, and recommened to any C++ programme like me who needed some convincing. Can't wait for the generics and anonymous functions. I'm not one for beta's though. I hate reinstalling machines.

                                    M Offline
                                    M Offline
                                    Michael P Butler
                                    wrote on last edited by
                                    #25

                                    Giles wrote: Good book, and recommened to any C++ programme like me who needed some convincing. Can't wait for the generics and anonymous functions. I'm not one for beta's though. I hate reinstalling machines. It was certainly the book that opened the door for me to move from MFC/C++ to C#. It wasn't until Marc's original MyXaml articles that I went through that door. I've recently installed the VS2005 beta and all the new features certainly impress me. Michael CP Blog [^] Development Blog [^]

                                    1 Reply Last reply
                                    0
                                    • J Judah Gabriel Himango

                                      Ok, that's an argument I've heard before. But why do you need to have an API close to the OS? Doesn't that tie you to a particular OS and make it more likely that you'll royally corrupt OS dealings, e.g. the memory of other processes? And how "low" is low, kernel calls? Or calls into a library which relies on the kernel? I always find it interesting that certain hardliners :-) have this need to be low-level. Reminds me of the "C++ is too slow & too abstracted! I'm going back to C/Asm!" bunk that was prevalent for sometime in the 90s. Oh well. As far as .NET being "another layer", that's partially true; it really depends on what you're doing. .NET Windows Forms (System.Windows.Forms) apps are a layer on Win32...but other APIs like System.Xml, or a vast number of web APIs relied on by ASP.NET are managed. This article[^] has some good info regarding WinFX, the "all-managed" principle API of Windows Longhorn. Like Win32, WinFX will have the ability to make system calls directly, bypassing the Win32 middleman. In actuality, new services specific to Longhorn will be available only through WinFX, at least initially, so I've heard.

                                      Tech, life, family, faith: Give me a visit. I'm currently blogging about: Homosexuality in Christianity Judah Himango

                                      S Offline
                                      S Offline
                                      stephen hazel
                                      wrote on last edited by
                                      #26

                                      Oh come on... You really don't have that small voice in your head telling you "return to your commodore 64 and 6502 assembly"...? That's only meeee??? Sure, it's much easier to blast out another crappy old web app. But when I wrote my first text editor for my c64 in 3K of 6502 asm, I got a heck of a lot better "buzz"...:cool: I'm not gonna go try to buy a c64 off ebay or anything, but there will always be a small part of me that neeeeds to feel the LEDs somewhere near. And I'm not gonna justify it :) ...Steve

                                      1 Reply Last reply
                                      0
                                      • N Nitron

                                        I just can't seem to get motivated to learn it. Every time I get a small project that I think would be good to learn C#, I get frustrated because I don't even know how to read/write files and figure I could just do it faster in C++ anyway. Does anyone else have this problem? What book would you recommend to get into it? I've gone through the articles here, but I think I need more. I dunno, I got used to doing everything the MFC way, now it's like I'm stuck. It's still hard not to have a seperate .h and .cpp :~ ~Nitron.


                                        ññòòïðïðB A
                                        start

                                        C Offline
                                        C Offline
                                        Christian Graus
                                        wrote on last edited by
                                        #27

                                        Inside C# Second Edition by Tom Archer, MVP. Christian Graus - Microsoft MVP - C++

                                        1 Reply Last reply
                                        0
                                        • J Judah Gabriel Himango

                                          Ok, that's an argument I've heard before. But why do you need to have an API close to the OS? Doesn't that tie you to a particular OS and make it more likely that you'll royally corrupt OS dealings, e.g. the memory of other processes? And how "low" is low, kernel calls? Or calls into a library which relies on the kernel? I always find it interesting that certain hardliners :-) have this need to be low-level. Reminds me of the "C++ is too slow & too abstracted! I'm going back to C/Asm!" bunk that was prevalent for sometime in the 90s. Oh well. As far as .NET being "another layer", that's partially true; it really depends on what you're doing. .NET Windows Forms (System.Windows.Forms) apps are a layer on Win32...but other APIs like System.Xml, or a vast number of web APIs relied on by ASP.NET are managed. This article[^] has some good info regarding WinFX, the "all-managed" principle API of Windows Longhorn. Like Win32, WinFX will have the ability to make system calls directly, bypassing the Win32 middleman. In actuality, new services specific to Longhorn will be available only through WinFX, at least initially, so I've heard.

                                          Tech, life, family, faith: Give me a visit. I'm currently blogging about: Homosexuality in Christianity Judah Himango

                                          J Offline
                                          J Offline
                                          JWood
                                          wrote on last edited by
                                          #28

                                          Why because we already have a interpreted idiot VM type system it is called VB and that is completely in a different space reserved for the remedial-reading class of programmers. If they can't make it just a layer above the OS then it is not suitable as a proper fundamental programming language - it is a chicken attempt to control bugs by creating a mammoth system of checks that a basic language like C/C++ is supposed to be.

                                          J 1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups