Log in

View Full Version : Little Help With SprintDB


Jordan Rosenwald
09-09-2004, 01:21 PM
You'd think this was an easy one, but I keep hitting brick walls.

I want to have one tabbed form that pulls data from mulitiple forms. Basic idea is
Table1 is one reference source
Table2 is a second reference source
Table3 is a third reference source
The tables are not related in any way.

I want to open Form1 and tab1 having focus I see data from Table1. Click on tab2 and I see data from Table2.

I've tried changing the form's RecordSource on the Tab's OnSelChange event by doing an IF PageIndex=1, 2, etc. That didn't work. Even tried the same idea by PageName. Still no good.

Anyone have any ideas?

cnjmorris
09-10-2004, 06:40 PM
What I did was make 3 forms (made 1, and then duplicated controls).

I made it so that clicking on tab loaded new form (CallForm), then unloaded current (CloseForm). With each form tied to one table it works fine. Of course this means any underlying code has to be duplicated also, but I had need of certain things that made this the best option.

I haven't looked at SprintDB in a while, because I decided to order the beta of Visual Studio 2005 and start doing some application design instead of trying to simulate applications in a DB program. Let me look real quick, because I know I did what you are talking about also.

Okay, from their online help it looks like you want a combination of your IF - Then and two seperate Macro Actions.

SetFormSource (MainForm,{"SELECT * FROM Orders WHERE Orders.Customer=&customer_combo"})

RequeryForm(MainForm)

If that doesn't work try setting up predefined queries and then using OpenQuery (Query, DataMode)

Jordan Rosenwald
09-13-2004, 02:44 AM
But that's the basis of my problem. I can't get an OnSelChange event to let me do anything when used with an If statement.