PDF Redaction Custom Activity

Updated 2/1/2021

I’m excited to announce a new custom activity to redact PDF Documents without the use of any third party software. The activity locates and irreversibly redacts confidential text to produce a fully redacted PDF document.

Watch a YouTube video of it in action: Custom Activity for PDF Redaction built for UiPath Studio - YouTube

Effective use cases are in GDPR compliance and adherence to data privacy laws.

Here’s are some example workflows illustrating the use of the activity

Documentation: …PDF Redactor Activity.pdf (1.2 MB) for Version 2.0 and below

PDF Redactor Activity.pdf (1008.9 KB) for version > 2.0.21

EXAMPLE CODE
X-PDF Redaction - Example.zip (3.6 MB)

12 Likes

This is a great activity. The sample XAML file works a treat and privides a really cool user interface. Nice job @lawes

1 Like

Hi the component link is not available, it display Requested resource does not exist.

Hi.
the project says its missing an Activity.
I am using this version: UiPathTeam.PDFRedaction.Activities.1.0.0.nupkg

Any help?

Hi Aaron…

I’ve corrected the link in the original post. The component link was changed.

1 Like

Hi Benngo

You’ll need to download the component link. You’ll find it in the original post above

Have tried out this activity and it looks awesome lawes.

Looks like the regex patterns for ssn, email etc are defined in the back ground, would be good to have the power to customize formula variable to add in new custom defined regex formulae and reference it using a name (eg: tfn, abn etc)

1 Like

Or just a thought to maybe make the “formula” variable a String instead of String, to allow more than one regex patterns.

1 Like

Thanks for the feedback. In the interim, we can use the pipe symbol | between regex patterns. That would essentially do the same thing… Do you agree?

Makes sense… Will try this out

Hi Berard!

Your PDF Redaction Activity is great! Thanks for your work!

I habe some issues running your Activity on the corporate workstation. Our Security Policy doesn’t allow to create a folder on the "C:"
Your Activity tries to create a temp-Folder and it fails. grafik

Could you Specify your TempFolder using environment variable %temp%?
I think it’s a good idea.

The second issue if i try to specify the Output-File by giving a String Value into Properties. I’m getting this Error

Cann you fix this?
Thank you!

1 Like

Hi Aleks,

I’m very sorry that I did not respond sooner… I fixed this problem almost immediately after seeing your post, and updated the redaction activity. Can you try again, and let me know if this works for you?

Best
Bernard

I really like your idea to make the formula variable a String Array. I will make this change in the upcoming release


What did I wrong?
Please help me…
Error message:
RemoteException wrapping System.ArgumentException: No compiled code to run
error BC30451: 'regex’이(가) 선언되지 않았습니다. 해당 보호 수준으로 인해 액세스할 수 없습니다. At line 49

at UiPath.Activities.System.Utilities.InvokeCode.CompilerRunner.Compile(String code, Int32 errLineOffset, Boolean generateInMemory)
at UiPath.Activities.System.Utilities.InvokeCode.CompilerRunner…ctor(String code, String className, String methodName, Int32 errLineOffset, Boolean generateInMemory)
at UiPath.Activities.System.Utilities.InvokeCode.VBCodeInvoker.GetCompilerRunner(String code, String className, String methodName, Int32 errLineOffset, Boolean inMemory)
at UiPath.Activities.System.Utilities.InvokeCode.NetCodeInvoker.GetCompilerRunner(String userCode, List1 args, String imps, Boolean inMemory) at UiPath.Activities.System.Utilities.InvokeCode.NetCodeInvoker.Run(String userCode, List1 inArgs, IEnumerable`1 imps, Object args)
at UiPath.Core.Activities.InvokeCode.Execute(CodeActivityContext context)
at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager)
at System.Activities.ActivityInstance.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)
at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)

Hi @Bokyeong_Ko - I’m wondering if there are any dependencies missing?

Would you mind also trying these two things:

  • Can you provide a screenshot of your projects tab

  • Set the OCREngine to “uipath” lowercase

  • Enter a variable into FileOut parameter… Define it something like “C:\Output\redacted.pdf”

Thank you for reaching out.


Here is the screenshot of your projects tab.
The same error occured… :cry:

oops mistake , Here is the screenshot of “my” projects tab.

Hi Bokyeong,

Would you mind upgrading your UiPath.System.Activities to 20.4.0 or greater ?

still getting the same error message…

Is it because I’m a community edition user? Do I have to be a Pro user to use this activity?