|
-
Nov 6th, 2000, 10:27 AM
#1
Thread Starter
Hyperactive Member
Hi there!
I just want to know how to add items to a datagrid column which has the button. (i.e, button property is checked so that combobox is displayed at the column). For eg, let's say for the datagrid column 'prefix', it should have the following 5 values. 1. Mr 2.Mrs 3. Rev 4. Master 5. Dr
How can I do that? Please provide code. I am using ADO.
Thanx in advance.
-
Nov 6th, 2000, 11:42 AM
#2
New Member
Hi..
First at button_click event put the following event:
cboprfx.top= ' you have to populate its position
cboprfx.left= ' you have to populate its position
At combobox click event put the following steps:
datagrid.columns("perfix").text=cboprfx.text
cboprfx.visible=false
-
Nov 15th, 2000, 09:33 AM
#3
Thread Starter
Hyperactive Member
Thanx..but
Hi there!
Thanx for your reply.
I just want to use the built in button that comes with the Datagrid control. Can anyone provide help?
Thanx in advance.
-
Nov 15th, 2000, 11:05 AM
#4
New Member
DataGrid Button
Hello
In the Style tab in propety form of the datagrid select the column you want to put a button to it and then select the checkbox named Button in the bottom of the form. so your column now has a button, and you have also a DataGrid1_ButtonClick(ByVal ColIndex As Integer) event.
select the ColIndex for the column and put the procedure for viewing the combobox. and that is it... enjoy
I hope that i could solve your problem this time.
-
Nov 26th, 2000, 04:18 AM
#5
Thread Starter
Hyperactive Member
Yes, You are right! but...
Hi there!
Thanx for the reply. I just want to know how to show some values, when I click the button. So even before adding any record to the database, I want to display the following values when I click the button.
1.Mr
2.Mrs
3.Dr
4.Master
Hope you understand, what I am asking.
Thanx in advance.
-
Dec 1st, 2000, 02:02 PM
#6
New Member
Hi Jeba
It is too clearly.
In the ButtonClick event put the code to view the List Control.
The List should contains the values you need to view.
then, when the user click on the list to set a value, hide the list and make the cell value equal to the list value.
If it is not cleare replay to me please.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|