Hi,
How to add an action to a grid without modifying the aspx?
Thanks,
EV
Hi,
How to add an action to a grid without modifying the aspx?
Thanks,
EV
You can add the action using the screen editor and thus avoid touching the .aspx file directly.
What have you done so far?
Hi
There is not other way but to add a piece of aspx code to the page:
<px:PXGrid .....>
<ActionBar>
<CustomItems>
<px:PXToolBarButton Text="Grid Action" DependOnGrid="gridThings">
<AutoCallBack Target="ds" Command="GridAction">
<Behavior CommitChanges="True" ></Behavior>
</AutoCallBack>
</px:PXToolBarButton>
</CustomItems>
</ActionBar>
</px:PXGrid>
This assumes you have an PXAction defined like:
public PXAction<MYThings> GridAction;
>PXUIField(DisplayName = Messages.Thing, Enabled = true)]
>PXButton(CommitChanges = true)]
protected virtual IEnumerable gridAction(PXAdapter adapter)
{
return adapter.Get();
}
Hope this helps
Hi,
Ok thanks. What happens if someone need to add a new action to a page in another customization project?
Thanks,
EV
Hi
Normally Acumatica merge the code when publishing. When 2 or more customizations are touching same objects a warning / error message is thrown. You have to use Level attribute on the customization package to tell Acumatica which package has priority over another.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.