On PaymentPage.ascx I have:
Code: Select all
<asp:Literal ID="FormattedShippingAddress" runat="server" EnableViewState="false"></asp:Literal>
Code: Select all
User user = Token.Instance.User;
Address shippingAddress = null;
foreach (Address tempAddress in user.Addresses) if (tempAddress.Nickname == "Shipping") shippingAddress = tempAddress;
if (shippingAddress != null)
{
FormattedShippingAddress.Text = shippingAddress.ToString(true);
}
error CS0103: The name 'FormattedShippingAddress' does not exist in the current context
I have tried to declare 'FormattedShippingAddress' in other locations on the PaymentPage.ascx.cs but have had no luck.
Please help.
Thanks!