Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. righet click on tree view?

righet click on tree view?

Scheduled Pinned Locked Moved ASP.NET
questiondata-structureshelp
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    shima 2011
    wrote on last edited by
    #1

    Hi in file context menu on tree view: I tried to add node to the tree and while adding it ,the value and text is set. the new node is shown but the menu does not appear while Rclick. plz tell me what is wrong?

    protected void LinkButton1_Click1(object sender, EventArgs e)
    {
    setRightClickedNode();

        if (rightClickedNode != null)
        {
          
            TreeNode nodeToAdd = new TreeNode();
            nodeToAdd.Text = "<div id='151'  oncontextmenu='return showmenuie5(event,'151')' > new  node  </div>";
            nodeToAdd.Value = "151";
            rightClickedNode.ChildNodes.Add(nodeToAdd);
        }
        else
        {
            Label1.Text = "Oops, no right click node found. You have a problem";
        }
    }
    
    A 1 Reply Last reply
    0
    • S shima 2011

      Hi in file context menu on tree view: I tried to add node to the tree and while adding it ,the value and text is set. the new node is shown but the menu does not appear while Rclick. plz tell me what is wrong?

      protected void LinkButton1_Click1(object sender, EventArgs e)
      {
      setRightClickedNode();

          if (rightClickedNode != null)
          {
            
              TreeNode nodeToAdd = new TreeNode();
              nodeToAdd.Text = "<div id='151'  oncontextmenu='return showmenuie5(event,'151')' > new  node  </div>";
              nodeToAdd.Value = "151";
              rightClickedNode.ChildNodes.Add(nodeToAdd);
          }
          else
          {
              Label1.Text = "Oops, no right click node found. You have a problem";
          }
      }
      
      A Offline
      A Offline
      Ali AlOmairi TJIC
      wrote on last edited by
      #2

      Sir, is the string that you were trying to write like this:

      nodeToAdd.Text = "<div id='151' oncontextmenu='return showmenuie5(event,'151')' > new node </div>";

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups