3 Replies Latest reply: Jul 25, 2012 12:04 AM by MOMIR ZECEVIC RSS

    Any way to add custom data to a channel?

    Daniel Jiang Community Member

      Hi,

       

      I need to save some customized data to a spot channel, but didn't find out how to do it.

       

      I created the spot channel by 'sPSActionControl->Play(&result, eventMake, descNewSpotChannel, plugInDialogSilent)', and I've tried to put string into the descriptor by key 'keyCustomForced' or 'keyCustom', but none of the keys worked.

       

      Any suggestion will be greatly appreciated.

       

      Thanks a lot!

      Daniel

        • 1. Re: Any way to add custom data to a channel?
          MOMIR ZECEVIC Community Member

          First thin that came to my mind, you can add property to document that describe what you want for example documant may have custom property "Channel Black - Modified by user "

           

          After a little thought... have you tried to create descriptor, put string in it using keyText, and the put that descriptor using  PutObject() and  keyCustom?

           

          Does this helps?

          Getter seems

          • 2. Re: Any way to add custom data to a channel?
            Daniel Jiang Community Member

            Hi Momir,

             

            Thanks for your reply. I cannot add property to document, because I need to associate customized data with each channel, which user can add/delete/move channel, and can create channel by script/undo/redo, which listener cannot get notified.

             

            For PutObject, what would be the descriptor class ID  for key 'keyCustom' ?

             

             

            Thanks a lot!

            • 3. Re: Any way to add custom data to a channel?
              MOMIR ZECEVIC Community Member

              Hi,

               

              If just notification is a problem try workaround this way.

              Make scriptable plugin to which you will pass from your plugin data that you want to save with channel.

              Than you save this data in document in a manner that suites you. Now, "listner will be notified"  about so to say subplugin call and will catch all parameters that you have passed to subplugin.

               

              I know that it is not elegant, farr from it but in case that you hit the wall it may be worth trying.

               

              Regards,

              Momir