IRC Networks
Irc Logs Stats
Start date: 2007-09-27 02:48:27
Last update: 2008-10-24 20:19:38
Channels: 41
Logged Lines: 6230436
Size: 1822.56 MB
Powered by
Channel Info
Network: freenodeChannel: #csharp |
Search in www.irclog.org
Log from #csharp at freenode 2006-06-01
[00:34]<lnvnzxu>just deriving your interfaces from IUnknown means that your interfaces share a root vtable contract with COM objects; however, without registration, activation, and a type library describing the component, it's a little hard to call it COM
[00:34]<mjzymygo>subanark: was this dll third party? or inhouse?
[00:34]<su2zgzzc>no and yes
[00:35]<lnvnzxu>plus, if you also never called CoInitialize to use it, technically you were never loading COM into the process
[00:35]<su2zgzzc>I have the source
[00:35]<mjzymygo>Are the developers still employed by your firm?
[00:35]<mjzymygo>subanark... so you can use pinvoke at least
[00:36]<mjzymygo>direct referencing to the DLL without it being a bona-fida ActiveX COM is pretty much impossible as fusion requires type info to work
[00:36]<su2zgzzc>well that would be kind of messy
[00:37]<mjzymygo>Are the DLL's developers still employed by your firm?
[00:37]<su2zgzzc>yes
[00:37]<mjzymygo>can't you get them to convert to an ATL implementation?
[00:38]<su2zgzzc>It uses atl
[00:38]<mjzymygo>not fully by the sounds of it.
[00:39]<lnvnzxu>did the dll export anything but those functions above? did the previous client application do a LoadLibrary then a GetProcAddress on DllGetClassObject?
[00:39]<su2zgzzc>I think it actually has its own COM implementation if its missing
[00:39]<su2zgzzc>nope just those 4 functions
[00:40]<mjzymygo>Subanark... if you have the source, is there an IDL file living in there
[00:40]<lnvnzxu>heh
[00:40]<lnvnzxu>i was just typing that
[00:40]<su2zgzzc>the previous client application uses CoCreateInstance I think
[00:40]<lnvnzxu>then it shouldn't do a LoadLibrary at all
[00:40]<mjzymygo>sorry to steal your thunder there peterhu ;)
[00:41]<lnvnzxu>and for that to work, it either needs to fully register itself with DllRegisterServer, or an isolated COM activation manifest needs to be used
[00:41]<mjzymygo>totally. sounds like something/someone has messed somethin gup
[00:41]<mjzymygo>Any IDL file?
[00:41]<su2zgzzc>Don't see any
[00:42]<lnvnzxu>where are the interfaces defined?
[00:42]<su2zgzzc>In the .hpp file
[00:42]<mjzymygo>hmm... sounds like you may need to fire-up VC++ and start a new ATL wizard (for clarity), and do a cut-and-shut and recreate the IDL...
[00:43]<su2zgzzc>e.g. MIDL_INTERFACE("907996ab-EB88-4806-AEB8-BF161C0D2DE2") ITraceStatsInfoSource : public IUnknown
[00:45]<mjzymygo>well that should work with an IDL coclass. but without an IDL it sounds like your object is a little disabled
[00:45]<su2zgzzc>hrm... ok I'll try building it myself
[00:45]<mjzymygo>http://msdn2.microsoft.com/en-us/library/ak5wyby1.aspx
[00:45]<mjzymygo>(I think... it's been a while since I used ATL...)
[00:46]<su2zgzzc>It wasn't built using VC though
[00:46]<mjzymygo>what was it built with?
[00:46]<lnvnzxu>all that's doing is decorating the type for the compiler with a IID so that you can use some extensions like uuidof()
[00:46]<su2zgzzc>some driver build tool
[00:46]<mjzymygo>do you have VC++?
[00:46]<su2zgzzc>sure I got all of them
[00:47]<lnvnzxu>a better question: if you can view the source of DllRegisterServer, does it do anything?
[00:47]<mjzymygo>there's always PInvoke...
[00:47]<lnvnzxu>hehe
[00:48]<mjzymygo>.NET was such a breath of fresh air...
[00:49]<lnvnzxu>indeed
[00:49]<mjzymygo>subanark... is the code anything you can port to .net Managed C++ or C++/CLI? or even c#?
[00:49]<su2zgzzc>the code is not really written yet
[00:50]<su2zgzzc>I just started, and the c++ wasn't going so well
[00:50]<mjzymygo>so you have the DLL source code... it's it's not written?
[00:50]<mjzymygo>ah
[00:50]<su2zgzzc>The dll code is huge
[00:50]<mjzymygo>whats in it?
[00:50]<su2zgzzc>its in c++ using atl
[00:50]<mjzymygo>ok... functionality
[00:51]<su2zgzzc>oh what does it do?
[00:51]<mjzymygo>yeh... =0)
[00:51]<su2zgzzc>well that part it does that I'm intrested, is to query a log file
[00:51]<kjr>smellyhippy: so... progress on the PoS
[00:51]<sdnffdxdlld>yeah?
[00:51]<kjr>smellyhippy: I'm going to wrap the servlet portions I want with a middleware bridge
[00:51]<su2zgzzc>things like get total time this process ran
[00:51]<kjr>smellyhippy: the client is going to be real thin
[00:52]<mjzymygo>so your accessing a FS based log file?
[00:52]<sdnffdxdlld>funky
[00:52]<su2zgzzc>FS?
[00:52]<kjr>smellyhippy: I can't think of a better way
[00:52]<kjr>filesystem
[00:52]<mjzymygo>FileSystem
[00:52]<su2zgzzc>well the data is binary
[00:52]<sdnffdxdlld>sounds like a good plan
[00:52]<mjzymygo>is it a file of your design?
[00:52]<kjr>smellyhippy: the other plan is to use their Swing app
[00:52]<su2zgzzc>I didn't have antying to do with the file format
[00:53]<sdnffdxdlld>why does it have to be using this?
[00:53]<su2zgzzc>Its good its binary though, as the logs can easily run over 100 megs
[00:53]<sdnffdxdlld>why cant you choose the technologies to fit thier needs?
[00:53]<kjr>smellyhippy: because it's an entire E-commerce solution
[00:53]<kjr>smellyhippy: I am choosing them
[00:53]<kjr>smellyhippy: the cashier app might be a Glade app
[00:53]<kjr>(wx widgets)
[00:53]<mjzymygo>how much time has been invested in the DLL code and how much time is left and how big a problem are you having with the 'not doing so well with c++'
[00:53]<mjzymygo>?
[00:55]<su2zgzzc>Time invested, a couple of days. Time left about a month or two. c++, I just had problems with simple stuff like string formatting, and working with the COM XML library
[00:56]<mjzymygo>if there is just a couple of days involved, then if I were you (and i'm not so it's your call) i'd use c#
[00:56]<su2zgzzc>well yes that was my plan
[00:56]<mjzymygo>and port the code over
[00:56]<su2zgzzc>my code? That is simple, most of the time spent was learning what functions to call.
[00:57]<su2zgzzc>Their code I ain't touching
[00:57]<mjzymygo>so do it =) then you won't have to worry about IDL's and stuff
[00:57]<kjr>smellyhippy: what do you think?
[00:57]<su2zgzzc>but back to the first questino of how do I interface with the psudo-COM
[00:57]<mjzymygo>sorry... I thought the 'ATL' dll was your work... I must have gotten confused
[00:58]<mjzymygo>Subanark... either rebuild it and add a proper IDL file, or use PInvoke.
[00:58]<sdnffdxdlld>I think personally I'd do it with MS technologies but thats because thats what I use ;) the implimentations sound good though :)
[00:59]<sdnffdxdlld>what level of stock control and stuff do yo have to do? any loyalty stuff?
[01:00]<sdnffdxdlld>matt, it wont be on windows
[01:00]<mjzymygo>;)
[01:00]<sdnffdxdlld>:P
[01:00]<sdnffdxdlld>javas much better behaved on non-windows stuff







