Leo Jay wrote:

> dear all,
> i have a python com server like this:
> 
> import win32com.server.register
> 
> class HelloWorld:
>     _reg_clsid_         = "{B0EB5AAB-0465-4D54-9CF9-04ADF7F73E4E}"
>     _reg_desc_          = 'Python test com server'
>     _reg_progid_        = "Leojay.ComServer"
>     _public_methods_    = ['Add', 'Mul']
> 
>     def Add(self, a, b):
>         return a+b
>     def Mul(self, a, b):
>         return a*b
> 
> 
> if __name__ == '__main__':
>     win32com.server.register.UseCommandLine(HelloWorld)
> 
> 
> after registering the com server, i can use it in visual basic .net:
>         Dim a As Integer = 5
>         Dim b As Integer = 8
>         Dim h As Object = CreateObject("Leojay.ComServer")
>         MsgBox(h.Add(a, b).ToString() + " " + h.Mul(a, b).ToString())
> 
> but i don't know how to use it in visual c++.
> 
> who has any idea about using this com server in viusal c++?
> a detailed sample of early binding would be better, thanks.
> 
> 
> 

too complicated for my brain. Waiting for a good answer.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to