Formula Hell

J

JB

I have converted an Excel workbook form into an Infopath 2007 form. The
problem I am having is converting a complex excel formula into a Infopath
2007 formula.

Here is the original excel formula:

=IF(ROUNDUP(8*((B4/(B10-1))-TRUNC(B4/(B10-1),0)),0)=0,TRUNC(B4/(B10-1),0),IF(ROUNDUP(8*((B4/(B10-1))-TRUNC(B4/(B10-1),0)),0)=4,TRUNC(B4/(B10-1),0)+0.5,IF(ROUNDUP(8*((B4/(B10-1))-TRUNC(B4/(B10-1),0)),0)=2,TRUNC(B4/(B10-1),0)+0.25,IF(ROUNDUP(8*((B4/(B10-1))-TRUNC(B4/(B10-1),0)),0)=6,TRUNC(B4/(B10-1),0)+0.75,IF(ROUNDUP(8*((B4/(B10-1))-TRUNC(B4/(B10-1),0)),0)=8,1+TRUNC(B4/(B10-1),0),TRUNC(B4/(B10-1),0)+ROUNDUP(8*((B4/(B10-1))-TRUNC(B4/(B10-1),0)),0)/8)))))

The problem I am having is translating the above formula into something
usable in Infopath 2007. I can obviously use 'Round' in Infopath. However,
is there away to use 'IF' and 'TRUNC'? These do not seem to be available in
Infopath 2007.

Could someone attempt to try to translate the above excel formula into an
usable infopath formula?

-jb
 
S

S.Y.M. Wong-A-Ton

It's advisable to write code for this, since the formula is too complex for
InfoPath. Excel is good with numbers, InfoPath is good with XML data; not
calculations.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top