Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid with a SET RELATION TO not working
Message
De
20/03/2002 05:45:54
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00634689
Message ID:
00634839
Vues:
18
>I have a grid connected to a table, TIMESHEET. TIMESHEET is related into 2 tables.
>
>select Timesheet
>set relation to project into project, project+task into tasks
>
>GRID
>column 1 is Timesheet.project
>column 2 is Project.descrip
>column 3 is Timesheet.task
>column 4 is Tasks.descrip
>
>What I want is when I type in a project in column1, project descrip appears, and column4 is blank until I type in a task into column3.
>
>The project.descrip (column 3) is working great, but as soon as I type in a project into column1, the task descrip comes up with a descrip that is not related to the project.
>
>Any ideas?

Frederick,
Directly using tasks.descrip and Project.descrip as controlsources doesn't sound to be feasible (they are needed readonly there, aren't they).
If so try changing controlsources to something like :
column2.Controlsource = ;
  [(iif(seek(TimeSheet.Project,'Project','PrjFKTag'),]+;
  [Project.descrip,''))] 
column4.controlsource = ;
  [(iif(seek(Timesheet.Project+TimeSheet.Task,'Tasks','PrjFKTag'),]+;
  [Tasks.descrip,''))]
This approach doesn't need any relations set.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform