There are at least two problems wrong with my ActiveX EXE server project.
They both have to deal with the way I am passing in Objects (interface arguments) from clients.
I have attached the VC++ server project and the VB6 client (see the examples\vb6\ directory)
For example, this code will crash with a null pointer exception on the 4th or 5th loop:
Dim x As New DateTimeInfo
Dim y As New BarInfo
Private Sub Form_Load()
'This code will crash
For n = 1 To 5
[login to view URL] = 1
[login to view URL] = x
[login to view URL] = 1
Next n
End Sub
The source of the problem turns out to be AddRef... I was not using that in the [out].
But, since I need to hang on to pStartDateTime and pEndDateTime on the [in] side, I also need to AddRef there.
Now the problem is this: The application works, but does not exit because of the extra AddRef in the put_EndDateTime function.
So, I added a FinalRelease() in the CBarInfo class where I call pEndDateTime->Release(), but this doesn't seem to really release them - and the server still stays in memory.
Any ideas on how to release them? I don't think FinalRelease() is being called.
## Deliverables
1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.
2) Deliverables must be in ready-to-run condition, as follows (depending on the nature of the deliverables):
a) For web sites or other server-side deliverables intended to only ever exist in one place in the Buyer's environment--Deliverables must be installed by the Seller in ready-to-run condition in the Buyer's environment.
b) For all others including desktop software or software the buyer intends to distribute: A software installation package that will install the software in ready-to-run condition on the platform(s) specified in this bid request.
3) All deliverables will be considered "work made for hire" under U.S. Copyright law. Buyer will receive exclusive and complete copyrights to all work purchased. (No GPL, GNU, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site per the coder's Seller Legal Agreement).
## Platform
Win32