Skip to Content
avatar image
Former Member

Copy and clear Comments in one

Hello,

I want to do the Copy Comments and Clear Comments in one Package . User wants to have a button in the Excel to Copy comments(From Selection and To Selection) and then it should also clear the FROM Selection. I tried creating a custom package and copied both the standard COPY and CLEAR DM scripts . This will not work because I am locking the record and it won't do both the task at the same time.

Any suggestions?.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

8 Answers

  • Mar 07 at 06:05 PM

    "I tried creating a custom package and copied both the standard COPY and CLEAR DM scripts" - please explain what you have done!

    What do you mean by "custom package"?

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 07 at 06:32 PM

    Thanks Vadim.

    I copied both the DM scripts of COPY and CLEAR comments and created a new custom Package with the script below :

    PROMPT(COPYMOVEINPUT,%SELECTION%,%TOSELECTION%,"Select the members to COPY and where to",%DIMS%) PROMPT(RADIOBUTTON,%CHECKLCK%,"Select whether to check work status settings when copy comments.",1,{"Yes, check work status settings when copy comments","No, do not check work status settings"},{"1","0"}) 'PROMPT(DELIMITER,%SELECTION%,) TASK(/CPMB/COPY_COMMENTS,SELECTION,%SELECTION%) TASK(/CPMB/COPY_COMMENTS,TOSELECTION,%TOSELECTION%) TASK(/CPMB/COPY_COMMENTS,CHECKLCK,%CHECKLCK%)

    PROMPT(RADIOBUTTON,%CHECKLCK%,"Select whether to check work status settings when deleting comments.",1,{"Yes, delete comments with work status settings","No, do not delete comments with work status settings"},{"1","0"}) TASK(/CPMB/CLEAR_COMMENTS,SELECTION,%SELECTION%) TASK(/CPMB/CLEAR_COMMENTS,ENABLETASK,%ENABLETASK%) TASK(/CPMB/CLEAR_COMMENTS,CHECKLCK,%CHECKLCK%)

    Thanks.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member
      
      PROMPT(COPYMOVEINPUT,%SELECTION%,%TOSELECTION%,"Select the members to COPY and where to",%DIMS%)
      PROMPT(RADIOBUTTON,%CHECKLCK%,"Select whether to check work status settings when copy comments.",1,{"Yes, check work status settings when copy comments","No, do not check work status settings"},{"1","0"})
      TASK(/CPMB/COPY_COMMENTS,SELECTION,%SELECTION%)
      TASK(/CPMB/COPY_COMMENTS,TOSELECTION,%TOSELECTION%)
      TASK(/CPMB/COPY_COMMENTS,CHECKLCK,%CHECKLCK%)
      
      PROMPT(RADIOBUTTON,%ENABLETASK%,"Do you want to clear comments associated with data regions?",1,{"Yes","No"},{"1","0"})
      PROMPT(RADIOBUTTON,%CHECKLCK%,"Select whether to check work status settings when deleting comments.",1,{"Yes, delete comments with work status settings","No, do not delete comments with work status settings"},{"1","0"})
      TASK(/CPMB/CLEAR_COMMENTS,SELECTION,%SELECTION%)
      TASK(/CPMB/CLEAR_COMMENTS,ENABLETASK,%ENABLETASK%)
      TASK(/CPMB/CLEAR_COMMENTS,CHECKLCK,%CHECKLCK%)
      
      
      
      
      
      
      
  • avatar image
    Former Member
    Mar 07 at 09:40 PM

    Chain for this is COPY Comments as I created the custom DM by copying the COPY Comments package . After that I added the Clear Comments Task . Let me know if I am able to explain what I am trying to do.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 07 at 11:05 PM

    One option I think is to copy the standard Process chain /CPMB/COPYCOMMENTS and create a custom chain . Then add the steps of Clear Comments Process chain(/CPMB/CLEARCOMMENTS) to the custom Chain . Let me know if there is any other better solution?.

    Add comment
    10|10000 characters needed characters exceeded

  • Mar 08 at 06:44 AM

    Try to create a custom chain.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 08 at 06:52 PM

    I am trying that Approach . One question regarding that how can I commit the Copy comments first and then run clear comments step in the PC. Because both cannot be triggered at the same time.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 08 at 09:59 PM

    When I run the Package attached to the Custom Process Chain . I get the error Below:

    Package Script:

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Mar 09 at 01:28 AM

    Thanks Vadim , it works now.

    Add comment
    10|10000 characters needed characters exceeded