This COM thing is real cool!
-
Nish [BusterBoy] wrote: Or is he still in those final pre-guru stages which take the longest period of time in the Guru attainment procedure? LOL :) I think I'm a guru of simple apartment-threaded COM. I know zilch about remoting COM calls or DCOM or any of that proxy/stub stuff (just never had to use it, and for shell extensions all you need is apartment-threaded objects ;)). --Mike-- "COM didn't solve the old version of DLL hell - it just provided us with a new and improved version of hell." -- John Simmons, 1/22/2002 My really out-of-date homepage Sonork - 100.10414 AcidHelm Big fan of Alyson Hannigan.
-
Yipppeee! I wrote my first COM thingie :-) Of course it's only the example in the book. But despite the fact that I knew what to expect I was still thrilled, so thrilled I can't control my excitement. I mean I wrote the DLL, registered it. Then I used it from VB. Cool eh? Then I used it from ASP. Cooler eh? I haven't figured out how to use it from C++ though :-( But damnit, I mean this is so cool. I mean why did MS bother with .NET when they already had this COM thing? I mean, what's the bloody purpose! I am the newbiest COM newbie in this planet currently. But even I can see that it is so damn cool! Yippeee again...... How many COMites are here? Is Mike Dunn the only COMite Guru we have? Or is he still in those final pre-guru stages which take the longest period of time in the Guru attainment procedure? Coli, are you hearing this buddy? I am a COMite now. Halley's COMite :-) Regards COM newbie Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
Nish [BusterBoy] wrote: I mean why did MS bother with .NET when they already had this COM thing? I mean, what's the bloody purpose! COM rules, does it not ? I've not done enough after my initial forays, due to my trying to do stuff that is of use to my work. I wish I could, maybe soon I will :-) Running it from C++ is pretty easy. I've never run one from VB, for obvious reasons :-) Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
-
I am still too vague about all those things to even get scared :-) Ignorance makes me brave :-) Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
Connection points are WAY cool ( they let your COM object call the method that called it, like a callback ). I use it in my database program to report back on the files I am parsing. It was hell to get working though. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
-
Nish [BusterBoy] wrote: My grammar sucks like Lotus Notes, Just out of curiosity, what makes you think Lotus Notes sucks... Cheers Kannan
Kannan Kalyanaraman wrote: Just out of curiosity, what makes you think Lotus Notes sucks... Simple observation. There are entire websites devoted to how bad the UI is, and it's just an unpleasant experience from start to finish. No product has any excuse for requiring training for a group of programmers to learn how to use it to read email. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
-
Connection points are WAY cool ( they let your COM object call the method that called it, like a callback ). I use it in my database program to report back on the files I am parsing. It was hell to get working though. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
Thanks for the info CG :-) ****Christian Graus wrote: It was hell to get working though That's where the fun is I guess :-) Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
-
Yipppeee! I wrote my first COM thingie :-) Of course it's only the example in the book. But despite the fact that I knew what to expect I was still thrilled, so thrilled I can't control my excitement. I mean I wrote the DLL, registered it. Then I used it from VB. Cool eh? Then I used it from ASP. Cooler eh? I haven't figured out how to use it from C++ though :-( But damnit, I mean this is so cool. I mean why did MS bother with .NET when they already had this COM thing? I mean, what's the bloody purpose! I am the newbiest COM newbie in this planet currently. But even I can see that it is so damn cool! Yippeee again...... How many COMites are here? Is Mike Dunn the only COMite Guru we have? Or is he still in those final pre-guru stages which take the longest period of time in the Guru attainment procedure? Coli, are you hearing this buddy? I am a COMite now. Halley's COMite :-) Regards COM newbie Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
COM is wonderful. I've been writing COM objects for about four years now. Nish [BusterBoy] wrote: I mean why did MS bother with .NET when they already had this COM thing? I mean, what's the bloody purpose! .NET is based upon COM, without COM then .NET wouldn't exist. Welcome to the COM club. I recommend you read Essential COM by Don Box and Effective COM also by Don Box and if you can find a video of Don Box's COM dance. Michael :-)
-
Thanks for the info CG :-) ****Christian Graus wrote: It was hell to get working though That's where the fun is I guess :-) Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
Nish [BusterBoy] wrote: Christian Graus wrote: It was hell to get working though That's where the fun is I guess Of course - if it was easy, failed plumbers would do it for $3 an hour. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
-
Kannan Kalyanaraman wrote: Just out of curiosity, what makes you think Lotus Notes sucks... Simple observation. There are entire websites devoted to how bad the UI is, and it's just an unpleasant experience from start to finish. No product has any excuse for requiring training for a group of programmers to learn how to use it to read email. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
I definately agree. It's the weapon of choice for e-mail at my local college, and we all had a lot of fun laughing at it. - Jason SonorkID: 100.12194 :bob:'s your uncle
-
COM is wonderful. I've been writing COM objects for about four years now. Nish [BusterBoy] wrote: I mean why did MS bother with .NET when they already had this COM thing? I mean, what's the bloody purpose! .NET is based upon COM, without COM then .NET wouldn't exist. Welcome to the COM club. I recommend you read Essential COM by Don Box and Effective COM also by Don Box and if you can find a video of Don Box's COM dance. Michael :-)
Michael P Butler wrote: .NET is based upon COM, without COM then .NET wouldn't exist Can you elaborate more on that statement? Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
-
Nish [BusterBoy] wrote: Christian Graus wrote: It was hell to get working though That's where the fun is I guess Of course - if it was easy, failed plumbers would do it for $3 an hour. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
****Christian Graus wrote: Of course - if it was easy, failed plumbers would do it for $3 an hour In Indian money that'd be a pretty decent amount of money :-) Rs 138/hr :-) Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
-
kfc wrote: a .NET guru? Joking right? :-) Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
-
No, I am not joking. Considering the number of C# articles under your name, who else on this site is more qualified for the guru title? ;)
:-( I can feel the strong pungent scents of heavy sarcasm blowing hard into my face :-( Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
-
****Christian Graus wrote: Of course - if it was easy, failed plumbers would do it for $3 an hour In Indian money that'd be a pretty decent amount of money :-) Rs 138/hr :-) Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
Nish [BusterBoy] wrote: In Indian money that'd be a pretty decent amount of money Really ? I presume you mean US$ ( AU$5.50 an hour ), but even then - I make a bit over AU$20 an hour and I make half what I'd expect to make if I moved to the mainland, at a minimum. No wonder people keep posting for Indian programmers. I know if I needed any work done, I'd pay you US$3 an hour in a second, then lie awake at night feeling guilty that it was so, so little. I don't think anyone beyond street mimes and paper boys get $3 an hour, it's just my standard response, as in when I get poor service from McDonalds or the local supermarket I will call the manager and say 'I know it's hard getting decent staff when you pay $3 an hour, but...', or if my daughter doesn't get her toy with her happy meal, I tell her it's because the people who work there are monkeys who work for $3 an hour. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
-
:-( I can feel the strong pungent scents of heavy sarcasm blowing hard into my face :-( Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
Nish [BusterBoy] wrote: I can feel the strong pungent scents of heavy sarcasm blowing hard into my face I learned something this week, Nish. I went for a job interview, and after a couple of C++ questions, which I answered as expansively as I could, the guy said 'well the rest of my questions are going to sound pretty lame then'. He asked a few, but they quickly decided I knew enough not to bother asking any more. What did I learn ? I'd always assumed I was a bit below anyone who had a degree in my knowledge, in fact my main reason in going for the job was just to see if I could make any sort of impression at all. It seems to me if you're working hard to learn something, you may find that you know more than you think. Don't get me wrong, if Michael Dunn, for example, went for this job, I would not have a chance in hell, but I seem to be doing better than I thought. You are too - when I finally learn C#, I intend to read your articles, and to hope you answer my questions, the way I always hoped to see Michael answer my COM ones. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
-
:-( I can feel the strong pungent scents of heavy sarcasm blowing hard into my face :-( Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
Nish wrote: "I can feel the strong pungent scents of heavy sarcasm blowing hard into my face" Sorry, Nish. I wasn't trying to make fun of you. I know too little about .NET and C#, the number of articles is my only measure to judge the guruness of another person. :) :) :) The fact that you have evolved into a COM newbie says that you have a very bright future ahead of you. :) :) :)
-
Michael P Butler wrote: .NET is based upon COM, without COM then .NET wouldn't exist Can you elaborate more on that statement? Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
I'll leave it to the experts to elaborate, they can probably explain it better than I can http://msdn.microsoft.com/msdnmag/issues/1200/com/com1200.asp Michael :-)
-
Yipppeee! I wrote my first COM thingie :-) Of course it's only the example in the book. But despite the fact that I knew what to expect I was still thrilled, so thrilled I can't control my excitement. I mean I wrote the DLL, registered it. Then I used it from VB. Cool eh? Then I used it from ASP. Cooler eh? I haven't figured out how to use it from C++ though :-( But damnit, I mean this is so cool. I mean why did MS bother with .NET when they already had this COM thing? I mean, what's the bloody purpose! I am the newbiest COM newbie in this planet currently. But even I can see that it is so damn cool! Yippeee again...... How many COMites are here? Is Mike Dunn the only COMite Guru we have? Or is he still in those final pre-guru stages which take the longest period of time in the Guru attainment procedure? Coli, are you hearing this buddy? I am a COMite now. Halley's COMite :-) Regards COM newbie Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
EEeewww. COM Sucks. That's not a childish put-down; it's a succinct technical assessment.
-
EEeewww. COM Sucks. That's not a childish put-down; it's a succinct technical assessment.
Any particular area? As somebody who loves the COM programming lifestyle I'd be interested to know why you think it sucks. Michael :-)
-
Yipppeee! I wrote my first COM thingie :-) Of course it's only the example in the book. But despite the fact that I knew what to expect I was still thrilled, so thrilled I can't control my excitement. I mean I wrote the DLL, registered it. Then I used it from VB. Cool eh? Then I used it from ASP. Cooler eh? I haven't figured out how to use it from C++ though :-( But damnit, I mean this is so cool. I mean why did MS bother with .NET when they already had this COM thing? I mean, what's the bloody purpose! I am the newbiest COM newbie in this planet currently. But even I can see that it is so damn cool! Yippeee again...... How many COMites are here? Is Mike Dunn the only COMite Guru we have? Or is he still in those final pre-guru stages which take the longest period of time in the Guru attainment procedure? Coli, are you hearing this buddy? I am a COMite now. Halley's COMite :-) Regards COM newbie Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut
Here's some lessons for ya: 1) If your COM object is a STA (Single Threaded Apartment) and you put threads in that apartment, ALWAYS include a message pump. You can add a message pump very easily by adding CWindowImpl to your derivations and adding the message pump. Then, while waiting on your threads to complete their task, process window messages in a loop. Otherwise, you'll freeze. 2) I find that though it's often very tedious and is a nightmare for C++ use of your object, you should usually opt for IDispatch as your interface. IUnknown is much easier and much nicer with types, but limits you heavily (no VB or ASP). 3) If you have a multithreaded STA that uses other STA's, ALWAYS ALWAYS ALWAYS marshal your interfaces. In something like a simple dialog application (MFC) passing around your STA object (smart pointer) by pointer is fine in the same thread. However, don't do this in multithreaded applications. It will work sometimes.... but will often screw you up in hard to find/debug ways. Marshalling is always the way to go and it won't hurt you to use it if you don't need it. 4) If your COM object is written in ATL and IDispatch derived, be prepared to use BSTR and VARIANT's. VB and Scripting simply can't deal with anything else appropriately and you'll frequently find hard to debug problems if you get it working without it. Best of luck! ;)
-
Nish [BusterBoy] wrote: In Indian money that'd be a pretty decent amount of money Really ? I presume you mean US$ ( AU$5.50 an hour ), but even then - I make a bit over AU$20 an hour and I make half what I'd expect to make if I moved to the mainland, at a minimum. No wonder people keep posting for Indian programmers. I know if I needed any work done, I'd pay you US$3 an hour in a second, then lie awake at night feeling guilty that it was so, so little. I don't think anyone beyond street mimes and paper boys get $3 an hour, it's just my standard response, as in when I get poor service from McDonalds or the local supermarket I will call the manager and say 'I know it's hard getting decent staff when you pay $3 an hour, but...', or if my daughter doesn't get her toy with her happy meal, I tell her it's because the people who work there are monkeys who work for $3 an hour. Christian I have come to clean zee pooollll. - Michael Martin Dec 30, 2001 Picture the daffodil. And while you do that, I'll be over here going through your stuff. Picture a world without war, without hate. And I can picture us attacking that world, because they would never expect it.
Sonork ID 100.10002:MeanManOz
I live in Bob's HungOut now
The average Indian software engineer makes between Rs 15,000 to 25,000 per month which is cosidered pretty good here. Lets assume he works 25 days a month averaging 8 hrs a day. That gives us 200 hrs. Thus for 15,000 he makes Rs 75 /hr which is US$ 1.60 and the 25000 guy makes Rs 125 an hr which is USD 2.65 If you offer someone $3 per hr for 200 hrs a month he'd jump for it :-) Nish Sonork ID 100.9786 voidmain www.busterboy.org If you don't find me on CP, I'll be at Bob's HungOut