473,396 Members | 1,827 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

HOWTO get info from the other colums of the dataset-table used as datasource for a combobox ?

Hi,

I have this combobox which has a table from a dataset as datasource.

When I click an item on the combobox-list , I would like to display (in
textfield) the value from an other column that is present in the table but
is not the ID-column that is connected to toe combobox.datavalue.

How can I do this ?

TIA,
jobi
Nov 20 '05 #1
2 1768
you can write in the combobox selectedindexchanged event.

' assume dataview1 is your datasource for your combobox.
messagebox.show (dataview1(combobox1.selectedindex)("othercolumn") )
as your combobox is binded with some datasource, combobox's selectedindex
property virtually represents the row position of the datasource.
However, it's not necessary to write dataview1 directly in your code. you
can extract it through currencymanager.

Rajesh Patel
"jobi" <jo**@reply2.group> wrote in message
news:bm**********@reader08.wxs.nl...
Hi,

I have this combobox which has a table from a dataset as datasource.

When I click an item on the combobox-list , I would like to display (in
textfield) the value from an other column that is present in the table but is not the ID-column that is connected to toe combobox.datavalue.

How can I do this ?

TIA,
jobi

Nov 20 '05 #2
Thanks for the solution.

jobi
"Rajesh Patel" <rd****@hotmail.com> wrote in message
news:uf**************@TK2MSFTNGP09.phx.gbl...
you can write in the combobox selectedindexchanged event.

' assume dataview1 is your datasource for your combobox.
messagebox.show (dataview1(combobox1.selectedindex)("othercolumn") )
as your combobox is binded with some datasource, combobox's selectedindex
property virtually represents the row position of the datasource.
However, it's not necessary to write dataview1 directly in your code. you
can extract it through currencymanager.

Rajesh Patel
"jobi" <jo**@reply2.group> wrote in message
news:bm**********@reader08.wxs.nl...
Hi,

I have this combobox which has a table from a dataset as datasource.

When I click an item on the combobox-list , I would like to display (in
textfield) the value from an other column that is present in the table

but
is not the ID-column that is connected to toe combobox.datavalue.

How can I do this ?

TIA,
jobi


Nov 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

13
by: Mattias Campe | last post by:
Hi, Depending on if I get an image or a text of a certain URL, I want to do something different. I don't know in advance whether I'll get an image or a text. This is a URL that returns an...
2
by: Giedrius | last post by:
I would like to create a typed dataset, from which I could create such xml document using WriteXML method. Is it possible? ............ <Fields Count=34> <Field Name="name1">value1</Field>...
4
by: Pipo | last post by:
Hi, I fill myDataset from a Excel file. Then I do a myDataset.WriteXML("C:\MyXML.xml") So far everything goes as I want to. But I need a attribute when a node has a value e.g.: I get:
0
by: Bernard Dhooghe | last post by:
In http://www-1.ibm.com/partnerworld/pwhome.nsf/weblook/eac_a_webcast_052504.html the writer says (page 50, Multidimensional Clustering Advisor): " The MDC Advisor feature of the DB2 Design...
1
by: STeve | last post by:
Hi guys, I was wondering how I would go about creating a string array from a single column from a dataset. What I was thinking was iterate through each row in the dataset, finding out the size...
1
by: Dan Sikorsky | last post by:
How do you select records from one dataset and create a second dataset? I need to pull out the master records from a dataset and create a master datagrid in which to embed a details datagrid (for...
1
by: basulasz | last post by:
May be it is a bit easy question but i don't know the way to display data in bounded colums. I get data from DB with a datareader, and I want to display them on bounded colums. I dont want to...
1
by: khalsaiskingraajkaregakhalsa | last post by:
hello all, i m using vb.net.i want to make a crytal report which contains a subreport in the header .the subreport in the header will display class info like class ,class teacher,class monitor...
7
by: Dan Sikorsky | last post by:
How do you iterate thru a dataset to change money fields to a different value? Here's what I have. My dataset is filled directly from a stored procedure. ' Create Instance of Connection and...
3
by: serge calderara | last post by:
Dear all, I have a datagrid erver control which is bind to a dataset. How to display as column name custom text instead of database fields name ? Ex : Started At instead of START_TIME_COL ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.