Results 1 to 3 of 3

Thread: How to add a row on flexgrid

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2011
    Posts
    4

    How to add a row on flexgrid

    hi! can anyone help me how to add a row on a flexgrid because i have a new table that i created and the table has nothing on it.

    HERE'S THE CODE:

    SQL = "Select isnull(A.drino,'') As [drino], isnull(A.PONum,'') As [PONum], isnull(A.prodcode,'') As [prodcode], isnull(A.AcctCode,'') As [AcctCode], isnull(B.AcctDesc,'') As [AcctDesc], isnull(A.Debit,0) As [Debit], isnull(A.Credit,0)As [Credit], A.RowID from [" & gDatabaseName & "].dbo.drind_acode A left join [" & gDatabaseNameAccounts & "].dbo.accounts B on A.AcctCode = B.AcctCode where drino = '" & drino & "' and PONum = '" & ponum & "' and prodcode = '" & prodcode & "'"
    rs = dbConn.Execute(SQL)


    '====SET COLUMNS HIDDEN
    fgAccount.set_ColHidden(8, True) 'rowid

    fgAccount.Rows = rs.RecordCount + 1

    If Not rs.EOF Then
    For i = 1 To rs.RecordCount
    fgAccount.set_TextMatrix(i, mintLineNum, i)
    fgAccount.set_TextMatrix(i, mintDRIno, Trim(rs.Fields("drino").Value) & "")
    fgAccount.set_TextMatrix(i, mintPONum, Trim(rs.Fields("ponum").Value) & "")
    fgAccount.set_TextMatrix(i, mintProdCode, Trim(rs.Fields("prodcode").Value) & "")
    fgAccount.set_TextMatrix(i, mintAcctCode, Trim(rs.Fields("AcctCode").Value) & "")
    fgAccount.set_TextMatrix(i, mintAcctDesc, Trim(rs.Fields("AcctDesc").Value) & "")
    fgAccount.set_TextMatrix(i, mintDebit, rs.Fields("Debit").Value & "")
    fgAccount.set_TextMatrix(i, mintCredit, rs.Fields("Credit").Value & "")
    fgAccount.set_TextMatrix(i, mintRowID, Trim(rs.Fields("RowID").Value) & "")
    rs.MoveNext()
    Next
    End If

  2. #2
    PowerPoster make me rain's Avatar
    Join Date
    Sep 2008
    Location
    india/Hubli
    Posts
    2,208

    Re: How to add a row on flexgrid

    is this vb6 ? or VBA
    The averted nuclear war
    My notes:

    PrOtect your PC. MSDN Functions .OOP LINUX forum
    .LINQ LINQ videous
    If some one helps you please rate them with out fail , forum doesn't expects any thing other than this

  3. #3

    Thread Starter
    New Member
    Join Date
    Sep 2011
    Posts
    4

    Re: How to add a row on flexgrid

    Im using VB 2008.

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