‎2006 Aug 29 6:38 AM
Hi Friends!
Is it possible to open an external application using a DLL file? If yes, how can i achieve it?
The exact requirement is to open the drawing from the transaction cv02n by clicking on the document no. The drawing will be stored in the wrench file format. The DLL to open the file is only available at the presentation server and the Wrench application will not be installed .
The sample code to open using DLL from VB is given here.
Sample VB code:
Dim objView As Object
Private Sub Command1_Click()
On Error GoTo ERR_HANDLER
Set objView = CreateObject("WrenchDocViewer.DocViewer")
If objView.initialise(Trim(Text1.Text), Trim(Text2.Text), Trim(Text3.Text)) = 1 Then
If objView.ViewDocuments(Trim(Text4.Text)) = 0 Then Exit Sub
End If
Exit Sub
ERR_HANDLER:
If Err.Number <> 0 Then
MsgBox Err.Description, vbCritical
Err.Clear
End If
End Sub
Thanks and Regards,
M.Arumugam
‎2006 Aug 29 7:19 AM
hi,
look at class (with se24) CL_GUI_FRONTEND_SERVICES
e.g. method: EXECUTE
A.
‎2006 Aug 29 7:19 AM
hi,
look at class (with se24) CL_GUI_FRONTEND_SERVICES
e.g. method: EXECUTE
A.
‎2006 Aug 29 7:37 AM
Hi!
This method can execute only exe files. Please correct me if i am wrong.
I already tried this.
Thanks,
M.Arumugam
‎2006 Aug 29 7:46 AM
Welcome to SDN
for this you need to register the dll in all frontend machines using regserve32.exe and then create a abap class to instantiate the dll and use its methods.
check the following weblog where Thomas shows how to use windows media player control and same logic can be used for your case.
/people/thomas.jung3/blog/2005/05/11/using-classic-activex-controls-in-the-abap-control-framework
Regards
Raja