Postingan

Menampilkan postingan dengan label mshflexgrid

Select Single Cell in MSHFlexgrid

Gambar
         How to use MSHFlexgrid in selecting a particular column. It is very easy, as shown in the picture below. For example a data has been shown in contorl MSHFlexgrid, then the user will select one of the existing data in that column, then the program for manangkap data chosen by the user are as follows:        Private Sub Command1_Click()       MsgBox (MSHFlexGrid1.TextMatrix(MSHFlexGrid1.Row, MSHFlexGrid1.Col))  End Sub     More topic of Mshflexgrid    -. How to Use MSHFlexgrid ?  -. Mshflexgrid with Adodc  -. Editable MSHFlexgrid  -. Attach textbox to MSHFlexgrid  -. MSHFlexgrid select a cell and change background

MSHFlexgrid select a cell and change background

Gambar
         To change the color on the column or cell that is selected on the control MSHFlexgrid is very easy. Open a new project in Visual Basic 6.0, add one form and one control MSHFlexgrid. So that practice could easily give MSHFlexgrid the control data. Then with one CommandButton button, you give a command like the following:    Private Sub Command1_Click()       MSHFlexGrid1.CellBackColor = vbRed  End Sub            If the program is executed, then the produce is if the user selects the cell in the grid, then the button is pressed then the effect is the cell will change color according to the above statements.       More topic of Mshflexgrid    -. How to Use MSHFlexgrid ?  -. Mshflexgrid with Adodc  -. Editable MSHFlexgrid  -. Attach textbox to MSHFlexgrid  -. Select Single Cell in MSHFlexgrid

Attach textbox to MSHFlexgrid

Gambar
        In this session we will discusses how to utilize MSHFlexgrid which can be edited with the help of the textbox control. Now just open your Visual Basic program. Then create a new project, add MSHFlexgrid control and a textbox control. For example we are setting the grid has 10 rows and 10 columns, then diform form load event add the following command:      Private Sub Form_Load()      MSHFlexGrid1.Rows = 10     MSHFlexGrid1.Cols = 10  End Sub    Later in the event of MSHFlexgrid entercell, give the following command:    Private Sub MSHFlexGrid1_EnterCell()        Text1.Height = MSHFlexGrid1.CellHeight        Text1.Width = MSHFlexGrid1.CellWidth        Text1.Top = MSHFlexGrid1.CellTop + MSHFlexGrid1.Top        Text1.Left...

Editable MSHFlexgrid

        This time we will practice how to control MSHFlexgrid just like excel can be edited, without the help of other components. Whether it can be done by MSHFlexgrid ? The answer is that it can.           Open a new project in VB6 you, then add the control MSHFlexgrid. On the property form KeyPreview = true property setting. Then in the keypress event of MSHFlexgrid add the following:      Private Sub MSHFlexgrid1_KeyPress(KeyAscii As Integer)  Select Case KeyAscii            Case vbKeyReturn, vbKeyTab                    If MSHFlexgrid1.Col + 1                       MSHFlexgrid1.Col = MSHFlexgrid1.Col + 1   ...

Mshflexgrid with Adodc

Gambar
         This time we will discusses how to use control mshflexgrid taking adodc data connection. Suppose you want to display a set of data from Microsoft Access database or other databases, then the way is very easy.            Open your new project. Then add the control mshflexgrid and control addc by right-clicking in the box area component, then add the two control. If you've added, then both the control will be there in a box set of control components. The next step is to add a second control, into a form.  In adodc control, setting the following property:          Right click on the control, then select the tab konection string, select the database we will show. In the above example we take BBLIO existing database in visual basic folder.         Press the Test button to test whether the database co...

How to Use Mshflexgrid

Gambar
        Now we will practice how to use the control Mshflexgrid in a form. Open a new project in VB6, then add Mshflexgrid control and a CommandButton control. Let the names of the control by default.    Type the following code in the CommandButton.    Private Sub Command1_Click()  Dim Nomor(5)  Dim Names(5)  Nomor(1) = "10001"  Nomor(2) = "10002"  Nomor(3) = "10003"  Nomor(4) = "10004"  Nomor(5) = "10005"  Names(1) = "Abraham"  Names(2) = "Pill Collin"  Names(3) = "Collina"  Names(4) = "Stoner"  Names(5) = "Paul"  With MSHFlexGrid1       .Rows = 6       .Cols = 3       .TextMatrix(1, 1) = Nomor(1)       .TextMatrix(1, 2) = Names(1)       .TextMatrix(2, 1) = Nomor(2)       .TextMatrix(...

MSHFLEXGRID

Gambar
        One component in Visual Basic that is often used is MSHFLEXGRID . In the programs that we build applications, components are usually used to display data in the form of columns and rows.          How to add a form control in the way is as follows:  Right-click in the box area components, it will display a number of components vb. Then choose the components that have the name Microsoft Herarchical Flexgrid Contorl 6.0, as shown below.             Once the selected components to be added in the component box, then the next to add falam form to double-click the control mshflexgrid. The result will look like the picture below.              At first glance it appears that the components are the same as the control flexgrid. The difference is highly perceived by contorl flexgrid is i...