Visible property question

4 posts, 1 answers
  1. lisal
    lisal avatar
    22 posts
    Member since:
    Mar 2007

    Posted 20 Jun 2008 Link to this post

    I have 4 tabs with 4 corresponding pageviews.  Under certain conditions, I set tab number 2 to visible = false.  This causes the contents of pageview 2 to appear in tab 3 (and the contents of pageview 3 to appear in tab 4).  However, if I set the visible property of pageview 2 to false,  it simply takes away the contents of tab 3.  So basically, how do I get rid of tab 2 and it's pageview at the same time?

    Thanks for you help,
    Lisa
  2. Answer
    Paul
    Admin
    Paul avatar
    4281 posts

    Posted 20 Jun 2008 Link to this post

    Hello lisal,

    You can easily achieve your goal by setting the PageViewID property for each tab to point to the corresponding pageview.

    Best wishes,
    Paul
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. lisal
    lisal avatar
    22 posts
    Member since:
    Mar 2007

    Posted 20 Jun 2008 Link to this post

    Perfect!  Thanks for always being so prompt and helpful.
  4. Chris
    Chris avatar
    23 posts
    Member since:
    Nov 2003

    Posted 08 May 2009 Link to this post

    Can you explain why this is happening?  To me this does not seem very intuitive at all.

    I had this in my code:

     

     

     

     

     

    if (!Page.User.IsInRole("Manager"))   
    {  
        caseTabs.FindTabByText("Investor").Visible = false;  
        caseMultiPage.FindPageViewByID("InvestorView").Visible = false;   
    }  
     
     

    And changed it to this:

     

     

     

     

    if (!Page.User.IsInRole("Manager"))  
    {  
        caseTabs.FindTabByText("Investor").Visible = false;  
        caseMultiPage.FindPageViewByID("InvestorView").Visible = false;  
     
        caseTabs.FindTabByText("Documents").PageViewID = "DocumentView";  

    And that worked, but I'm not clear why I should have to reset the PageViewID of a tab that is totally unrelated.  I DON'T mind this as a workaround if that is what it is but it seems like a bug in the TadTab or the RadPageView control.  If this is a bug will it be fixed on an upcoming release?  If it is not can you please explain the reasoning behind this?

     

     

     

    I find the Telerik controls to be very intuitive (usually) but I wast4ed a number of hours on this, thinking that some where I had a bug in my code.

     

     

     

Back to Top