disable steps in checkout

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
15 năm cách đây
I have C# 2008 Express and VWD 2008.   I have tried to add these steps in the respective ASPX. the Web form ignores the changes and doesn't recompile.  Any suggestions If I can get this to work it would be great.
15 năm cách đây
I am also having dificulties on billing address, any cody snippit would make my day!
15 năm cách đây
I want to skip the billing address section and only use the shipping address. I program in ASP.NET and C# but i can't figure out how to do. Any ideas? Thanks
15 năm cách đây
Any sollution in disabling billing or/and shipping address?
15 năm cách đây
Hi there

I'v just tried to implement this approach to disable the shipping method during the checkout process by the following method.

1. Removed all but one shipping method in the site administration.

2. I opened CheckoutShippingMethod.ascx, and added the following lines in the !Page.IsPostBack event

if (!Page.IsPostBack)
            {
                if (shoppingCartRequiresShipping)
                {
                    //ShipmentPackage shipmentPackage = ShippingManager.CreateShipmentPackage(Cart, NopContext.Current.User.ShippingAddress);
                    string error = string.Empty;
                    ShippingOptionCollection shippingOptions = ShippingManager.GetShippingOptions(Cart, NopContext.Current.User, NopContext.Current.User.ShippingAddress, ref error);
                    if (!String.IsNullOrEmpty(error))
                    {
                        LogManager.InsertLog(LogTypeEnum.ShippingErrror, error, error);
                        lError.Text = Server.HtmlEncode(error);
                    }
                    else
                    {
                        if (shippingOptions.Count == 1)
                        {
                            NopContext.Current.User.LastShippingOption = shippingOptions[0];
                            Response.Redirect("~/CheckoutPaymentMethod.aspx");
                        }

                        if (shippingOptions.Count > 0)
                        {
                            dlShippingOptions.DataSource = shippingOptions;
                            dlShippingOptions.DataBind();
                        }
                        else
                        {
                            phSelectShippingMethod.Visible = false;
                            phShippingIsNotAllowed.Visible = true;
                        }
                    }
                }

3. I then Re-built the application in VWD

However when I go through the shopping cart and checkout process I still get prompted to select a shipping method.

Im not sure what I’m doing wrong or missing, but was wondering if this approach only works with “source” version of the application, as I am currently using the “no source” version and editing the CheckoutShippingMethod.ascx file in visual web developer
15 năm cách đây
hi

yes you are right, you have to use source version :)
15 năm cách đây
and guess what ,, i just tested your code and its working fine :)

thanks 4 sharing
15 năm cách đây
Cheers liquidq8

I'll switch to the source version...!

Regards, James
15 năm cách đây
I have Source Code version.  I am using Visaul Web Developer express 2008 and I also have C# Expresss 2008.   I havce added this logic as a test and I nothing happens...... What am I missing?   I need to Skip Many Sections

Billing, Shipping and Payment.  


Thanks
15 năm cách đây
try to download nopCommerce v1.40 .. same happened with me b4
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.