Welcome to Vortx Community Forum, where you can ask questions and receive answers from the staff at Vortx and other members of the community.

If you had a user account on our previous forums website, you will need to register a new account here.

Learn more about...


Adding a button to order.aspx in Admin

I am adding a new button to order whichs links to an order editing form for handling short shipments. When I add the button in order.aspx ...

 <asp:Button ID="btnEditOrderItems" CssClass="btn btn-primary" Text="Edit Order Items" runat="server" OnClick="btnEditOrderItems_click" />

along with the click event in order.aspx.cs ...

        public void btnEditOrderItems_Click(object sender, EventArgs e)
            // get order # from call parameter
            // redirect to kboOrderUpdate.aspx?ordernumber=xxxxxx
            // try to save return url for edit close button
            StringBuilder script = new StringBuilder();
            script.Append(String.Format("../KboOrderUpdate.aspx?ordernumber={0}&customerid={1}", OrderNumber, CurrentOrder.CustomerID));

I get the compiler error ...

ASP.kbomanager_order_aspx' does not contain a definition for 'btnEditOrderItems_click' and no extension method 'btnEditOrderItems_click' accepting a first argument of type 'ASP.kbomanager_order_aspx' could be found (are you missing a using directive or an assembly reference?)	

Is there some other place that  I need to add a reference? All the orther buttons on the order.aspx page are implemented identically. I'm at a loss.



closed with the note: I got the answer. It was my inabiltiy to control the shift key properly.
asked Jan 13, 2016 in MultiStore by AbbottF (370 points)
closed Jan 13, 2016 by AbbottF

1 Answer

0 votes
Looks like a casing issue.  btnEditOrderItems_click != btnEditOrderItems_Click
answered Jan 13, 2016 by Vortx ScottS (13,500 points)
Thanks. I really thought I copy - pasted the evet name between the aspx & aspx.cs.

Have a great day.