Skip to content

Instantly share code, notes, and snippets.

@smarenich smarenich/WebDialog.cs

Last active Nov 27, 2015
Embed
What would you like to do?
//Defining action DataView
public PXAction<MyDAC> MyButton;
//Defining Button Attribute with tooltip
[PXButton(Tooltip = PX.Data.Update.Messages.MyTooltip)]
//Providing title and mapping action access rights
[PXUIField(DisplayName = "MyTitle", MapEnableRights = PXCacheRights.Delete, MapViewRights = PXCacheRights.Delete)]
protected void myButton()
{
WebDialogResult result = Companies.Ask(ActionsMessages.Warning, PXMessages.LocalizeFormatNoPrefix("My Message"),
MessageButtons.OKCancel, MessageIcon.Warning, true);
//checking answer
if (result != WebDialogResult.OK) return;
//Do usefull stuff.
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.