Results 1 to 3 of 3

Thread: Adding view(s) dynamically to a multiview

  1. #1

    Thread Starter
    Frenzied Member KGComputers's Avatar
    Join Date
    Dec 2005
    Location
    Cebu, PH
    Posts
    2,024

    Adding view(s) dynamically to a multiview

    Hi,

    Done lots of research on this, but has not been productive yet.. but heres the scenario anyway...

    1. I have a button that adds a view which contains controls like (radio button, button, textfield, label, and panel to hold the controls..)

    2. When the button is always clicked, it will always add a view with the controls to the multiview..

    How do i do this in asp.net? C# particularly..vb.net is welcomed

    Another option will be is that when the button inside a particular view is clicked, it will delete the view not the other views.

    Hope you could help..

    (Greg)
    CodeBank: VB.NET & C#.NET | ASP.NET
    Programming: C# | VB.NET
    Blogs: Personal | Programming
    Projects: GitHub | jsFiddle
    ___________________________________________________________________________________

    Rating someone's post is a way of saying Thanks...

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: Adding view(s) dynamically to a multiview

    You should be able to create the view and simply go

    MultiView1.Views.Add(newViewObject);

    Does that answer both #1 and #2?

    Not sure what you mean by the 'other option' though... you seem to be able to want to delete a view, is that right?

  3. #3

    Thread Starter
    Frenzied Member KGComputers's Avatar
    Join Date
    Dec 2005
    Location
    Cebu, PH
    Posts
    2,024

    Re: Adding view(s) dynamically to a multiview

    Mendhak,

    tried that one statement, but just want to clarify things out...

    1. I have a button named (Add Details)..This is located outside the multiview.

    2. Everytime this button is clicked on the page, say 5 times, it will add 5 views (Details) to the multiview..

    3. Each view has a panel that contains other controls like textbox, radio button, checkbox, label and a button for delete.

    4. This button delete when clicked will simply remove the particular view.

    5. So if you click one delete button, the views on the multiview will now become 4.

    6. All views have the same design/UI/interface...

    Done, lots of code from different samples, but seems it does not work...Don't know if im missing something...

    Greg
    CodeBank: VB.NET & C#.NET | ASP.NET
    Programming: C# | VB.NET
    Blogs: Personal | Programming
    Projects: GitHub | jsFiddle
    ___________________________________________________________________________________

    Rating someone's post is a way of saying Thanks...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width