Calling VB executable from MFC
-
Hi, Im having one VB executable file named as VSCModule.exe I want to use this in MFC to use the functions in that executable. Previously ,it has used in VB Macros. Just they add referennces , Tool->References and select VSCModule.exe. VBA coding :
Dim vsc As New VSCmodule.vsc
vsc.getVar("PL", "PVC101", "PV").Value 'getVar is function belongs to VSCModuleJust i want to know.Can i use this exe in MFC? If it is so How can i use that? Im using VS2008 version. I add reference in VC++ in the same way, its get added in References Column as
Interop.VSCModule.1.1
I dont know how to proceed after this? Pls kindly help me.
Anu
-
Hi, Im having one VB executable file named as VSCModule.exe I want to use this in MFC to use the functions in that executable. Previously ,it has used in VB Macros. Just they add referennces , Tool->References and select VSCModule.exe. VBA coding :
Dim vsc As New VSCmodule.vsc
vsc.getVar("PL", "PVC101", "PV").Value 'getVar is function belongs to VSCModuleJust i want to know.Can i use this exe in MFC? If it is so How can i use that? Im using VS2008 version. I add reference in VC++ in the same way, its get added in References Column as
Interop.VSCModule.1.1
I dont know how to proceed after this? Pls kindly help me.
Anu
You can execute any EXE from MFC using the
CreateProcess
API.«_Superman_» _I love work. It gives me something to do between weekends.
-
Hi, Im having one VB executable file named as VSCModule.exe I want to use this in MFC to use the functions in that executable. Previously ,it has used in VB Macros. Just they add referennces , Tool->References and select VSCModule.exe. VBA coding :
Dim vsc As New VSCmodule.vsc
vsc.getVar("PL", "PVC101", "PV").Value 'getVar is function belongs to VSCModuleJust i want to know.Can i use this exe in MFC? If it is so How can i use that? Im using VS2008 version. I add reference in VC++ in the same way, its get added in References Column as
Interop.VSCModule.1.1
I dont know how to proceed after this? Pls kindly help me.
Anu
Anu_Bala wrote:
Can i use this exe in MFC
If I understand you correctly, you want to know if you can call functions inside the VB exe from your MFC program. No you cannot do that. If those fucntions were in a DLL you could but not an exe. You can run the exe and get a result from the VB exe if that will suit your purpose.
Why is common sense not common? Never argue with an idiot. They will drag you down to their level where they are an expert. Sometimes it takes a lot of work to be lazy Individuality is fine, as long as we do it together - F. Burns