Forum Discussion

sivakarthik's avatar
sivakarthik
Contributor
6 years ago

Grid column header click and move the column

Hi everyone,

 

I have a question regarding the grid column headers.

Actually what I am trying to do is, to test the grid column move function. 

 

For that I have used the Grid.ClickColumHeader(Id, 0)

is there a way to move the column place5 to 1 or 1 to  3like that in test Complete. ?

 

any info or help material would be great help

 

Thanks and Regards

SivaKartheek Sreeram

4 Replies

  •  

    Actually for moving I can use the obj.Drag()  but, in that i have to use the co-ordinates. is there any alternate fo that with out using co-ordinates I can drag and place the column.

     

    2. I can access the Grid customization window in grid by click(5, 7) but I don't want like that in the column header I am unable access that via name of the colum. Actuall in the grid column header it places on -1 side is there a way to access it?

    3. Is it posisible to get column width and height in the grid ? if I use the getwidth() method its giving me the following the entire grid width. Actually I don't need that. I need only the column width.

     

    any info or help would be great help

    Thanks and regards

    SivaKartheek Sreeram 

    • TanyaYatskovska's avatar
      TanyaYatskovska
      SmartBear Alumni (Retired)

      Hi SivaKartheek,

       

      What exact grid control do you use?

      I recommend that you check the Working With Grids article. Do you see your control in the list of supported controls? If you see, in this case, TestComplete provides special support of such controls and you can use special methods and properties to access the grid.

       

      Otherwise, you can make TestComplete treat your control as a support one by using the Object Mapping feature.

       

      • sivakarthik's avatar
        sivakarthik
        Contributor

        Hi Tanya,

         

        I am using the TcxGridSite. I have already checked that link. But I didn't get idea how to proceed further. As you can see my earlier message  thats what I got from that link.

         

        Do you have any other ideas

         

        thanks and regards

        SivaKartheek Sreeram