NEED HELP!

%3CLINGO-SUB%20id%3D%22lingo-sub-1539745%22%20slang%3D%22en-US%22%3ENEED%20HELP!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1539745%22%20slang%3D%22en-US%22%3E%3CP%3EHello%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20am%20trying%20to%20create%20an%20excel%20workbook%20which%20allows%20me%20to%20enter%20a%20specified%20date%20and%20calculate%20hours.%20Basically%20there%20is%20a%20limit%20to%20working%20days%20within%20a%20month%20that%20i%20can%20use.%20Ex%2021%20days%20in%20aug%20and%20so%20on.%20If%20i%20do%20%3Dnetworkdays%20and%20get%20a%20number%20from%20one%20date%20to%20another%20(7%2F1%2F2020-%206%2F5%2F2021%20is%20243%20days)%2C%20i%20need%20it%20to%20manipulate%20a%20monthly%20breakdown%20to%20give%20me%20allotted%20hours.%20If%20someone%20is%20allotted%2030%20hours%20a%20week%2C%20and%20there%20are%20specified%20working%20days%20(m-f)%20each%20month%2C%20how%20many%20monthly%20hours%20do%20they%20get.%20I%20have%20made%20something%20near%20what%20im%20looking%20for%20but%20i%20want%20to%20type%20in%20a%20start%20and%20end%20date%20and%20have%20it%20manipulate%20the%20Monthly%20hours%20on%20its%20own%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1539805%22%20slang%3D%22en-US%22%3ERe%3A%20NEED%20HELP!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1539805%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F736984%22%20target%3D%22_blank%22%3E%40bbaumann%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIf%20you%20manipulate%20the%20dates%2C%20it%20changes%20the%20monthly%20hours%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1555046%22%20slang%3D%22en-US%22%3ERe%3A%20NEED%20HELP!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1555046%22%20slang%3D%22en-US%22%3E%3CP%3EHello%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F736984%22%20target%3D%22_blank%22%3E%40bbaumann%3C%2FA%3E%26nbsp%3B%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3Efor%20such%20calculations%2C%20Excel%20keeps%20easy-to-use%20time%20intelligence%20functions%20handy.%20The%20formula%20you%20are%20looking%20for%20is%20NETWORKDAYS.INTL%20(%3CA%20href%3D%22https%3A%2F%2Fsupport.microsoft.com%2Fen-us%2Foffice%2Fnetworkdays-intl-function-a9b26239-4f20-46a1-9ab8-4e925bfd5e28%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3ELink%3C%2FA%3E).%20You%20fill%20it%20with%20the%20parameters%20start-%20and%20end-date%2C%20a%20parameter%20for%20the%20weekend%20days%20(1%20for%20Sat%2BSun)%2C%20and%20an%20extra%20parameter%20for%20the%20amount%20of%20public%20holidays%20within%20the%20timeframe.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EFor%20instance%2C%20using%2001.07.2020%20and%2031.07.2020%2C%20Sat%2BSun%20(1)%20and%20no%20public%20holidays%2C%20the%20result%20is%2023%20working%20days.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20that%20the%20function%20you%20are%20looking%20for%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EKind%20regards%3C%2FP%3E%3CP%3EJan%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1558075%22%20slang%3D%22en-US%22%3ERe%3A%20NEED%20HELP!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1558075%22%20slang%3D%22en-US%22%3E%3CP%3EHello%20again%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F736984%22%20target%3D%22_blank%22%3E%40bbaumann%3C%2FA%3E%26nbsp%3B%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20must%20apologize%2C%20I%20failed%20to%20correctly%20look%20into%20your%20file.%20It%20does%20seem%20to%20be%20calculating%20correctly%2C%20but%20apparently%20there%20is%20an%20issue%20with%20the%20field%20value%20formatting.%20Other%20than%20that%20perhaps%20when%20testing%20you%20manipulated%20the%20days%20cutting%20out%20weekends%20and%20the%20number%20of%20working%20days%20stayed%20the%20same%2C%20i.e.%20changing%2031.01.21%20to%2030.01.21%20to%2029.01.21%20will%20get%20you%20the%20same%20result%20since%20the%2030.%20and%2031.01.%20are%20saturday%2Fsunday.%20Anyhow%2C%20I%20solved%20the%20field%20formatting%20issue%20by%20simply%20changing%20the%20G-Column%20(%22Total%20working%20days%22)%20from%20Standard%20to%20Number.%20On%20Standard%20it%20kept%20on%20flipping%20the%20value%20to%20Date%20when%20manually%20recalculating.%20Other%20than%20that%20it%20was%20working%20fine%20for%20me.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EKind%20regards%3C%2FP%3E%3CP%3EJan%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
New Contributor

Hello,

 

I am trying to create an excel workbook which allows me to enter a specified date and calculate hours. Basically there is a limit to working days within a month that i can use. Ex 21 days in aug and so on. If i do =networkdays and get a number from one date to another (7/1/2020- 6/5/2021 is 243 days), i need it to manipulate a monthly breakdown to give me allotted hours. If someone is allotted 30 hours a week, and there are specified working days (m-f) each month, how many monthly hours do they get. I have made something near what im looking for but i want to type in a start and end date and have it manipulate the Monthly hours on its own

3 Replies
Highlighted

@bbaumann 

If you manipulate the dates, it changes the monthly hours

Highlighted

Hello @bbaumann ,

 

for such calculations, Excel keeps easy-to-use time intelligence functions handy. The formula you are looking for is NETWORKDAYS.INTL (Link). You fill it with the parameters start- and end-date, a parameter for the weekend days (1 for Sat+Sun), and an extra parameter for the amount of public holidays within the timeframe.

 

For instance, using 01.07.2020 and 31.07.2020, Sat+Sun (1) and no public holidays, the result is 23 working days.

 

Is that the function you are looking for?

 

Kind regards

Jan

Highlighted

Hello again @bbaumann ,

 

I must apologize, I failed to correctly look into your file. It does seem to be calculating correctly, but apparently there is an issue with the field value formatting. Other than that perhaps when testing you manipulated the days cutting out weekends and the number of working days stayed the same, i.e. changing 31.01.21 to 30.01.21 to 29.01.21 will get you the same result since the 30. and 31.01. are saturday/sunday. Anyhow, I solved the field formatting issue by simply changing the G-Column ("Total working days") from Standard to Number. On Standard it kept on flipping the value to Date when manually recalculating. Other than that it was working fine for me.

 

Kind regards

Jan