web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Make a field mandatory on the product receiving page of the Enterprise Portal AX2012 R2

(0) ShareShare
ReportReport
Posted on by

Hello - I need to make a field mandatory on the unconfirmed products receipts page of the EP 2012. I'm not sure if this is as easy as going to the AOT and making the field mandatory in the web parts or it needs a developer code.  I have looked around in the AOT and couldn't find the appropriate object in "Web Files". I'd appreciate it if anyone can provide some guidance.

Thanks,

Farokh

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    André Arnaud de Calavon Profile Picture
    303,730 Super User 2026 Season 1 on at

    Hi Farokh,

    When the field must be set to mandatory for all legal entities on this table regardless it is from EP or the AX client, you can make the field mandatory in the AOT.

  • Suggested answer
    ArunGarg Profile Picture
    3,926 on at

    Hi Farokh,

    For field to be mandatory you can set the property on the following path :

    1.On Table field  you can make field mandatory.

    2.On Dataset of that user control you can make field mandatory.

    3.On UserWebControl you can make field mandatory.

    Regards

    Arun

  • Community Member Profile Picture
    on at

    Hi Andre, Thanks for the quick reply. I checked the table in the AOT and the field is actually set to be mandatory but for some reason it's not mandatory in the EP.

  • Community Member Profile Picture
    on at

    Hi Arun,

    Thanks for the quick reply. Where is the UserWebControl?

    Thanks,

    Farokh

  • Community Member Profile Picture
    on at

    I found the web control "EPPurchCORReceive" for the unconfirmed product receipts in the AOT and I just now need to figure out how to make the field mandatory by modifying the code.

    the part of the code that relates to the field that I need to make mandatory is:

       <dynamics:AxBoundField DataField="editReceiptId**" DataSet="dsEPPurchCORAction" DataSetView="PurchLine"  HeaderText="<%$ axlabel:@SYS342654%>"/>    

    Below is the complete code:

    <%@ Control Language="C#" AutoEventWireup="true" CodeFile="EPPurchCORReceive.ascx.cs" Inherits="EPPurchCORReceive" %>

    <%@ Register Assembly="Microsoft.Dynamics.Framework.Portal, Version=6.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"

    Namespace="Microsoft.Dynamics.Framework.Portal.UI.WebControls" TagPrefix="dynamics" %>

    <%@ Register Src="AxBaseUserControl.ascx" TagName="AxBaseUserControl" TagPrefix="Ax" %>

    <dynamics:AxDataSource ID="dsEPPurchCORReceive" runat="server" DataSetName="EPPurchCORReceive"/>

    <dynamics:AxForm ID="AxForm" runat="server" DataSourceID="dsEPPurchCORReceive" DataMember="PurchLine_Current"

    AutoGenerateEditButton="true" DefaultMode="Edit" >

    <table>

       <tr>

           <td>

               <asp:Label ID="lblInitialText" runat="server" Text="<%$ axlabel:@SYS332466%>"></asp:Label>

           </td>

       </tr>

       <tr style="height:5"><td></td></tr>

       <tr>

           <td>

                <asp:Label ID="lblText" runat="server" Text="<%$ axlabel:@SYS332467%>"></asp:Label>

           </td>

       </tr>

    </table>

       <dynamics:AxGroup ID="AxGroup" runat="server" Caption="<%$ axlabel:@SYS59970%>">

           <Fields>

               <dynamics:AxBoundField DataField="editRemainPurchPhysical**" DataSet="dsEPPurchCORAction" DataSetView="PurchLine"  HeaderText="<%$ axlabel:@SYS303371%>"/>            

        <dynamics:AxBoundField DataField="editReceiptId**" DataSet="dsEPPurchCORAction" DataSetView="PurchLine"  HeaderText="<%$ axlabel:@SYS342654%>"/>            

    <dynamics:AxCheckBoxBoundField DataField="editCloseLine**" DataSet="dsEPPurchCORAction" DataSetView="PurchLine" HeaderText="<%$ axlabel:@SYS303372%>"/>            

           </Fields>

       </dynamics:AxGroup>

       <dynamics:AxGroup ID="AssetGroup" runat="server" Caption="<%$ axlabel:@SYS25653%>" Visible="false">

           <Fields>

               <dynamics:AxBoundField DataField="editAssetName**" DataSet="dsEPPurchCORAction" DataSetView="PurchLine" HeaderText="<%$ axlabel:@SYS7399%>"  />            

               <dynamics:AxBoundField DataField="editMake**" DataSet="dsEPPurchCORAction" DataSetView="PurchLine" HeaderText="<%$ axlabel:@SYS67389%>"/>            

               <dynamics:AxBoundField DataField="editModel**" DataSet="dsEPPurchCORAction" DataSetView="PurchLine" HeaderText="<%$ axlabel:@SYS9923%>"  />            

               <dynamics:AxBoundField DataField="editSerialNumber**" DataSet="dsEPPurchCORAction" DataSetView="PurchLine" HeaderText="<%$ axlabel:@SYS477%>" />            

           </Fields>

       </dynamics:AxGroup>

    </dynamics:AxForm>

    I hope someone can help me make this change.

    Regards,

    Farokh

  • Verified answer
    Community Member Profile Picture
    on at

    I resolved this issue by adding Mandatory = True to the code. Thank you for your tips.

    Regards,

    Farokh

  • ArunGarg Profile Picture
    3,926 on at

    HI,

    Please verify if your issue get resolved.

    Regards

    Arun

  • Akbarpasha Profile Picture
    on at

    Hi,

    i have a same kind of issue, i need to set mandatory true for field "item GST group in purchase requestion form in EP". i tried at data set level, but its not working and also trying with control level from VS, but at the time of deploying it is throwing so many errors like proxy adding, i added EPApplication proxy and purchreq related proxy, but still its not deploying.

    can you please guide me on this.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Joris dG Profile Picture

Joris dG 5

#2
Andrew Jones a1x Profile Picture

Andrew Jones a1x 2

#3
GL-01081504-0 Profile Picture

GL-01081504-0 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans