×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

Tableframe index

Tableframe index

Tableframe index

(OP)
I have a form with 2 tableframes displayed with a 1 to many link. On moving through the master table I should like the records that are displayed in the detail table to be displayed by their secondary index. I thought that the switchindex("xxx") command would work but unless I am attaching it to the wrong object it doesn't. Any ideas please.

Thanks,

Lewy

RE: Tableframe index


You cannot 'switch index' on a tableframe linked to a master table on another index.

Instead, link the two tables by the secondary index.

Or don't link them, and switchindex/setrange on the child table programmatically.

Tony McGuire
"It's not about having enough time; we have the rest of our lives.  It's about priorities."

RE: Tableframe index

(OP)
Wow, that's a quick response, many thanks.

"Or don't link them, and switchindex/setrange on the child table programmatically. " Any clues on how this can be done?

Thanks

Lewy

RE: Tableframe index

Well, no doubt several ways.

uiName.switchindex("index_name")

for starters.  uiName being the name of the child tableframe/object.

'index_name' being the name of the index.

So, if the field name you wish to limit the view of the child was 'machine', you might then

uiName.setrange(masterobjectName."fieldname",masterobjectName."fieldname")

This should place the child table in a restricted view, based on the index name, and with the restriction being the data in the 'fieldname' of the current record of 'masterobjectName' (tableframe?).

I did this with a zip code, phone, city set of tables.  Depending on the field being used to 'search', all tables were switchindex()ed to the appropriate index and then limited with each character typed into the active 'search' field.

This allows 100% flexibility, with the same or better speed Paradox uses when tables are linked.

But there were no linked tables.  Just several secondary indexes on each table.  And each record in the table had a MEANINGLESS integer index; everything was done with secondary indexes.

Tony McGuire
"It's not about having enough time; we have the rest of our lives.  It's about priorities."

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close