For total records, make the calculation unstored.
AllRepairCost has several problems.
Sum ( Field1 ) is the same as just typing in Field1.
If you want to use Sum to compute the total cost in your portal, define it in the inventory table Sum ( Repairs::Cost ) will total up all the values in cost for all the repair records related to the current inventory record.
You have this expression:
Sum ( Cost ) = Inventory::kp_InvID
Any time you use the equals operator like this, you are comparing the value on the left of the operator with the value on the right. If they are equal, the value returned is 1 (True). If they are not equal the value returned is 0 (False).
If you want to compute the total using a field in Repairs, define AllRepairCost as a summary field that computes the total of Cost. You'll find that this field does not refresh as smoothly and quickly as Sum ( Repairs::Cost )--you may even want to use a script trigger to refresh the window after the cost field is exited if you use this approach.
Yep, all makes perfect sense! Thanks Phil! =)
So tell me, overall how does the solution look so far though to you? Decent?
If you have any suggestions I would love to hear them...
I just took a quick look at the two fields where you had a problem. Haven't looked it over beyond that. I may get time to look at it in more detail later today.
Thanks I would appreciate that. Trying to increase my skills to make my solutions as professional in design as in what they do. So any tips you got as far as functionality, or design, or any tips at all you may have would be greatly appreciated.
Looks pretty good. Most of what I'm commenting on is fairly minor:
Your scripts that use New Window trigger an awkward resize of the parent window on windows systems if the Parent window has been maximized. There's code you can add that checks to see if the current platform is windows and then takes steps to minimize this resize. Likewise, you can check to see if "enlarge window contents to improve visibility" has been checked and can adjust window sizes of pop-up windows accordingly. (This is a Windows only preference, I believe.)
What if a system has two monitors, several printers or more than one HDD? If you defined a portal to "components" you could list a more flexible number and type of system components.
I have a delete portal row script you might want to use. It's 100% portable as it has no layout, field or table specific references, confirms the delete, but doesn't execute if the delete button clicked was located on the bottom blank "add" row of the portal. And the one script can be used for all your portals. (The layout/table/field specific data is passed in a script parameter.)
You can import this script from the Known Bugs List. It also has scripts you can look at for opening new windows that deal with the two issues I've mentioned above.
Downloading the known bugs list now. That script sounds awesome, and thanks for the pointers on the resize. You have no idea how much I appreciate your input on these boards! =)
Hope you had an excellent holiday Phil!