Page 1 of 1

Order Number on receiptpage.ascx

Posted: Thu Aug 27, 2009 8:25 am
by mfreeze
I have the following 3 lines at the top of receiptpage.aspx replacing the View Order # text. Can somebody tell me how I replace the 'xx' in the third line with the order #? I have tried several things with no success.

<asp:Panel ID="PageHeaderPanel" runat="server" CssClass="receiptpageHeader">
<h1><asp:Localize ID="Caption" runat="server" Text="Thank you for your order."></asp:Localize></h1>
<h4><asp:Localize ID="Caption1" runat="server" Text="Please print this page for your records."></asp:Localize></h4>
<h4><asp:Localize ID="Caption2" runat="server" Text="Your order number is xx and it will ship pending credit card approval. ."></asp:Localize></h4>
</asp:Panel>

Re: Order Number on receiptpage.ascx

Posted: Thu Aug 27, 2009 12:57 pm
by AbleMods
Change this:
mfreeze wrote:<h4><asp:Localize ID="Caption2" runat="server" Text="Your order number is xx and it will ship pending credit card approval. ."></asp:Localize></h4>
to:

Code: Select all

<h4><asp:Localize ID="Caption2" runat="server" Text="Your order number is [color=#FF0000]{0} [/color]and it will ship pending credit card approval. ."></asp:Localize></h4>
Now edit the receiptpage.ascx.cs code file. Find line 55 which says:

Code: Select all

Caption.Text = String.Format(Caption.Text, _Order.OrderNumber);
and change it to:

Code: Select all

Caption2.Text = String.Format(Caption2.Text, _Order.OrderNumber);

Re: Order Number on receiptpage.ascx

Posted: Thu Aug 27, 2009 5:53 pm
by mfreeze
Thanks Joe. That worked flawlessly.

Re: Order Number on receiptpage.ascx

Posted: Thu Aug 27, 2009 9:15 pm
by AbleMods
Glad to help - I wish ALL my code worked that well ;)