wanting to create a macro that will give different outputs dependent on an input from a combo box
have tried using 'setvalue' and an IIf statement which says :
IIf([Forms]![xxxxx]![typeselect]="1",DateAdd("d",28,(DateAdd("m",5,[Forms]![xxxxx]![yedate]))),"")
which works fine on its own. If I then use a further 'setvalue' (for the same output field) based on a different selection in the combo box it doesn't work and the original 'setvalue' expression also fails to work
any ideas how i can sort this problem out
do i have to use a single 'setvalue' command and integrate all the options and outputs into one expression ????
Tried to put an expression together for all but it was too large.
I think that what is happening is that the "" empty string is clearing the contents of the output once the macro is complete, is there anyway to run the IIf but if the TRUE part of the statement isn't applicable, to leave the original value in the output as it was????
[This message has been edited by scossar (edited 04-16-2002).]
[This message has been edited by scossar (edited 04-16-2002).]
have tried using 'setvalue' and an IIf statement which says :
IIf([Forms]![xxxxx]![typeselect]="1",DateAdd("d",28,(DateAdd("m",5,[Forms]![xxxxx]![yedate]))),"")
which works fine on its own. If I then use a further 'setvalue' (for the same output field) based on a different selection in the combo box it doesn't work and the original 'setvalue' expression also fails to work
any ideas how i can sort this problem out
do i have to use a single 'setvalue' command and integrate all the options and outputs into one expression ????
Tried to put an expression together for all but it was too large.
I think that what is happening is that the "" empty string is clearing the contents of the output once the macro is complete, is there anyway to run the IIf but if the TRUE part of the statement isn't applicable, to leave the original value in the output as it was????
[This message has been edited by scossar (edited 04-16-2002).]
[This message has been edited by scossar (edited 04-16-2002).]