Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

macro delete alert list

Hi,

I want to delete all my alerts in the document using a macro. Any ideas? I know how to get the alert list (getAlertList array), but then there is no SetAlertList or removeAll items in the AlertsList or something like this. Thanks!

Labels (1)
2 Replies
Not applicable
Author

Hi,

The following code will remove all Alerts in a document.

Sub DeleteAlerts

set docprop = ActiveDocument.GetProperties
set alertList = docprop.Alerts
For i = 0 to alertList.Count - 1
alertList.RemoveAt(0)
Next
ActiveDocument.SetProperties docprop

End Sub

I hope this helps.

Thanks

Nick



Not applicable
Author

Thanks a lot Nick! it works perfectly.

Cheers