Dcount function

Rather than hardcoding the values for the individual riskcodes and adding them all together, just count the whole set. Someone earlier gave you code for that and you said it worked so I don't understand why you are back to the individual domain functions.
sure, im using it already. i just had to go back to that code just for reference (example) here.
im using >= and <= now
If you want to categorize riskcodes so that they are counted as "minor", "average", and "major" for example, add another column to the riskcode table so you can assign a category to each individual code. Then you join to the riskcode table in your query to pick up the category and use a query to display the three categories - either in a subform as a list or a subform as a crosstab.
yeah, i have a riskcolor field. with text. it gets text depending on the number or riskcode
1712000485315.png

here u can see yellow textbox with text in it (on the left side). its automated. it gets data when a user clicks on one of those 25 buttons.
so i have 2 risk indentifier in table data (code i mean number and text). also that color is just condition formatting. but its hard for me to implement it what u suggest, cause im not that pro in acccess and its simplier and better for me to use the method i know for today well. i can ealisy fix it when i need it to. so i think i need to stick with numeric riskcodes so i can use formulas like dcount easily using numbers only.
 
its automated.
Not if you are using 25 domain functions to fill the boxes. You should be using a subreport bound to a crosstab query. NO DOMAIN functions at all.

Keep in mind that each domain function runs a separate query so you are running 25 queries to produce that grid when you should probably be using a single crosstab.

The running of the domain functions adds up and your form could be sluggish because of all the queries you are running.
 

Users who are viewing this thread

Back
Top Bottom