Hi all
Being very new to Access I've using massive amounts of Google to develop a database using Access2007 (two screens- one on Access and the other open on Google with an "Access 2007" prefix. Developing software has changed a bit since I last did this 20 years ago!
My application requires a query to produce a set of calculations on stored variables. However, the formulas vary, depending on the recordset (RVCueCard). At the moment I'm using Iif to evaluate which formula to use, based on the RVCueCard_ID:
F1_B: IIf([RVCueCard_ID]=1,((100-[Var_A_B])/100)*([Var_B_B]+[Var_C_B]+[Var_D_B]+[Var_F_B]+[Var_G_B])),IIf([RVCueCard_ID]=3,(((100-[Var_A_B])*[Var_B_B]*[Var_C_B])/100),"CueCard not loaded")
As you can see this is going to become a problem long before I hit the 10(?) entry limit for Iif (as I may end up with hundreds of CueCards!).
What would be ideal would be to store the expression when it is designed with the CueCard, and "drop" it into the query when F1_B is evaluated.
Any ideas on how this could be done?
BTW - in case you missed this earlier - I'm new to this and just figured out how to copy some code into VBA. Please keep it simple
Thanks
Graham