Results 1 to 2 of 2

Thread: MshFlexgrid - more questions

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jul 2000
    Location
    Malaysia
    Posts
    90
    I have a form with mshflexgrid displaying data from a table. I also have a command button inside this form. This program highlight the row when user click on it. if the user click on the command button, this program will proceed to display another form and let the user make changes on this record. my code look something like below:

    ' <A> from, if user click on the command change button
    Private Sub cmdchg_click()
    Flex1.Row = Flex1.RowSel
    Flex1.Col = 1

    ' store employee code into the form change text1
    FrmEmpChg.Text1.Text = Flex1.Text
    FrmEmpChg.Show
    End Sub


    ' <B> Form to change Employee information
    Private Sub form_load()
    Dim Db as Database
    Dim Rs as Recordset

    Set Db = OpenDatabase(App.Path & "\DepartMent.Mdb")
    Set Rs = db.OpenRecordset("Employee", dbOpenTable)

    Rs.Index = "ID"
    Rs.Seek "=", Trim(Text1.Text)
    If Not Rs.NoMatch Then
    Text2.text = Rs!Name
    Text3.text = Rs!Address
    -
    -
    Else
    Msgbox("Can't Find This Record")
    End If

    End Sub


    Text1.text box on <B> form displayed the employee ID correctly but seek operation failed. If i do a debug.print on text1.text, there was nothing displayed.
    Appreciate if someone can share their experience on this.


    Regards

    CT

  2. #2
    Guest

    Talking

    Not the answer but do you know how can we control the black part of the grids?.... like the shadow..... on the bottom and right....

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