Author | Topic: dsoframer | |
---|---|---|
Altiy Zemlytskiy | dsoframer on Wed, 20 Feb 2013 14:01:46 +0200 <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> </head> <body text="#000000" bgcolor="#FFFFFF"> <font face="Courier New, Courier, monospace">Hi all,<br> <br> I use dsoframer.ocx to integrate MS Excel Sheets to my application. <br> <br> I created CLASS SpDSOFramer FROM XbpActiveXControl<br> and wanted to redefine COMEventDispatcher method. At least I did it, and everything is working<br> <br> METHOD SpExcelIntoUniversal:COMEventDispatcher( nDISPID, mp1, mp2, mp3, mp4, mp5, mp6, mp7, mp8, mp9, mp10 )<br> LOCAL i, j, oSheets, nCount<br> IF nDISPID = 4<br> ::document := ::ActiveDocument:Application:dynamicCast( ActiveXObject() )<br> IF .NOT.EMPTY(::sheetProperty)<br> oSheets := ::document:sheets<br> nCount := oSheets:count<br> ::itemCollection := {}<br> FOR i=1 TO nCount<br> IF (j:=ASCAN(::sheetProperty,{|a|UPPER(a[1])==UPPER(ALLTRIM(oSheets:Item(i):Name))}))<>0<br> AADD(::itemCollection, oSheets:Item(i):dynamicCast( ActiveXObject()))<br> ATAIL(::itemCollection):&(::sheetProperty[j][2]) := ::sheetProperty[j][3]<br> ENDIF<br> NEXT<br> oSheets:destroy()<br> ENDIF<br> ENDIF<br> RETURN ::XbpActiveXControl:COMEventDispatcher( nDISPID, @mp1, @mp2, @mp3, @mp4, @mp5, @mp6, @mp7, @mp8, @mp9, @mp10 )<br> <br> But I've set </font><font face="Courier New, Courier, monospace"><b><font face="Courier New, Courier, monospace">nDISPID = 4</font></b><b> </b>empirically<b>. </b>Do somebody know where can I found dsoframer events description? Googled many times, but found nothing. <br> Many thanks in advance<b><br> </b><b> </b><br> <br> </font> <div class="moz-signature">-- <br> Best regards, Altiy</div> </body> </html> | |
Jose Antonio Diego Kereje | Re: dsoframer on Wed, 20 Feb 2013 13:48:17 +0100 Altiy, Events: Event OnFileCommand(ByVal Item As ocFileCommandType, Cancel As Boolean) Description: Called when File menu item is selected by user (may be canceled). ID: 1 Event OnDocumentOpened(ByVal File As String, ByVal Document As Object) Description: Called when document is opened or new document added. ID: 2 Event OnDocumentClosed() Description: Called when document is closed. ID: 3 Event OnActivationChange(ByVal fGoingActive As Boolean) Description: Called when component gains/loses activation. ID: 4 Event BeforeDocumentClosed(ByVal Document As Object, Cancel As Boolean) Description: Called before document is closed (may be canceled). ID: 5 Event BeforeDocumentSaved(ByVal Document As Object, ByVal Location As String, Cancel As Boolean) Description: Called before document is saved (may be canceled). ID: 6 Event OnPrintPreviewExit() Description: Called when print preview is closed. ID: 7 Event OnSaveCompleted(ByVal Document As Object, ByVal DocName As String, ByVal FullFileLocation As String) Description: Called when save is successful. ID: 8 Regards. Diego | |
Altiy Zemlytskiy | Re: dsoframer on Wed, 20 Feb 2013 15:02:13 +0200 Many thanks, Diego. > Altiy, > > Events: > > Event OnFileCommand(ByVal Item As ocFileCommandType, Cancel As Boolean) > Description: Called when File menu item is selected by user (may be > canceled). > ID: 1 > > Event OnDocumentOpened(ByVal File As String, ByVal Document As Object) > Description: Called when document is opened or new document added. > ID: 2 > > Event OnDocumentClosed() > Description: Called when document is closed. > ID: 3 > > Event OnActivationChange(ByVal fGoingActive As Boolean) > Description: Called when component gains/loses activation. > ID: 4 > > Event BeforeDocumentClosed(ByVal Document As Object, Cancel As Boolean) > Description: Called before document is closed (may be canceled). > ID: 5 > > Event BeforeDocumentSaved(ByVal Document As Object, ByVal Location As > String, Cancel As Boolean) > Description: Called before document is saved (may be canceled). > ID: 6 > > Event OnPrintPreviewExit() > Description: Called when print preview is closed. > ID: 7 > > Event OnSaveCompleted(ByVal Document As Object, ByVal DocName As > String, ByVal FullFileLocation As String) > Description: Called when save is successful. ID: 8 > > Regards. Diego Best regards, Altiy | |
Altiy Zemlytskiy | Re: dsoframer on Wed, 06 Mar 2013 10:13:44 +0200 Hi All, It is endless . Everything works great, but I can't open another Excel sheet independently in usual Execel application window, clicking by mouse, if "my" Excel sheet is opened by DSOframer. Do somebody know where can I take DSOframer documentation? http://support.microsoft.com/kb/311765 does not exist anymore: Best regards, Altiy > Altiy, > > Events: > > Event OnFileCommand(ByVal Item As ocFileCommandType, Cancel As Boolean) > Description: Called when File menu item is selected by user (may be > canceled). > ID: 1 > > Event OnDocumentOpened(ByVal File As String, ByVal Document As Object) > Description: Called when document is opened or new document added. > ID: 2 > > Event OnDocumentClosed() > Description: Called when document is closed. > ID: 3 > > Event OnActivationChange(ByVal fGoingActive As Boolean) > Description: Called when component gains/loses activation. > ID: 4 > > Event BeforeDocumentClosed(ByVal Document As Object, Cancel As Boolean) > Description: Called before document is closed (may be canceled). > ID: 5 > > Event BeforeDocumentSaved(ByVal Document As Object, ByVal Location As > String, Cancel As Boolean) > Description: Called before document is saved (may be canceled). > ID: 6 > > Event OnPrintPreviewExit() > Description: Called when print preview is closed. > ID: 7 > > Event OnSaveCompleted(ByVal Document As Object, ByVal DocName As > String, ByVal FullFileLocation As String) > Description: Called when save is successful. ID: 8 > > Regards. Diego | |
Altiy Zemlytskiy | Re: dsoframer on Wed, 06 Mar 2013 10:35:38 +0200 found - http://www.cnblogs.com/liping13599168/archive/2009/09/17/1568187.html > Hi All, > > It is endless . Everything works great, but I can't open another > Excel sheet independently in usual Execel application window, clicking > by mouse, if "my" Excel sheet is opened by DSOframer. Do somebody know > where can I take DSOframer documentation? > http://support.microsoft.com/kb/311765 does not exist anymore: > > Best regards, Altiy |