Results 1 to 11 of 11

Thread: how direct input data to msflexgrid

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2010
    Posts
    377

    how direct input data to msflexgrid

    Just started learning vb. I want to know to directly input data to msflexgrid. can someone please give me a simple sample of it. thanks.

  2. #2
    PowerPoster dilettante's Avatar
    Join Date
    Feb 2006
    Posts
    24,487

    Re: how direct input data to msflexgrid

    The MSFlexGrid and MSHFlexGrid controls are meant for displaying output. They do not accept input. People sometimes develop hacks though where they float a TextBox over cells and resize it to simulate Grid input.

    The DataGrid is the most up to date grid control that allows user input and editing naturally.

  3. #3
    Next Of Kin baja_yu's Avatar
    Join Date
    Aug 2002
    Location
    /dev/root
    Posts
    5,989

    Re: how direct input data to msflexgrid

    What version of VB are you using? This section of the forum is for VB Classic (not .Net) which has been unsupported for some time. If there is no particular reason why you are learning VB (classic) you might want to consider going for VB.Net instead.

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2010
    Posts
    377

    Re: how direct input data to msflexgrid

    thank you for the replies. I am using vb6 sp6. I really dont know if I am pertaining to msflexgrid but I am pertaining to such grid wherein I can manually and directly input record on one cell and perform or show some calculations on the other cell on another column.

    kindly direct me.. I am just beginning to learn vb6 just this week. no plans yet of learning vb.net

  5. #5
    Next Of Kin baja_yu's Avatar
    Join Date
    Aug 2002
    Location
    /dev/root
    Posts
    5,989

    Re: how direct input data to msflexgrid

    You might want to think about switching then. By the time you learn VB6 to be able to do anything more practical with it, demand for it will drop down to a minimum.

  6. #6

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2010
    Posts
    377

    Re: how direct input data to msflexgrid

    guys, I still need a sample about msflexgrid. I want to know in simple way how to perform calculations there and how to add new record, row and delete record/row. kindly help me guys.

  7. #7

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2010
    Posts
    377

    Re: how direct input data to msflexgrid

    I have gone over searching on the code bank but I cant seem to find one. kindly help out guys.

  8. #8
    Fanatic Member
    Join Date
    Aug 2004
    Location
    Essex, UK
    Posts
    774

    Re: how direct input data to msflexgrid

    This is how to place text in a cell - in this case, row 1, column 2:

    Code:
        Dim iRow As Integer
        Dim iCol As Integer
        
        iRow = 1
        iCol = 2
        
        MSFlexGrid1.TextMatrix(iRow, iCol) = "Hello!"
    This is just for an unbound FlexGrid, not connected to a datasource.

  9. #9

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2010
    Posts
    377

    Re: how direct input data to msflexgrid

    thanks for the reply. how about if it is bound and connected to a datasource? and can I also get sample for sample calculation please. thanks.

  10. #10
    Fanatic Member
    Join Date
    Aug 2004
    Location
    Essex, UK
    Posts
    774

    Re: how direct input data to msflexgrid

    You can use TextMatrix to get the values from any of the cells and then do your calculations. To bind the grid to a datasource you could use the ADO data control. If you search the web for ADO and Msflexgrid you will find many examples.

  11. #11

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2010
    Posts
    377

    Re: how direct input data to msflexgrid

    paulg4ije, I have searched the google and here about msflexgrid. also in pscode. but I havent got good results that I wanted about textmatrix. can you possiblly give me another sample for this textmatrix please. thanks in advance.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width