PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV 2024 → Editing Query Results with Windev
Editing Query Results with Windev
Débuté par Steve Erts, 09 juin 2005 00:37 - 1 réponse
Posté le 09 juin 2005 - 00:37
Hi,
I am evaluating Windev using the demo version of V8.
I have built a screen which represents a two table relationship “Demo_Contact” and “Demo_Phone_Numbers”.
The screen contains one record from the table "Demo_Contact" and multiple records from teh table "Demo_Phone_Numbers"
I built the phone number table using a query and passed in the parameter. Worked fine.
What I am having problems with is how to modify the results of the query, i.e. add, modify, or delete phone numbers displayed by the query.
Is this the proper technique for creating such screens, am I missing something?
The help files allude to the fact that the results of a query can be modified, but the examples aren't clicking with me.
Any help would be greatly appreciated.
Posté le 09 juin 2005 - 03:09
Steve
As you will discover there are many ways to achieve the same result in WD.
From what you have written I am not sure you have selected on one of the better ones.
As a direct answer to your question you need to use HAdd(Demo_Phone_Numbers) or HModify(Demo_Phone_Numbers) but there are a number of other requirements that go with these instructions.
Assuming you have a link defined in your analysis then possibly the easiest way to see what is required is to use the RAD tool to build the windows for these tables.
RAD will give you the option to use Procedural, Query or OOP code and the completed windows will give you all (and more) the code you require.
Let me clarify 'easiest' -- you will of course have to go through the code segments and sort out what is necessary, what is nice to have and what is overkill but this will give you a good grounding in the coding methodology.
I do not, by choice, use RAD very much but I did find it very useful for exactly this type of scenario when I first started with WD.
Regards
DerekT