Improve company productivity with a Business Account.Sign Up

x
?
Solved

combobox in Flex Grid

Posted on 2001-08-17
8
Medium Priority
?
2,111 Views
Last Modified: 2012-08-14
Hello
        I have to view a table record in Flex Grid , The table has a combobox , now i want to view that combobox in the Flex Grid just like the part of cell like we can view in Access. Pleaze tell me how can i do this.
Will be thankfull for ur answer .
0
Comment
Question by:arzoo
  • 4
  • 3
8 Comments
 
LVL 3

Expert Comment

by:andysalih
ID: 6399730
and what about the points ????? 0 points
0
 
LVL 3

Expert Comment

by:andysalih
ID: 6399735
have a look at the code provided on these threads, ive enclosed discriptions aswell. Don't expect a huge responce to your question where you havent posted any points.


THIS IS AN EXAMPLE OF HOW YOU CAN DO A SIMPLE TABLE WITH DATA, SO YOU CAN NOT USE THE FREEFILE() , YOU CAN MAKE MSFLEX GRID, TEXT BOX,COMBO BOX ETC WITH THIS CODE, AND IS SO EASY, TRY IT, PLEASE DONT FORGET TO VOTE FOR ME THANKS.....

http://www.planetsourcecode.com/xq/ASP/txtCodeId.25311/lngWId.1/qx/vb/scripts/ShowCode.htm




Ever wanted to have drop down combo boxes, list boxes, or check boxes in a MS FlexGrid? Well with this code you can now do it. With the code you can see how to do it for your own projects. You can add or take out what you need for your program. All you ne ...(description truncated)(ScreenShot)

http://www.planetsourcecode.com/xq/ASP/txtCodeId.10392/lngWId.1/qx/vb/scripts/ShowCode.htm



With the wsValidate ActiveX-DLL you can validate the user input if a field should lost focus or if the current recordset should change. If you set cancel=true in the 'Validate' event, the input field will not lost focus and the current recordset will not ...(description truncated)

http://www.planetsourcecode.com/xq/ASP/txtCodeId.6582/lngWId.1/qx/vb/scripts/ShowCode.htm
0
 
LVL 3

Accepted Solution

by:
andysalih earned 200 total points
ID: 6399739
this one is exactly what you want


Ever wanted to have drop down combo boxes, list boxes, or check boxes in a MS FlexGrid? Well with this
code you can now do it. With the code you can see how to do it for your own projects. You can add or
take out what you need for your program. All you ne ...(description truncated)(ScreenShot)

http://www.planetsourcecode.com/xq/ASP/txtCodeId.10392/lngWId.1/qx/vb/scripts/ShowCode.htm

have a look at the above link, its even got a screen shot for you to look at, that says it all, combo box in a flexgrid.

full source code provided, so you could build off it.

cheers
Andy
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 1

Expert Comment

by:harsh008_k
ID: 6399755
i will send u code,which i have dine
0
 
LVL 1

Expert Comment

by:harsh008_k
ID: 6399758

pass the gridnaME
Call InitializeGrid(fgrdNAME, 2,4, "cOL hEADER0", "ColHeader1", "ColHeader2", "ColHeader3")

Call SetCellSize(fgrNAME, 2000, 1300, 1000, 1000)

Call PlaceSpecificControlInGridCell(fgrdname, 1, 1, combo1)

'put this in a bas module

Public Sub InitializeGrid(grd As MSFlexGrid, nrows As Integer, ncols As Integer, ParamArray colnames() As Variant)
''To Initialize Flex Grid
Dim i As Integer
With grd
    .Rows = nrows
    .Cols = ncols
    .FixedCols = 0
    .Row = 0
    For i = 0 To UBound(colnames)
    .Col = i
    .Text = colnames(i)
    Next i
End With
End Sub


'this procedure has to be used after InitilizeGrid function
Public Sub SetCellSize(grd As MSFlexGrid, ParamArray size() As Variant)
Dim colcount As Integer
Dim i As Integer
colcount = grd.Cols
With grd
    For i = 0 To UBound(size)
    .Col = i
    .ColWidth(i) = CInt(size(i))
    Next i
End With

End Sub

Public Sub PlaceSpecificControlInGridCell(grd As MSFlexGrid, rowno As Integer, colno As Integer, ctlname As Control)
'this procedure is used to place control in a cell specified in particular column


    With grd
                 If TypeOf ctlname Is Control Then
                    .Row = rowno
                    .Col = colno
                    ctlname.Left = .Left + .CellLeft
                    ctlname.Top = .Top + .CellTop
                    ctlname.Width = .CellWidth
                    If TypeOf ctlname Is CheckBox Or TypeOf ctlname Is OptionButton Then
                        ctlname.BackColor = .BackColor
                    End If
                End If
    End With

End Sub

0
 
LVL 1

Expert Comment

by:harsh008_k
ID: 6399760
*********U have not set the points*******
0
 
LVL 3

Expert Comment

by:andysalih
ID: 6399876
i think he will know that from my first comment !!!
0
 
LVL 9

Expert Comment

by:Valliappan AN
ID: 6400162
Hi, look at this:

http://support.microsoft.com/support/kb/articles/Q201/1/97.asp
(HOWTO: Use a ComboBox to Enter Data into a FlexGrid Control)

Cheers
0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

608 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question