Could I know how to get a number under such condition? eg. X=Y+D. when Y=0, X=Y=0, In other words, when Y=0, I want X=0. When Y is non zero number, I need X=Y+D. I'll appreciate help.
yeah its ok, the only way you can start to learn. so basically you could have 3 unbound textboxes on your form. 2 of them would be Y and D, and the 3rd, the result textbox would be X. Name theses textboxes TXTY, TXTX and TXTD. Place a command button on your form, right click the command button, click "build expression" then select "Code Builder".
Place the following code in the area which you're taken to(should be a procedure called "Command1_Click")
if txtY.value = 0 then
TxtX.value = 0
else
txtx.value = txty.value + txtD.value
end if
that will accomplish what you wanted above. let me know how it works.
Hi, expert, Last time I want any digit becomes 0. So I got help from PHV. Indeed the statment (([PackageCount]*[Packages/Case])\10)*10 is very useful.
Now I'd like to have special condition, that is if last digit is 9, I want add 1. For example if it is 999, I want it to be 100. Could someone give me detailed formula for that? Thanks!!!
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.