Important Notice from AspDotNetStorefront
It is with dismay that we report that we have been forced, through the action of hackers, to shut off write-access to this forum. We are keen to leave the wealth of material available to you for research. We have opened a new forum from which our community of users can seek help, support and advice from us and from each other. To post a new question to our community, please visit: http://forums.vortx.com
Results 1 to 2 of 2

Thread: Accessing Customer ExtensionData

  1. #1
    tigreye007 is offline Junior Member
    Join Date
    Nov 2008
    Posts
    27

    Default Accessing Customer ExtensionData

    We need to store additional customer data, and it seems the best way to do this would be to utilize the ExtensionData field, and place the additional data in a nice xml format.

    So to start, we have added a couple of text boxes to the CreateAccount.aspx and Account.aspx web forms. In CreateAccount.aspx.cs, we have modified the call to ThisCustomer.UpdateCustomer with our ExtensionData that we pulled together from the new text boxes. This is working just fine.

    The problem is that we're unable to find a nice way to pull the ExtensionData down to display the data in Account.aspx (so the user can edit their data). You would think there would be an ExtensionData property on the Customer object, but there is not. What would be the best way to access the ExtensionData property for the currently logged-in customer?

  2. #2
    Dusty is offline Member
    Join Date
    Jun 2009
    Posts
    176

    Default

    You've one of two ways you could accomplish this.

    You could create and additional field on the Customer object to pull the information from the extension data field, or alternatively you could change the customer page to pull the extension data from the database. The former is probably your better option as the information would be retrieved when the customer is loaded, and that you can parse the data from the field in the object rather than on the page.

    Dusty
    ASPDotNetStorefront Staff