I am currently trying to integrate the PDF control from the PDF Editor SDK into our application and unfortunately I have some problems
when calling the function ExecUICmd2 () (https://sdkhelp.pdf-xchange.com/vie ... ExecUICmd2)
Unfortunately, I always get an error message in my application when calling the function and I don't know why.
Parallel I have your demo application FullDemo written in C#. There the call works without problems.
Is there anything else that needs to be initialized that I miss?
Code: Select all
oleobject lo_cmd
STRING as_command
STRING ls_langCode
LONG ll_cmdId
pdfCtl.object.SetLicKey ( is_licKey ) // working
pdfCtl.object.VisibleCmdPanes = PXV_VisibleCmdPanes_None // working
// as_command = "cmd.open"
as_command = "cmd.view.goto.firstPage"
lo_cmd = CREATE oleobject
lo_cmd = io_uiInst.CmdManager.Cmds.Find(as_command) // Working
ll_cmdId = lo_cmd.ID // 3460 same as in the c# fulldemo application
ls_langCode = pdfCtl.object.Inst.GetCurrentUILang() // Working
// Test 1
pdfCtl.object.Inst.ExecUICmd2 ( ll_cmdId, lo_pOwner ) // "Error calling external object function execuicmd2"
// Test 2
pdfCtl.object.Inst.ExecUICmd2 ( ll_cmdId ) // "Error calling external object function execuicmd2"
// Test 3
pdfCtl.object.Inst.ExecUICmd2 ( 3460 ) // "Error calling external object function execuicmd2"
// Test 4
pdfCtl.object.Inst.ExecUICmd2 ( lo_cmd.ID ) // "Error calling external object function execuicmd2"
// Test 5 - unknown function to test error
pdfCtl.object.Inst.ExecUICmd12 ( lo_cmd.ID ) // "Name not found calling external object function execuicmd12"
Greetings
Alex