I'm trying to change the "Pay with Card" button (when the customer submits the order and credit card information) to a custom image.
I changed the button code (in CreditCardPaymentForm.ascx) to: <asp:ImageButton ID="CreditCardButton" runat="server" SkinID="SubmitOrderButton" ValidationGroup="CreditCard" Visible="true" OnClick="CreditCardButton_Click"></asp:ImageButton>
and added a line in style.skin: <asp:ImageButton runat="server" SkinId="SubmitOrderButton" ImageUrl="images/submitorder_button.gif" />
The result is this error:
[[ConLib:PaymentPage]] c:\inetpub\wwwroot\websitedirectory\Checkout\PaymentForms\CreditCardPaymentForm.ascx(292): error CS0122: 'System.Web.UI.WebControls.ImageButton.Text' is inaccessible due to its protection level.
The desired end result is to make the button an image. I've done this with other buttons. What do I need to do to make this happen?
Thanks
Credit Card Payment - Button (Error)
Re: Credit Card Payment - Button (Error)
As a work around, I used a CSS class with a background image to get the desired look.
- deverill
- Lieutenant (LT)
- Posts: 64
- Joined: Tue Jan 06, 2009 11:58 am
- Location: Key West, FL
- Contact:
Re: Credit Card Payment - Button (Error)
I'm pretty new to .NET web programming but as I understand it the ImageButton does not have a Text attribute and the line referred to in the error message is trying to set the original button text to "Pay With Card", at least in mine. Comment that line out and you should be fine with the imagebutton.
Jim Sewell - Web Programmer
Trusted Tours & Attractions
Trusted Tours & Attractions