Solved

Move row in Msflexgrid

Posted on 2003-11-26
3
1,066 Views
Last Modified: 2012-06-27
How to write code for moving row in MSflexgrid?
where i can find the sample code
0
Comment
Question by:cyseng10
  • 2
3 Comments
 
LVL 9

Expert Comment

by:bhagyesht
ID: 9830216
assume fg is the flexgrid object this will move a row up


    Dim strTemp As String
    If fg.Row > 1 Then
        For i = 1 To fg.Cols - 1
            strTemp = fg.TextMatrix(fg.Row - 1, i)
            fg.TextMatrix(fg.Row - 1, i) = fg.TextMatrix(fg.Row, i)
            fg.TextMatrix(fg.Row, i) = strTemp
        Next i
    End If
0
 
LVL 1

Author Comment

by:cyseng10
ID: 9835510
the sample code working well for move up row. if i want move down row. how the code will be?

how do i apply using mouse to move row up and down when row selected?

0
 
LVL 9

Accepted Solution

by:
bhagyesht earned 100 total points
ID: 9835532
   Dim strTemp As String
    If fgDesign.Row < fgDesign.Rows - 2 Then
        For i = 1 To fgDesign.Cols - 1
            strTemp = fgDesign.TextMatrix(fgDesign.Row + 1, i)
            fgDesign.TextMatrix(fgDesign.Row + 1, i) = fgDesign.TextMatrix(fgDesign.Row, i)
            fgDesign.TextMatrix(fgDesign.Row, i) = strTemp
        Next i
    End If
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This is an explanation of a simple data model to help parse a JSON feed
If you’re thinking to yourself “That description sounds a lot like two people doing the work that one could accomplish,” you’re not alone.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question