PDA

View Full Version : Completely Frustrated With RecordSets



EdB
02-02-2006, 11:27 AM
Does the Mappoint RecordSet object come up short, or is it just me?

Here's my issue. I provide a user with the opportunity to enter an address for me to find. If the results are not found exactly, I pop up the ShowFindDialog. So, they identify their item and Mappoint places a pushpin on the map. It names it based on the item that they selected from the dialog. Now, I need to find out the name of that pushpin.....keeping in mind that there may be other pushpins on the map already, and I do know their names.

I can see the RecordCount of the DataSet in question, but I can not see an Item property on the RecordSet object to cycle through the names of the pushpins on the map and see if the name matches a known name.

I looked to the Fields property and although I have items in the recordset/dataset, fields reports 0.

HELP!!!!!!!!!

EdB
02-02-2006, 09:20 PM
OK, so I figured this out......but the recordset object IS wanting.

Unless I am totally missing something....

if I do this:

objRecordSet = app.ActiveMap.DataSets(1).QueryAllRecords

I need to cycle through the RecordSet using MoveFirst and MoveNext to get the number of records in the recordset.......how about a count property? Is that too much to ask?

Wilfried
02-04-2006, 04:31 AM
Hi,

The result set suport the foreach statement. I think this is also supported in VB. Not sure.