Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Parameterized Views...Referencing
Message
De
31/03/1999 09:42:19
 
 
À
30/03/1999 22:59:42
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00203633
Message ID:
00203838
Vues:
15
Erik -

Once again, thanks for the reply. I picked up a lot on your last message. I feel I am getting close!!

After reading your reply, I have a few questions that revolve around the actual setting of the parameter.

First, let me quickly give you background on what I am trying to accomplish, so that my question will make more sense.

I have an "orders" table and an "orders_detail" table and a "products" table. I went to the view designer and created a p-view, using the orders_detail and products table.

My WHERE command in my SQL statment for my view now reads:
WHERE orders_detail.norderid = ?lnorderid

The purpose of the view is so that when I am scrolling through records on my "orders" form, my view (extended_price_detail), which is a grid, will be updated with the appropriate product information for each new record.


OK


The code for my init event of my "orders" form is as follows:

LPARA tnOrderID

IF TYPE("tnOrderID") = "?"
lnorderid = tnOrderID
ELSE
RETURN .F.
ENDIF

REQUERY("extended_price_detail")
__________________________________________________________

My question is, what do I set the variable to so that each time I scroll to a new record on my "orders" form, my grid (p-view) is updated properly.

This question is directly related to the following line of code:

IF TYPE("tnOrderID") = "N"

Would "N" be "THIS.Value" ??? or a range of numbers, such as 1 -999,999,999,999?

I can't set the paramter to a specific number, b/c the view has to be updated for every record that I scroll to. This question is slightly embarrasing, but honestly I don't know what to set the parameter to for the grid to work in harmony with the rest of the form.

TIA for any additional comments

Jason
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform