Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Morten Bock 1867 posts 2140 karma points MVP 2x admin c-trib
    Jul 15, 2011 @ 13:17
    Morten Bock
    0

    Creating speechbubble from the delete event with clienttools

    I'm creating a handler that will cancel the MoveToTrash in certain cases.

    When doing save/publish handlers we are able to use this line to send info to the user:

    BasePage.Current.ClientTools.ShowSpeechBubble(BasePage.speechBubbleIcon.error, "Error", "This is my message");

    But when trying that from the Document.BeforeMoveToTrash event, the BasePage.Current is null.

    Is there a way to display the speechbubble from the delete/movetotrash events?

  • Morten Bock 1867 posts 2140 karma points MVP 2x admin c-trib
    Jul 18, 2011 @ 15:46
    Morten Bock
    0

    So far, the solution I have come up with is to throw an exception. If the code throws an exception, then the UI will show an error speechbubble, with the exceptions message as the text.

Please Sign in or register to post replies

Write your reply to:

Draft