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 8 of 8

Thread: Adding Another field in the create account page

  1. #1
    peter3827 is offline Senior Member
    Join Date
    Nov 2005
    Posts
    281

    Default Adding Another field in the create account page

    I want to Add a "How did you hear about us?" field to the create account page. Does anyone know how this could be done. Thanks.

  2. #2
    omaxuk is offline Member
    Join Date
    Apr 2009
    Location
    We're Brits
    Posts
    73

    Default

    Don't actually know the answer, but our devs repurposed the Billing Suite and delivery suite (shipping if you speak American) fields, 'cos we reckoned they wern't needed anyway. see omax.org, (don't ask!)

    Used these fiels for "if you're out, where do we leave it' etc & we added a "How you hear about us" field too, so it can be done.
    Last edited by omaxuk; 01-21-2010 at 04:43 PM. Reason: Added more info

  3. #3
    mbertulli is offline Senior Member
    Join Date
    Aug 2008
    Posts
    243

    Default

    You are going to want to start with the createaccount.aspx + createaccount.aspx.cs. If you don't have source, then you can't change the existing add customer functions, but it's pretty easy to add in your own SQL updates after the standard inserts are done. Look around line 621, for the CreateAccount() private method.
    Matthew Bertulli
    Demac Media
    mbertulli@demacmedia.com
    Custom Web Design & E-Commerce Development
    AspDotNetStoreFront Platinum DevNet Partner
    ----

    Custom Skinning & Design
    Web Services Integration
    Custom Reporting
    Salesforce.com eCommerce AspDotNetStoreFront Integration

  4. #4
    Web Design Magic is offline Junior Member
    Join Date
    Aug 2008
    Posts
    12

    Default Another Way

    Another way I did it was simple do the following;

    in the aspx page add a new textbox.
    Then add the results to the NOTES property of the AddAccount() function.

    Does this make sense?

  5. #5
    Upscale_Automotive is offline Senior Member
    Join Date
    Apr 2008
    Posts
    201

    Default

    Quote Originally Posted by Web Design Magic View Post
    Another way I did it was simple do the following;

    in the aspx page add a new textbox.
    Then add the results to the NOTES property of the AddAccount() function.

    Does this make sense?
    Can you expand on your method for this? I assume the result is that the customer "notes" section displays the text that was entered during account creation.

  6. #6
    Upscale_Automotive is offline Senior Member
    Join Date
    Apr 2008
    Posts
    201

    Default

    Specifically, how do you post the results to the Notes section of the customer's record?

  7. #7
    Web Design Magic is offline Junior Member
    Join Date
    Aug 2008
    Posts
    12

    Default Solution

    OK. Lets assume your adding a field called "Business Type"

    1. You add a Text Box to the aspx page and call it id="txtBusinessType"
    2. Then in the createacount.aspx.cs page (around line 690 ish) you will see

    Code:
    /*Notes*/ null,
    Change that to reference your new text box..

    Code:
    /*Notes*/ "Business Type:" + txtBusinessType.Text,
    So now whenever your store saves a new account instead of saving a null (empty) value in the notes it is saving the text from your new text box.

    You can then add validation controls if required etc..

    Hope this helps.

  8. #8
    Upscale_Automotive is offline Senior Member
    Join Date
    Apr 2008
    Posts
    201

    Default

    Thank you for expanding on this, it is very helpful!