Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Displaying the Pane Names to other rolesDisplaying the Pane Names to other roles
Previous
 
Next
New Post
6/28/2007 3:30 PM
 

What's up all,
  Is there any way to show the "Pane" names to other roles other than Admin and Host without giving edit rights to the page to the role.

I am creating a "lite" control panel for certain roles which only contains a limited number of modules (text/html module and other custom ones that we created).  I don't want the user to have edit rights to the pages, just want to show them where they can add these modules to.

I was going to recreate the same code that puts the pages in "Preview" mode which flips the panes on and off.

Anyone have any other suggestions?

Thanks!

 
New Post
6/29/2007 9:25 AM
 

forget it...I got it...if anyone else needs the code here you go:

private void loadPaneNames()
        {
            try
            {
                foreach (string pane in PortalSettings.ActiveTab.Panes)
                {
                    //Find all of Panes on the page
                    Control ctlPane = this.Parent.FindControl(pane);

                    if (ctlPane != null)
                    {
                        ctlPane.Visible = true;

                        // display pane border
                        if (ctlPane.GetType() == typeof(HtmlContainerControl))
                        { ((HtmlContainerControl)ctlPane).Style["border"] = "dotted 1px #0000FF"; }

                        // display pane name
                        Label lbl = new Label();
                        lbl.Text = String.Format("<center>{0}</center><br>", pane);
                        lbl.CssClass = "SubHead";
                        ctlPane.Controls.AddAt(0, lbl);
                    }
                }
            }
            catch (Exception exc) //Module failed to load
            {
                Exceptions.ProcessModuleLoadException(this, exc);
            }

        }

 
New Post
6/29/2007 9:58 AM
 

Sorry my mistake, use this "if" instead to set the border:

// display pane border
                        if (ctlPane is HtmlContainerControl)
                        {
                            ((HtmlContainerControl)ctlPane).Style["border"] = "dotted 1px #0000FF";
                        }

 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Displaying the Pane Names to other rolesDisplaying the Pane Names to other roles


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out