Adding A Custom Module

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
13 Jahre weitere
I am using nopCommerce 1.9.  I have a situation where I wanted to create a new product template.  I used the "VariantsInGrid.ascx" as a starting point by copy/past/rename files.  I then changed the following:

Inherits="NopSolutions.NopCommerce.Web.Templates.Products.VariantsInGrid"
CodeBehind="VariantsInGrid.ascx.cs"

to

Inherits="NopSolutions.NopCommerce.Web.Templates.Products.VariantsInDropDown"
CodeBehind="VariantsInDropdown.ascx.cs"

The code behind file class definition also got changed to:


namespace NopSolutions.NopCommerce.Web.Templates.Products
{
  public partial class VariantsInDropdown : BaseNopFrontendUserControl
    {
       .......
    }
}


When I compile the website, I get a "Could not load type 'VariantsInDropDown'" which is pointing to the VariantsinGrid.ascx file for the inherits part.

I have done this many times in other web projects and it worked fine.  Any suggestions on how to properly create a new product template and reference everything correctly so it compiles?

Thanks,

Bo
13 Jahre weitere
Update:

I had opened the project as a website in IIS for the NopCommerceStore folder.  I typically like programming web projects using IIS instead of the built-in web server.  In any case, I re-opened it as a project/solution and then did the same copy/paste/rename and it all hooked together.

Bo
13 Jahre weitere
Hey, I have been running into the same issue and have failed to resolve it. What were the steps you took to resolve it. I am a newbie with ASP.NET and NOPCommerce.

Thanks,
Brennan
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.