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. General Programming
  3. C#
  4. DataGrid Column: How to create simulated mouse click event or column header click event.

DataGrid Column: How to create simulated mouse click event or column header click event.

Scheduled Pinned Locked Moved C#
tutorial
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.
  • R Offline
    R Offline
    roman_s
    wrote on last edited by
    #1

    right now I have one column header that does not alphabetically sort its self when column header is clicked. so I figured I can make an event if that column header is clicked to a column header that sorts the it how I need to Column header Im targeting is gridView.columnFlags so far I have

        private void OnColumnHeaderClick(object sender, Divelements.SandGrid.GridColumnEventArgs e)
        {
            if (e.GridColumn.Equals(columnTest))
            {
                //this.OnMouseClick(new MouseEventArgs(MouseButtons.Left, 1, 100, 100, 0));
    
              //THIS IS WHERE I CAN SIMULATE MOUSE CLICK ON THE gridView.columnFlags COLUMN HEADER 
             // THE ABOVE CODE DOESNT WORKS
            }
    
            gms.HandleSort(e.GridColumn);
    
    H 1 Reply Last reply
    0
    • R roman_s

      right now I have one column header that does not alphabetically sort its self when column header is clicked. so I figured I can make an event if that column header is clicked to a column header that sorts the it how I need to Column header Im targeting is gridView.columnFlags so far I have

          private void OnColumnHeaderClick(object sender, Divelements.SandGrid.GridColumnEventArgs e)
          {
              if (e.GridColumn.Equals(columnTest))
              {
                  //this.OnMouseClick(new MouseEventArgs(MouseButtons.Left, 1, 100, 100, 0));
      
                //THIS IS WHERE I CAN SIMULATE MOUSE CLICK ON THE gridView.columnFlags COLUMN HEADER 
               // THE ABOVE CODE DOESNT WORKS
              }
      
              gms.HandleSort(e.GridColumn);
      
      H Offline
      H Offline
      Henry Minute
      wrote on last edited by
      #2

      As this is a 3rd party control, you are more likely to get help if you ask on their web site. Here[^].

      Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” Why do programmers often confuse Halloween and Christmas? - Because 31 Oct = 25 Dec. Business Myths of the Geek #4 'What you think matters.'

      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