100% Dynamic Drag Panels - How?

Last post 07-01-2007 9:20 AM by blink18jew. 4 replies.

Sort Posts:

  • 100% Dynamic Drag Panels - How?

    06-27-2006, 10:11 AM
    • Contributor
      2,484 point Contributor
    • toddhd
    • Member since 06-18-2002, 10:03 AM
    • Edina, MN
    • Posts 527

    I'm confused and need some help.

    My company is creating some web parts that will go into a portal we have developed, however these parts will also be "sold seperately" and should be able to work in any portal that uses web parts. So we inherit from a web part base class, and everything is generated dynamically from there, i.e.:

    Button b = new Button();
    b.Text = "Submit";
    this.Controls.Add(b);

    Ok, so every web part we make has a LinkButton that says, "Help", and when you click on it, we want to display a floating, draggable panel with some help text on it. The drag panel seems perfect in this regard.

    The thing is, since these web parts must be able to work in any given portal, I can't ensure that there will be a existing, hidden panel and/or a Drag Panel already setup and ready for use on the web page. I need to create it dynamically. So I need to do something like this:

    Panel p = new Panel();
    p.ID = "Panel1";
    // Add some help text or whatever to the panel here
    DragPanelProperties dpp = new DragPanelProperties();
    dpp.TargetControlID = p.ID;
    dpp.DragHandleID = p.ID;
    Page.Controls.Add(p);

    This isn't working at all. TargetControlID doesn't even show up in intellisense, and doesn't compile. I assume I need a dragpanelextender as well, but I that has no properties either, and won't compile.

    How can I 100% dynamically generate a drag panel? Or can't I?

    -Todd Davis
    http://www.SeaburyDesign.com
  • Re: 100% Dynamic Drag Panels - How?

    07-01-2007, 7:45 AM
    • Member
      197 point Member
    • blink18jew
    • Member since 05-21-2007, 8:12 PM
    • Posts 626

    did you manage to do this in the end? i would be very interested as i am trying to create dynamic drag panels but im only able to make normal panels thus far thanks si! 

  • Re: 100% Dynamic Drag Panels - How?

    07-01-2007, 7:54 AM
    • Contributor
      2,484 point Contributor
    • toddhd
    • Member since 06-18-2002, 10:03 AM
    • Edina, MN
    • Posts 527

    No, I was unable to do so. In the end, we ended up creating our own drag panels using MooTools. This worked better for us anyway, because we needed some advanced functionality that wasn't available in the original dragpanel. We had originally planned to modify the dragpanel, but MooTools offered a lot of functionality, and it was easier that point to just rewrite it.

    -Todd Davis
    http://www.SeaburyDesign.com
  • Re: 100% Dynamic Drag Panels - How?

    07-01-2007, 9:13 AM
    • Member
      197 point Member
    • blink18jew
    • Member since 05-21-2007, 8:12 PM
    • Posts 626

     kool, what is mootools it sounds kool, what is it? Does it generate dynamic dragpanels? or is it a toolbox of controls like an add on for ajax si!

    is this it : http://demos.mootools.net/Tips 

  • Re: 100% Dynamic Drag Panels - How?

    07-01-2007, 9:20 AM
    • Member
      197 point Member
    • blink18jew
    • Member since 05-21-2007, 8:12 PM
    • Posts 626

     i feel i should explain what im trying to do a little bit more.I have a page that i want to allow the user to create dragpanels (up to 10 for example) either dynamically or otherwise. That can be resized and dragged within a preset parameter or placeholder. Im also going t attempt to allow the user to set the colour of the panels / background images, as well as text within the panels if they so should need it. When you were looking for things like mootools did you come across anything else like it? what made you pick mootools? thanks a million si!

Page 1 of 1 (5 items)