Page 1 of 1

Jiwa grid SetDrillDown() not working on custom form

PostPosted: Thu Nov 02, 2017 3:47 pm
by perry
Hi

v7.0.175

Can you please take a look at my setdrilldown function? It doesn't seem to work on a form plugin,

Attached the sample custom form (process form) plugin, I simply added the grid with a dummy entry.

Code: Select all
 Private Sub SetupGrid()

        JiwaGrid1.AddColumn("InvoiceNo", New FarPoint.Win.Spread.CellType.TextCellType(), "Invoice No.", 25, False, True, True, True, , True)

        JiwaGrid1.SetupComplete()


        Dim row As Integer = 0
        JiwaGrid1.ActiveSheet.RowCount = 1

        With JiwaGrid1

            .GridText("InvoiceNo", row) = "100002"

            .SetDrillDown("InvoiceNo", row, 300, "000000000800000000NK") '"JiwaFinancials.Jiwa.JiwaSalesUI.SalesOrder.SalesOrderEntryForm"

        End With
    End Sub

Re: Jiwa grid SetDrillDown() not working on custom form  Topic is solved

PostPosted: Fri Nov 10, 2017 10:50 am
by Mike.Sheen
Hi Perry,

First you should make the celltype JiwaFinancials.Jiwa.JiwaApplication.JiwaManageGrid.JiwaTextCellType when adding the column:

Code: Select all
JiwaGrid1.AddColumn("InvoiceNo", New JiwaFinancials.Jiwa.JiwaApplication.JiwaManageGrid.JiwaTextCellType(), "Invoice No.", 25, False, True, True, True, , True)


And whenever you add a row to the grid (like when you're displaying the data) - you'll need to copy the column header tag to the cell tag for each column:

Code: Select all
' copy col header tag into each cell tag.
For Each column As FarPoint.Win.Spread.Column In JiwaGrid1.ActiveSheet.Columns
   JiwaGrid1.ActiveSheet.Cells(row, column.Index).Tag = JiwaGrid1.ActiveSheet.ColumnHeader.Cells(1, column.Index).Tag
Next


The tag property is a string containing attributes - including "DrillDown=1" - when you added the column the column header tag would have had it's tag set to include "DrillDown=1" - so copying the tag from the column header to the cell would make the cell drillable.

Mike

Re: Jiwa grid SetDrillDown() not working on custom form

PostPosted: Fri Nov 10, 2017 10:55 am
by perry
Thanks Mike