Skip to main content
Known Participant
December 28, 2009
Question

How to trace close event of a document & stop that functionality..

  • December 28, 2009
  • 1 reply
  • 524 views

Hi,

    Im new to Indesign SDK.  I need to open a document and do some changes in that.  When i closing that document i have to capture that event and just have to give one alert message which i did (Ex. close) and have to stop  that functionality(Close). 

     I can trace the event through Signal Manager of ServiceID  but dont know How to stop that close function?  When entering this cases

          case kBeforeCloseDocSignalResponderService:
        {
            DocWchUtils::DwAlert(doc, kBeforeCloseDocSignalStringKey);
            break;
        }
        case kAfterCloseDocSignalResponderService:
        {
            DocWchUtils::DwAlert(doc, kAfterCloseDocSignalStringKey);
            break;
        }

     Its gives alert and also file closed.  How can i stop that file closing?

     Pls someone help me?

This topic has been closed for replies.

1 reply

Inspiring
December 29, 2009

For stop the functionality you have to use the command interceptor (ICommandInterceptor) and handled the kCloseDocCmdBoss, you  can sear the sample for command interceptor.

you cannot stop the functionality by using document responder.