Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Binding a specific record

Posted on 2006-06-29
1
Medium Priority
?
178 Views
Last Modified: 2010-04-23
Hi gang!

I am trying to create a control panel type application that gets lists of items and sub-items from a webservice and puts them into a dataset. Then the application parses through them to generate ListViewItems with a two part tags e.g. "CNT:ESP" (so I know what to do when its clicked because some are folders and some are items, the example is "Country" and "Spain").

When called I want to call a specific record into a form so items can be changed but I can't get my head around binding with a key rather than a position... especially as some of forms need to access lookup data via a relationship.

Tables look like this:

GEODATA_CURRENCIES
code (EUR/USD/GBP etc)
name (Euro, US Dollar, British Point etc)

GEODATA_COUNTRIES
code (ESP/USA/GBR)
name (Spain, United States, Great Britain)
currency_code (EUR/USD/GBP lookup)

Say for example my user opens the form and wants to see "Spain", how? The tag for the item s/he opens would be CNT:ESP

Thanks!
setsquare
0
Comment
Question by:setsquare
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 96

Accepted Solution

by:
Bob Learned earned 375 total points
ID: 17010665
You could use a filter with the DataTable's DefaultView:

Dim table As DataTable = ds.Tables(0)
table.DefaultView.RowFilter = "code='USD' "

Bob
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I think the Typed DataTable and Typed DataSet are very good options when working with data, but I don't like auto-generated code. First, I create an Abstract Class for my DataTables Common Code.  This class Inherits from DataTable. Also, it can …
Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…

715 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