Ticket T546541
Visible to All Users
Duplicate

[Web] ObjectPermission DetailView throws FormatException from Guid

created 8 years ago (modified 8 years ago)

Hello,

I am experiencing an issue when accessing an ObjectPermission in XAF via the Web interface. I have tested this in a new project, this also shows the behavior, which leads me to believe this is an issue in XAF or one of the web controls. I have not found anything referencing this issue in the change logs, leading me to believe it may also be present in the newer XAF versions.

The exception thrown is a FormatException, claiming a GUID is incorrectly formatted. I can't find any information on which field it is referencing. The issue can be reproduced in a new XAF project with the Security System module used. The simplest way is to access the Role 'Default', then opening the permission for the 'User' class in a nested view, and then opening the single ObjectPermission. This will throw the exception.

Here is the stack trace for the exception:

Code
Url: http://localhost:2064/Default.aspx?Dialog=true&WindowID=59359732 Url referrer: http://localhost:2064/Default.aspx?Dialog=true&WindowID=59359732 SessionID: pdscsp2t0xncrcjuq2xykh5t Request type: POST User agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/60.0.3112.90 Safari/537.36 User IP: ::1 User: Admin Authenticated user: [no name] ================================================================================ The error occurred: Type: FormatException Message: Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx). Data: 0 entries Stack trace: at System.Guid.TryParseGuidWithDashes(String guidString, GuidResult& result) at System.Guid.TryParseGuid(String g, GuidStyles flags, GuidResult& result) at System.Guid..ctor(String g) at System.ComponentModel.GuidConverter.ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, Object value) at DevExpress.ExpressApp.Web.Editors.ASPx.ASPxGridViewContextMenu.SelectObject(String objectId) at DevExpress.ExpressApp.Web.Editors.ASPx.ASPxGridViewContextMenu.ProcessCommand(String args) at DevExpress.ExpressApp.Web.Editors.ASPx.ASPxGridViewContextMenu.DevExpress.ExpressApp.Web.Templates.IXafCallbackHandler. ProcessAction(String parameter) at DevExpress.ExpressApp.Web.Templates.XafCallbackManager.ProcessAction(String parameter) at DevExpress.ExpressApp.Web.Templates.XafCallbackManager.callbackControl_Callback(Object source, CallbackEventArgs e) at DevExpress.Web.ASPxCallback.OnCallback(CallbackEventArgs e) at DevExpress.Web.ASPxCallback.RaiseCallbackEvent(String eventArgument) at DevExpress.Web.ASPxWebControl.System.Web.UI.ICallbackEventHandler.RaiseCallbackEvent(String eventArgument) InnerException is null

The loaded assemblies are simply the default XAF assemblies as I have used a completely new project to reproduce this.

Answers approved by DevExpress Support

created 8 years ago

Hello Rik,

You have likely encountered the following issue: ASPxGridListEditor - FormatException is thrown when selecting an object in a lookup ListView shown from an aggregated collection. Please install the newest version of our components to get the bug fix.

    Comments (1)

      Ah, that could likely be it, yes. We'll look into updating then and see if that solves the issue.

      Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

      Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.