473,800 Members | 2,332 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Spread time accross day

Access 2000 question

Hi any help or advise required if possible

i am trying to create a formula for a field. here is what i have
currently

rem:
IIf(Time()<[Hours]![StartTime],MinToTime(([Hours]*60)),MinToTime ((([Hours]*60))-([Hours]![Non-Productive]*60)-(IIf(Time()>"09 :00:00"
And
Time()<="10:27: 00",(((Time()-[Hours]![StartTime])*24*60)*[Personnel]),IIf(Time()>"1 0:27:00"
And
Time()<="13:30: 00",(((Time()-[Hours]![StartTime])*24*60-12)*[Personnel]),IIf(Time()>"1 3:30:00"
And
Time()<="15:27: 00",(((Time()-[Hours]![StartTime])*24*60-42)*[Personnel]),(((((Time()-[Hours]![StartTime])*24)*60)-54)*[Personnel])))))))

here is it simplified.

i have a table which holds the start/end time for each day, the number
of hours for each day and the number of non-productive hours for the
day.

Our day starts at 09:00 and finishes at 18:00 - Time diff 9 hours.
during this time period there is 1 hours worth of breaks making a
working day of 8 hours per person. for this excise lets say there is
only one person. Now that persons day is made up of 2 hours
non-productive work and 6 hours of productive work.

now what i am trying to achieve is to spread a 6 hour productive
working day over a 9 hour shift, now the breaks are not a problem, but
incorporating the non-productive time over the course of the day, is
doing my head in, i cannot just throw it in at the start or end of the
day i need to account for it thru-out the day

any help would be appreciated

Feb 14 '06 #1
2 1539
sm*******@burbi dge.co.uk wrote:
Access 2000 question

Hi any help or advise required if possible

i am trying to create a formula for a field. here is what i have
currently

rem:
IIf(Time()<[Hours]![StartTime],MinToTime(([Hours]*60)),MinToTime ((([Hours]*60))-([Hours]![Non-Productive]*60)-(IIf(Time()>"09 :00:00"
And
Time()<="10:27: 00",(((Time()-[Hours]![StartTime])*24*60)*[Personnel]),IIf(Time()>"1 0:27:00"
And
Time()<="13:30: 00",(((Time()-[Hours]![StartTime])*24*60-12)*[Personnel]),IIf(Time()>"1 3:30:00"
And
Time()<="15:27: 00",(((Time()-[Hours]![StartTime])*24*60-42)*[Personnel]),(((((Time()-[Hours]![StartTime])*24)*60)-54)*[Personnel])))))))

here is it simplified.

i have a table which holds the start/end time for each day, the number
of hours for each day and the number of non-productive hours for the
day.

Our day starts at 09:00 and finishes at 18:00 - Time diff 9 hours.
during this time period there is 1 hours worth of breaks making a
working day of 8 hours per person. for this excise lets say there is
only one person. Now that persons day is made up of 2 hours
non-productive work and 6 hours of productive work.

now what i am trying to achieve is to spread a 6 hour productive
working day over a 9 hour shift, now the breaks are not a problem, but
incorporating the non-productive time over the course of the day, is
doing my head in, i cannot just throw it in at the start or end of the
day i need to account for it thru-out the day

any help would be appreciated


Perhaps this will help get you started:

http://groups.google.com/group/comp....ed54b162a1aa3c

James A. Fortune
CD********@Fort uneJames.com

Interesting site:
http://www.doityourself.com

Feb 14 '06 #2
Thanks for your help, however my boss finally got it to work, here is
the formula
IIf(Time()<[Hours]![StartTime],MinToTime([Hours]*60-[Non-Productive]*60),+MinToTime (+[Hours]*60-[Non-Productive]*60-DateDiff("n",[StartTime],Time())*[Personnel]+IIf(Time()>"10 :15:00",IIf(Tim e()<"10:27:00", DateDiff("n","1 0:15:00",Time() ),12),0)*[Personnel]+IIf(Time()>"13 :00:00",IIf(Tim e()<"13:30:00", DateDiff("n","1 3:00:00",Time() ),30),0)*[Personnel]+IIf(Time()>"15 :15:00",IIf(Tim e()<"15:27:00", DateDiff("n","1 5:15:00",Time() ),12),0)*[Personnel]))

Feb 15 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1701
by: Gary Herron | last post by:
Hi list, Can someone who has built the SpreadModule on a windows machine please send me the results of the build (or just point me an a binary distribution). Here's why: I'm starting to use the spread library (www.spread.org) in Python via the SpreadModule (http://www.python.org/other/spread/). The
3
2022
by: jim2372 | last post by:
Hello, I work for a very small trading firm. We are thinking of developing our own trading application to automatically make spread trades on the e-cbot platform. We are somewhat unsatisfied with our current application that performs this functionality. We will want a windows-based interface to these trades that provides a Depth of Market view of price activity. This interface will allow one-click trading on a spread ratio that will...
9
3229
by: Bob Achgill | last post by:
I would like to use the timestamp on files to manage the currency of support files for my VB windows application. In this case I would only put the timestamp of the file in the management database and not the file itself. To do this I will need to have a File class property for Create time and date that will let me "set" the Create time and date of the file to my own chooseing. The VB file class does not appear to have the ability
0
1196
by: WStoreyII | last post by:
Hello, I was wondering if there was a way to open a spread sheet up in a windows mdi form. I have tried the spreadsheet control but that does not work because i wish to open up an exisiting spread sheet that i have. How Can this be done? WStoreyII
2
2234
by: RICHARD BROMBERG | last post by:
I wrote a small Access application that accepts a City Name and a Street Name and runs a Query based on them . I want to create an Excel Spread sheet that contains all the matches found by the Query. . Does anyone know how to do this . On a quick and dirty basis I was able to "cut and paste" the query results into an Excel Spread sheet. but thats a little too crude.
5
3188
by: stuart79 | last post by:
I am looking for a code that enables me to open another excel spread sheet while i am in my XL form i have this code - Workbooks.Open Filename:= "OtherFilename.xls" - which opens up the XL spread sheet that i need however my form sits ontop of the xl spread sheet and i am unable to do anything to the spread sheet in the back ground. I need a code which will bring up the other spread sheet and allow me to use it without closing my form?????
2
2689
by: glibo | last post by:
I am trying to change the tab name when i open a excell spread sheet on the run time in c#. I changed it in the code: Response.AddHeader("content-disposition","filename=" + sFileName + ".xls"); But it works only on save mode but on the display mode still display the name of the page i am calling this excell spread sheet, in other words i see Ratings.aspx in url and in the tab name of this excell spread sheet. I need the name i assigned in the...
6
2842
by: Simon | last post by:
Dear reader, I have an Access application which works as back-end and front-end. In case it's running on a local PC it works perfect. If I install it on a server the response time is increasing drastically.
0
1143
by: codewarrior1241 | last post by:
Hi all, I will try to be as clear as possible with my application, maybe ppl familiar with asyncore can help me out :-) Basically, I have python 2.5 in SuSe running with a server written using asynchat. I use it to connect to several clients inside the asyncore.loop construct. This part of the application works fine. However, along with talking to clients through sockets, I need to talk to some Spread groups, obviously using spread. My...
0
9691
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9551
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10035
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9090
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7580
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6813
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4149
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3764
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2945
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.