.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
MarieAdela
Imran Ghani
Post New Web Links

Switching panels

Posted By:      Posted Date: September 16, 2010    Points: 0   Category :ASP.Net
 
Hi,I have a page with four different panels. On a certain event, I want to switch panels, but this doesn't seem to happen until the function I'm running is done. Is there a way to trigger this immidiately?Cheers! :)


View Complete Post


More Related Resource Links

Office Development: Manage Metadata with Document Information Panels

  

Here the author uses Document Information Panels in the Microsoft 2007 Office system to manipulate metadata from Office docs for better discovery and management.

Ashish Ghoda

MSDN Magazine April 2008


Panels messing up page layout

  

Hi,


On a few different pages in my web app I have a scrollable panel that contains a gridview. When there is nothing in the panel display as I want it to, however when the grid view is populated with data it stretches the panel across the page which looks awful, it means the panel is partially stretched across the window but is still scrollable


Anyone know why this might be happening?

Thanks

Chris


VS2010: Switching tabs in wpf designer

  
Hi, I have a problem with the WPF designer in VS 2010. I have a WPF UserControl which contains a TabControl with several Tabs (TabItems).  It was always possible to switch the tabs in the designer to see the content of the individual tabs. However, suddenly this stops working. I can not switch the tabs anymore. [EDIT] Seems to be a known issues? https://connect.microsoft.com/VisualStudio/feedback/details/531868/wpf-editor-tabcontrol-issues Workaround does not work for me (or I do not understand it correctly)... [/EDIT] Any ideas? Thanks in advance. Jus  

Stacked collapsible panels lose spacing after being collapsed

  
Hi all- I can't figure out why these collapsible panels are losing their white space inbetween each header after the panel is collapsed.    CSS: .collapsePanelHeader { border: 1px solid #333333; color: #333333; background-color: #e5e5e5; font-weight: bold; padding: 5px; margin-top: 5px; cursor: pointer; } .collapsePanel { height: 0px; background-color: #ffffff; overflow: hidden; border: 1px solid #333333; border-top: none; padding: 5px; padding-top: 10px; }  Panels: <div> <asp:Panel ID="HeaderPanel2" runat="server" CssClass="collapsePanelHeader">   Category 1 <span class="alignRight"> <asp:Label ID="collapseStateTextLabel2" runat="server" CssClass="labelInsidePanelHeader"></asp:Label> <asp:Image ID="HeaderImage2" runat="server" /> </span> </asp:Panel> <asp:Panel ID="ContentPanel2" runat="server" CssClass="collapsePanel"> <asp:TextBox ID="TextBox2" runat="server" BorderStyle="None&

Tab Container, Tab panels with User Controls - bug?

  
Hello all, I have a aspx page with a tab container, and 5 tabs on it - 4 of which hold user controls on them. I have a strange issue that presents sometimes, and I am not sure just what is causing it. Here is the scenario : there is one user control on each tab. On each of those user controls, there are a number of radio buttons in Update Panels. If a user selects one of the tabs, then selects another tab and clicks on one of the radio buttons on that tab causing a postback, when the page refreshes, the content of the previous tab becomes visible at the top of the current tab, pushing the original content down below it - as if the content of the previous tab has been appended to the top of the current tab's content. Has anyone out there experienced anything like this? What I did to "fix" the issue was simply to go into the aspx code for the tab container, and change the order of the tab panels in the code, something like this :  <cc1:TabContainer ID="tabContainer" runat="server"> <cc1:TabPanel ID="tabFirstTab" runat="server" HeaderText="My first tab" > <ContentTemplate> <uc1:usercontrol1 ID="UC1" runat="server" /> </ContentTemplate> </cc1:TabPanel>

Switching texbox when pressing Enter key

  
Dear all, I have a ssimple mask which is based on 4 text box to be fills. What is teh simple way that when my user is pressing the ENTER key after editing first text box, cursor moves to the next text box in edit bomde ? thnaks regards SergeYour knowledge is enhanced by that of others.

collapsible panels

  
Hiiiiii Coders,  I want to create collapsible panels in css and html. Means that there should be html link and when i click over it, it should be collapsed and expand. Also  at a time, one panel should be opened. How can i get this using html and css. Is there ank kind of article that can guide me this? plz rep me as soon as poss thanx and regards 

DragPanelExtender for multiple Panels

  
I want to use drag panel extender of AJAX.But there is a problem.I have multiple panels but I cannot drag all the panels.I can drag just one panel.Please help me to drag multiple panels in AJAX.its very urgent!!!

Update Panels, Postback Triggers, and GridViews, Oh my

  
I've been battling with this page for the past couple days and it works, but it's annoying, so I am hoping someone maybe has dealt with this and can help me a little.   I have an UpdatePanel that acts as a container for a number of other update panels, everything in this container works.  I got the bright idea to add a ModalPopup Extender to enhance the user experience a little when performing a certain function on the site.  The panel that acts as the container for the ModalPopup sits outside the UpdatePanel Container because if it's in the container, any interaction with a child control throws "Input string not in the correct format" error message.  Because this is outside the comfort of the UpdatePanel Container, any control that populates information into the Popup control has to register a Postback.  Thus my problem: the controls that populate the Popup are GridViews.  The only GridView Event I care to cause a PostBack is the SelectedIndexChanged, but PostBack Triggers don't care, they take all comers.  Want to go to the next page? PostBack. Sort? Hell Yeah, Postback. My initial solution is to provide a confirm type of a message under the gridview and have the user confirm their selection by clicking a button to avoid causing a postback until it's necessary, but you know what? That kinda sucks, so I sub

chrome and safari problems with log ins and sign ups in update panels

  
Hi,This is probably a common problem.I have log in and sign up controls in update panels. They are being focussed on when the user clicks the appropirate button. Once done, hitting the sign-up or the log-in button, the browser (FF, IE) updates the update panels and all looks nice.In chrome and safari however, this does not work quite as nice. Login and sign up still happen. But focussing the controls does not, neither does the update panel update. The user has to reload the page to see that he is actually logged in or has signed up.This is really not nice and I found a very strange error, given that update panels work fine under other circumstances.Whats the problem here and how can this be solved?Thank you very much.Regards,D

Tab panels causing undesirable mark-up reformatting

  
I am using VS 2010 and making extensive use of tab panels with gridviews inside of each.  I very often am required to reformat the whole document as it seems that the gridview mark-up gets completely reformatted in one continuous line.  In the act of reformatting unwanted things get inserted such as linebreaks. When I was using VS 2008 this behavior was even worse.  Does anyone have a suggestion to fixing this issue?  I am wasting time because things are changing visually and tested work is getting automatically changed.  

moving Panels flicker as they scroll across the screen

  

I have a panel that I am changing the x location by 1 pixel with each clock tick.  The panel jiggles as it moves .  Why and how do I have it move smoothly

Thanks


Performance Drop when switching from a #temp table to a @temp table variable

  

I am trying to convert a stored procedure to a table valued function and the performance has taken a HUGE hit and I was wondering if there was anything that can be done about it. Since a table valued function can not use #temp tables it must be converted to a @temp table variable.

Here are some steps I have already taken...

The original stored proc starts off by populating a #temp table via "Select x Into #temp ..."

Leaving it a stored proc for now, I explicitly created the #temp table and did an "Insert Into ... Select From" to more closely model how it must work when using a @temp table variable. There was no discernible performance difference.

Still leaving it as a stored proc, I then swapped out the #temp table with the @temp table variable and now, all of the sudden, the performance drops from sub-second to over a minute!!!

The temp table only has one field defined as an int and it is distinct, so I tried making the field the Primary Key to see if that would help and it did not.

The temp table is created by scanning a table with around 11,000 rows and the temp table itself has about 4400 rows in it (if it makes a difference to anyone).

Does anyone have any suggestions (or hope) for me?

Thanks,
Jim


Performance Drop when switching from a #temp table to a @temp table variable

  

I am trying to convert a stored procedure to a table valued function and the performance has taken a HUGE hit and I was wondering if there was anything that can be done about it. Since a table valued function can not use #temp tables it must be converted to a @temp table variable.

Here are some steps I have already taken...

The original stored proc starts off by populating a #temp table via "Select x Into #temp ..."

Leaving it a stored proc for now, I explicitly created the #temp table and did an "Insert Into ... Select From" to more closely model how it must work when using a @temp table variable. There was no discernible performance difference.

Still leaving it as a stored proc, I then swapped out the #temp table with the @temp table variable and now, all of the sudden, the performance drops from sub-second to over a minute!!!

The temp table only has one field defined as an int and it is distinct, so I tried making the field the Primary Key to see if that would help and it did not.

The temp table is created by scanning a table with around 11,000 rows and the temp table itself has about 4400 rows in it (if it makes a difference to anyone).

Does anyone have any suggestions (or hope) for me?

Thanks,
Jim


Panels inside Formview

  

I have a FormView, and I want to put a panel inside it's EditTemplate and then acess it when the dropdown is changed so that the FormView calls Edit. Then they will become visible. How can I call them to visible if I can't reach them?


So, how can I make Panels inside EditTemplate in FormView as variable reachable so I can change their visibility?


            "PanelRegSala.Visible = true;
            FormViewRegSala.ChangeMode(FormViewMode.Edit);
            PanelBusca.Visible = true;
            PanelGrid.Visible = true;"

"<asp:Panel ID="PanelRegSala" runat="server" Visible="False">
          <asp:FormView ID="FormViewRegSala" runat="server" DataSourceID="SQLDSRegSalas" DataKeyNames="idSala">
              <EditItemTemplate>
    <tr>
    <td>
             

panels width equal to the parents width ???

  

I have my own panel class ksClass and I want to insert a ksPanel in a form and the width of the ksPanel shold just be thw same as the width of the form !

        private void Form1_Load(object sender, EventArgs e)
        {
            this.Controls.Add(new ksPanel());
        }

In the class I have this code:

    public ksPanel()
    {
      Panel aPanel = new Panel
      {
        Location = new Point(0, 0),
        Size = new Size(this.Parent.ClientSize.Width, 20),
        BackColor=Color.White,
        BorderStyle = BorderStyle.FixedSingle
      };
      this.Controls.Add(aPanel);
    }

but gets an unhandled NullReferenceException !

How can I then set the width of my panel to the "width" of the form it's inserted on ?

 


Best regards KSor, Denmark

Dynamicly created panels

  

Hi ,

I have created panels dynamicly , with a label and a button in them , no when i click the dynamicly added button it should retrieve the label text in that specific panel . Here is some code that i have

     private void ShowRoomsNow(string Desc , string code , int num)
        {
        
                Panel pnl = new Panel();
                pnl.BorderColor = Color.Black;
                pnl.BorderWidth = 1;
                pnl.ID = "Pnl" + num;
                Button btn = new Button();
                btn.Text = "Book";
           
                System.Web.UI.WebControls.Image img = new System.Web.UI.WebControls.Image();
                btn.ID =  "btn"+num;
                Label lbl = new Label();
                lbl.ID = "Lbl" + num;
                lbl.Text = " Room Name: "+ Desc +"<br/> RoomCode: " +code + "<br/>No:"+ num;
                lbl.ForeColor = Color.Black;
                pnl.Controls.Add(lbl);
                pnl.Controls.Add(btn);
                pnl.Controls.Add(new LiteralControl("<br/>"));
                pnl.Controls.Add(new LiteralControl("<br />"));
                pnl.Controls.Add(new LiteralControl("       "));
                pnl.Cont
Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend