Using a query result on a form's text box (1 Viewer)

jjake

Registered User.
Local time
Today, 03:47
Joined
Oct 8, 2015
Messages
291
Hi,

I'm using the following query to display total completion % for a project.

Code:
SELECT qryProjectSubSubTaskTotalCount.ProjectSubTaskID, qryProjectSubSubTaskTotalCount.TotalTasks, qryPRojectSubSubTaskCompleteCount.CountOfActualCompletionDate, [CountOfActualCompletionDate]/[TotalTasks] AS TotalPercentage
FROM qryPRojectSubSubTaskCompleteCount RIGHT JOIN qryProjectSubSubTaskTotalCount ON qryPRojectSubSubTaskCompleteCount.ProjectSubTaskID = qryProjectSubSubTaskTotalCount.ProjectSubTaskID;

How would i include this in my forms to show the value for those records in a text box? please see the attached image.
 

Attachments

  • project completion.jpg
    project completion.jpg
    88.8 KB · Views: 32

theDBguy

I’m here to help
Staff member
Local time
Today, 01:47
Joined
Oct 29, 2018
Messages
21,357
Hi. You could try joining your query to the form’s query or use DLookup()?
 

mike60smart

Registered User.
Local time
Today, 08:47
Joined
Aug 6, 2017
Messages
1,899
Hi

If you include the Task Nr in your query for Total %, you could create a Form based on the query and then insert the Form as a Subform
 

jjake

Registered User.
Local time
Today, 03:47
Joined
Oct 8, 2015
Messages
291
Hi

If you include the Task Nr in your query for Total %, you could create a Form based on the query and then insert the Form as a Subform

This worked great. i just made the subform super small to show the one text box and hid everything else
 

Users who are viewing this thread

Top Bottom