How to do complicated calculations in a Infopath - InfoPath Dev
in

InfoPath Dev

How to do complicated calculations in a Infopath

Last post 02-27-2006 08:16 PM by Matt Faus. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 02-27-2006 06:13 AM

    • MunmunNath
    • Not Ranked
    • Joined on 02-27-2006
    • United Kingdom
    • Posts 1

    How to do complicated calculations in a Infopath

    Please find attached a screenshot of the time sheet i have developed. As shown in the doc,by checking the checkbox, the text box gets populated with no of working hours and this is added into Total Working hours.When Bank Holiday is selected from dropdown , textbox is again populated but this time it gets added to Total Non Working hours. However i dont know how to set rules so as to decrease the total no of hours when the action is changed , For e.g when Bank holiday is changed to Sick Leave the Total should decrease. But i cant incorporate this functionality. Please suggest some help.


    P.S How to include attachments with a post on this forum ?
  • 02-27-2006 08:16 PM In reply to

    Re: How to do complicated calculations in a Infopath

    Hi Munmun and welcome to the forum!

    The forum doesn't provide attachment functionality, so you would have to upload your image to some webspace and give us a link.

    However, from what you have described you might want to use code to perform the calculations. You could attach whatever calculations you need to execute to the OnAfterChange event of the dropdown. To do this, find the drop-down node in the Data Source task pane, double-click it, switch to the Data Validation tab, choose OnAfterChange from the event handler drop-down and then click Edit Form Code.

    I hope this helps!
    Matt Faus / Microsoft InfoPath MVP
    Qdabra® Software / Streamline data gathering to turn process into knowledge
Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.