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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Pages / PowerApps Portal: erro...
Power Pages
Unanswered

PowerApps Portal: error message when submitting a form on the portal page

(0) ShareShare
ReportReport
Posted on by

Hello Community,

 

On my custom PowerApps portal, I have a web page with an entity form on it, where users can basically fill in data and submit the form. When the form is submitted, behind the scene it will create a Lead entity record in the Dynamics 365 instance that's connected to the portal.

 

I am experiencing a very odd error message on the submission page. When clicking on the Submit button to submit the entity form on the web page, the following error message pops up. This is very puzzling because I am only getting this error when login to the portal as certain users, but the same submission process works fine if I login to the portal as some other different users.

 

I already checked entity permissions and all that, and everything seems fine. I am really lost as to what might be causing this error message.

 

Does anyone have any clues? Thank you!

 

 

Categories:
I have the same question (0)
  • v-xida-msft Profile Picture
    on at

    Hi @Anonymous ,

    Have these certain users been assigned with proper Web Role in your custom Portal?

    Have you assigned proper Entity Permission (related to your Lead Entity) to the Web Role (which is assigned to these certain users )?

     

    Based on the issue that you mentioned, I have made a test on my side, and don't have the issue that you mentioned. Firstly, please make sure you have created a Entity Permission with proper privileges for your Leads Entity in your Portal as below:

    1.JPG

     

    And then create a proper Web Role in your Portal or use the existing web role, then assign the above Entity Permission to this Web Role as below:

    2.JPG

     

    After that, assign above Web Role to these specific contacts (created for these certain users) in your Portal.

    3.JPG

     

    Then go to your Portal Designer, then click "Sync Configuration"-> "Browse Website" button to make the changes you made in your Portal take effect.

     

     

    More details about assigning Entity Permission in Portal, please check the following article:

    https://docs.microsoft.com/en-us/powerapps/maker/portals/configure/assign-entity-permissions

     

    Regards,

  • Community Power Platform Member Profile Picture
    on at

    Hello,

     

    I have confirmed that I have the right web role and entity permissions in place, but I am still getting the same error. Below is the details of the error. Does anyone know what this means? What could be the problem?

     Server Error in '/' Application.


    Invalid postback or callback argument.  Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page.  For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them.  If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.ArgumentException: Invalid postback or callback argument.  Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page.  For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them.  If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


    Stack Trace:

    [ArgumentException: Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.]
     System.Web.UI.ClientScriptManager.ValidateEvent(String uniqueId, String argument) +11822878
     System.Web.UI.Control.ValidateEvent(String uniqueID, String eventArgument) +143
     System.Web.UI.WebControls.DropDownList.LoadPostData(String postDataKey, NameValueCollection postCollection) +86
     System.Web.UI.Page.ProcessPostData(NameValueCollection postData, Boolean fBeforeLoad) +558
     System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +4231
  • Community Power Platform Member Profile Picture
    on at

    I did some further research into the above error I am getting, and I came across the following blog discussions that seem to be explaining the problem I am having. In my scenario, I have one lookup field on the lead entity form on the portal page, which I then converted into drop-down and apply some filter on this drop-down using JS.

     

    https://community.dynamics.com/crm/f/microsoft-dynamics-crm-forum/298329/use-the-clientscriptmanager-registerforeventvalidation-method-in-order-to-register-the-postback-or-callback-data-for-validation

     

    According to the last post in the article, it says the dropdown list will only show the first 5000 records. So if I have more than 5000 records in the entity I am looking up, and the value I select is not in the first 5000, I will get the above error message...and the user who posted this mentioned this is currently a limitation on the portal.

     

    Does anyone know if there is a way around this? And how does the system determine the first 5000 records, is it based on the name field of the entity for sorting the first 5000 records?

     

    Any insights would be appreciated!

  • v-xida-msft Profile Picture
    on at

    Hi @Anonymous ,

    Regarding the issue that you mentioned, I think this issue may be related to the 'Validation Event' in your current web page of your Portal.

     

    Please consider go to your Portal Management, then find the specific Web Link Set your current web page related to:

    5.JPG

    then switch to "Links" option, then find the specific Web Link corresponded to your current web page (where the issue is), then select it and click "Edit" option:

    6.JPG

    within the opening Web Link, locate at the "Link Options" section, then check the "Disable Page Validation" option as below:

    7.JPG

    then click "save" button. After that, go to your Portal Designer, click "Sync Configuration"-> "Browse website" button to make the changes take effect, then check if the issue is solved.

     

    Also please check if the following article would help in your scenario:

    https://community.dynamics.com/crm/f/microsoft-dynamics-crm-forum/298329/use-the-clientscriptmanager-registerforeventvalidation-method-in-order-to-register-the-postback-or-callback-data-for-validation

     

    Regards,

  • Verified answer
    oliver.rodrigues Profile Picture
    9,368 Most Valuable Professional on at

    take a look at this video: https://www.youtube.com/watch?v=F8QxoyOIzAc

     

    it might help you indicating where the error is

     

     

    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • Community Power Platform Member Profile Picture
    on at

    Hi @v-xida-msft ,

     

    I followed exactly what you suggested to disable the page validation. Unfortunately, the same problem persists...

  • v-xida-msft Profile Picture
    on at

    Hi @Anonymous ,

    Have you tried the @OliverRodrigues 's video resource? I think it would be helpful in your scenario.

     

    Currently, I could not reproduce your issue on my side. Have you referred to the response from the Schjoermann in the thread I provided above? I guess this issue may be related to limitation of lookup fields rendered as dropdowns in the portal.

    Spoiler (Highlight to read)
    "

    I came to the conclusion that this is a limitation of lookup fields rendered as dropdowns in the portal.

    The dropdown list will only show the first 5000 records.

    So if you have 7500 records in the entity you are looking up, and you filter the list to only show 7. If the one you then select from the 7, is not part of the first 5000 in the original list you will get the above error.

    I created a case for Microsoft on this issue, and they say that this is by design.

    "
    " I came to the conclusion that this is a limitation of lookup fields rendered as dropdowns in the portal. The dropdown list will only show the first 5000 records. So if you have 7500 records in the entity you are looking up, and you filter the list to only show 7. If the one you then select from the 7, is not part of the first 5000 in the original list you will get the above error. I created a case for Microsoft on this issue, and they say that this is by design. "

    On your side, please check if you have configured a LookUp field rendered as Dropdown within a Entity form on your current Web page, and the LookUp field have more than 5000 records.

     

    If the issue still exists, please consider submit an assisted support ticket for further help through the following link:

    https://powerapps.microsoft.com/en-us/support/pro

     

    Regards,

  • Community Power Platform Member Profile Picture
    on at

    Hi @v-xida-msft ,

     

    Yes, the issue I am having is related to limitation of lookup fields rendered as dropdowns in the portal, as we have more than 5000 records in the lookup. 

     

    We are looking into other workaround options.

     

    Thanks again for the insights and information, much appreciated!

  • Verified answer
    v-xida-msft Profile Picture
    on at

    Hi @Anonymous ,

    Actually, it is an known limit with the LookUp field in PowerApps Portal, I afraid that there is no direct solution to achieve your needs in PowerApps Portal.

     

    If you would like to get further help in this issue, please consider submit an assisted support ticket through the following link:

    https://powerapps.microsoft.com/en-us/support/pro

     

    If the solution I provided above is helpful in your scenario, please also consider go ahead to click "Accept as Solution" to identify my reply as helpful.

     

    Regards,

  • OOlashyn Profile Picture
    3,496 Most Valuable Professional on at

    Hi @Anonymous ,

     

    Do you need to show all available options or you can prefilter them? Usually, I create views that I use on a Portal only with prefiltered data. You can setup which view will be used to show the data on the lookup. Open your form, select lookup field and then change what view will be used by changing Default View. 

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Pages

#1
Jerry-IN Profile Picture

Jerry-IN 71

#2
Fubar Profile Picture

Fubar 62 Super User 2025 Season 2

#3
sannavajjala87 Profile Picture

sannavajjala87 31

Last 30 days Overall leaderboard