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

Thread: OKToEMail if skipreg=true

  1. #1
    BFG 9000 is offline Senior Member
    Join Date
    Oct 2006
    Location
    South UK
    Posts
    882

    Default OKToEMail if skipreg=true

    Greetings All,


    How would I enable the OK To Email radio buttons if the customer has chosen anonymous checkout - i.e. skipreg=true?


    TTFN

    BFG

  2. #2
    BFG 9000 is offline Senior Member
    Join Date
    Oct 2006
    Location
    South UK
    Posts
    882

    Default

    Anyone have any ideas?


    TTFN

    BFG

  3. #3
    ASPAlfred is offline Senior Member
    Join Date
    Nov 2007
    Posts
    2,244

    Default

    Open up your CreateAccount.aspx, locate the "SkipRegOver13" checkbox, at the bottom of it, add these lines.

    Code:
    <tr>
       <td align="right" valign="top" width="35%">
           <asp:Literal ID="Literal5" runat="server" Text="(!createaccount.aspx.26!)"></asp:Literal> &nbsp;
           <asp:Literal ID="Literal6" runat="server" Text="(!createaccount.aspx.27!)"></asp:Literal>
           <asp:RadioButton ID="OKToEmailYes2" runat="server" GroupName="OKToEMail" />&nbsp;&nbsp;&nbsp;&nbsp;                
           <asp:Literal ID="Literal7" runat="server" Text="(!createaccount.aspx.28!)"></asp:Literal>
           <asp:RadioButton ID="OKToEmailNo2" runat="server" GroupName="OKToEMail" />
       </td></tr>
    <br />
    <asp:Label ID="Label1" runat="server" Text="(!createaccount.aspx.29!)"></asp:Label>
    ...and go to your CreateAccount.aspx.cs file under CreateAccount() method, change this line:
    Code:
    /*OkToEmail*/ CommonLogic.IIF(OKToEMailYes.Checked, 1, 0))
    to
    Code:
    /*OkToEmail*/ CommonLogic.IIF(SkipRegistration,CommonLogic.IIF(OKToEmailYes2.Checked,1,0),CommonLogic.IIF(OKToEMailYes.Checked, 1, 0)),
    *You should make a backup first before changing anything.