New Custom Page Problem
-
- Ensign (ENS)
- Posts: 5
- Joined: Sun Jul 15, 2012 4:18 pm
New Custom Page Problem
I'm having trouble creating a new page. Multiple posts reference copying and renaming an About page to create a simple template, but any page I copy and rename generates the following error inside our left (nav.) sidebar:
[[ConLib:SimpleCategoryList]] c:\inetpub\[ourwebsite]\ConLib\SimpleCategoryList.ascx.cs(91): error CS0103: The name 'lblUserGroup' does not exist in the current context
I'm familiar with the relationship between the aspx page and scriptlets as content, but am being prevented from creating new pages due to this error. Even simply renaming the default.aspx file to default1.aspx generates the error. I'm new to AbleCommerce and any advice is much appreciated.
[[ConLib:SimpleCategoryList]] c:\inetpub\[ourwebsite]\ConLib\SimpleCategoryList.ascx.cs(91): error CS0103: The name 'lblUserGroup' does not exist in the current context
I'm familiar with the relationship between the aspx page and scriptlets as content, but am being prevented from creating new pages due to this error. Even simply renaming the default.aspx file to default1.aspx generates the error. I'm new to AbleCommerce and any advice is much appreciated.
Re: New Custom Page Problem
The steps you're following should work. Try this as an alternative. Create a new file, name it default1.aspx. Open the new file and paste in the text from the default page:
Then browse to default1.aspx while you are logged in as an admin. You should then be able to change the scriptlets.
Code: Select all
<%@ Page Language="C#" MasterPageFile="~/Layouts/Scriptlet.master" Inherits="CommerceBuilder.Web.UI.AbleCommercePage" Title="New Page" %>
<%@ Register Assembly="CommerceBuilder.Web" Namespace="CommerceBuilder.Web.UI.WebControls.WebParts" TagPrefix="cb" %>
<asp:Content runat="server" ContentPlaceHolderID="PageContent">
<cb:ScriptletPart ID="HomePage" runat="server" Layout="Three Column" Content="Home Page" LeftSidebar="Standard Sidebar 1" RightSidebar="Standard Sidebar 2" Header="Standard Header" Footer="Standard Footer" Title="Home Page" AllowClose="False" AllowMinimize="false" />
</asp:Content>
-
- Ensign (ENS)
- Posts: 5
- Joined: Sun Jul 15, 2012 4:18 pm
Re: New Custom Page Problem
Thanks. I did try pasting the content into a fresh file, and received the error before I could alter the scriptlets. I am using a simple code editor/FTP program outside of AbleCommerce. Is there some type of database of "approved actual" pages that AbleComm maintains? It's as if some pages were grandfathered in to rendering properly, but once the files are touched--not even altered, but just resaved--they generate the error. Nothing is changing in the file content at all. I'm stumped.
Re: New Custom Page Problem
No, Able just reads the root folder to display custom pages and as you can see, the pages aren't very complex. And you said you tried renaming an existing file and it failed, too, correct?
What FTP software are you using? Can you try setting the file type to binary versus text when you upload? This wouldn't explain the rename failure, but it seems worth a try.
What FTP software are you using? Can you try setting the file type to binary versus text when you upload? This wouldn't explain the rename failure, but it seems worth a try.
-
- Ensign (ENS)
- Posts: 5
- Joined: Sun Jul 15, 2012 4:18 pm
Re: New Custom Page Problem
I followed your instructions and created an entirely fresh file pasted from your page code above and received the exact same error. This is occurring on both or production server and our test server. I swear I could create pages this way in the past. Could this be an update/version issue?
I'm using EditPlus for page editing and Filezilla when I only need to move files around. I'm simply not able to create any new files without that error occurring on the left nav. AbleCommerce just won't let me create any new files. Very strange.
I'm using EditPlus for page editing and Filezilla when I only need to move files around. I'm simply not able to create any new files without that error occurring on the left nav. AbleCommerce just won't let me create any new files. Very strange.
Re: New Custom Page Problem
I have another idea. Can you edit your standard left hand content scriptlet to remove the reference to the SimpleCategoryList ConLib control? It's probably the Standard Sidebar 1 scriptlet. That should prevent the error you're seeing and let your new page display. Once your new page is displaying you can change the script contents for the new page using the edit page function and put the SimpleCategoryList back in the standard sidebar.
If that works it's because that ConLib control is looking for a label control that isn't found on any scriptlet for your new blank page.
If that works it's because that ConLib control is looking for a label control that isn't found on any scriptlet for your new blank page.
-
- Ensign (ENS)
- Posts: 5
- Joined: Sun Jul 15, 2012 4:18 pm
Re: New Custom Page Problem
Thanks. That would definitely do it, but unfortunately, all our left hand scriptlet consists of is the ConLib SimpleCategoryList control, so that would also mean eliminating our left nav. This is a site I'd inherited and the configuration seems wrong, and I may have found a clue.
We're using a custom theme and all the scriplets seem to be located in the Scriptlets/Custom/Sidebar folder except for the Standard Sidebar 1.htm file. That's in Scriptlets/Default/Sidebar. Is this just how AbleCommerce does things, or does that seem in error?
We're using a custom theme and all the scriplets seem to be located in the Scriptlets/Custom/Sidebar folder except for the Standard Sidebar 1.htm file. That's in Scriptlets/Default/Sidebar. Is this just how AbleCommerce does things, or does that seem in error?
- jmestep
- AbleCommerce Angel
- Posts: 8164
- Joined: Sun Feb 29, 2004 8:04 pm
- Location: Dayton, OH
- Contact:
Re: New Custom Page Problem
If there has been any change to Able's default scriplet, that should be in the custom folder. Able looks into the default folder only if there is nothing in the custom folder for the scriplet. At upgrade time, you don't overwrite scriplets in the custom folder, but you can/do overwrite the ones in the default folder.
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Re: New Custom Page Problem
chrisNoTubes,
As Judy indicated, there will be a version of the scriplet in the custom folder if you've made any changes to the default scriptlet.
I understand that the only thing in the left sidebar is the SimpleCategoryList control. If you could temporarily remove that from the left sidebar and then try loading any of your new pages, it might give an additional clue as to what the problem is. If the page loads after removing the SimpleCategoryList control, then you can finish setting up your new page. After that, restore the SimpleCategoryList to the left sidebar and see if the page still loads.
If the page doesn't load after removing the left sidebar, I'd do a search through all of your code for 'lblUserGroup' to see what control is trying to use that variable. Perhaps that will give some hints to the problem.
As Judy indicated, there will be a version of the scriplet in the custom folder if you've made any changes to the default scriptlet.
I understand that the only thing in the left sidebar is the SimpleCategoryList control. If you could temporarily remove that from the left sidebar and then try loading any of your new pages, it might give an additional clue as to what the problem is. If the page loads after removing the SimpleCategoryList control, then you can finish setting up your new page. After that, restore the SimpleCategoryList to the left sidebar and see if the page still loads.
If the page doesn't load after removing the left sidebar, I'd do a search through all of your code for 'lblUserGroup' to see what control is trying to use that variable. Perhaps that will give some hints to the problem.
-
- Ensign (ENS)
- Posts: 5
- Joined: Sun Jul 15, 2012 4:18 pm
Re: New Custom Page Problem
Thanks Judy and David. The problem seemed to be related to something that was wrong with our test server, but yes, removing the SimpleCategoryList control let the page display without any errors and without any navigation menu. I still don't understand why I can't save an exact copy of Default.aspx with a new name without Standard Sidebar 1 erroring, but many mysterious in this old site! I've created a replacement sidebar with navigation that doesn't use the SimpleCategoryList control and all seems well. Thanks again.