Community forum

Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


khanmb1
2008-08-13T18:12:57Z
Hi,
I have jobs that are scheduled based on the number of workdays i.e. excluding weekend and holiday. Following are few examples. Could you please add workday functionality to visualcron?
Thanks
Khan


1. Job run for the first three workdays.
3. Job run on the last workday.
2. Job run 12th, 18th and 25th workday.
Sponsor
Forum information
ErikC
2008-08-15T08:19:53Z
This could be the workday interval:


|--Interval-------------------
|
| Interval: Workdays............Every: x Workday(s)
|


|--Interval-------------------
|
| Interval: Specific workdays of the month............Every : x Month(s)
|
| () Workdays 1-2-3-4-5-6-7-8-9-10......-23 (multi select)
| () Last workday of the month (already exist in specific days of the month)
| () 1st/2nd/3rd/4th/5ft Workday (combo box)
|


P.S. Run job on the last workday already exist and the 25th workday doesn't exist in my calendar 😇
Uses Visualcron since 2006.
pp
2008-09-11T08:40:18Z
That's exactly the function I need to use VisualCrone for our tasks.

When can we expect such a function?
Support
2008-09-11T13:13:23Z
We can't give any dates now because we are loaded with a lot of new functionality in development but all I can say is that it has high priority.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
pp
2009-03-11T09:35:18Z
HI,

are there any news about the workday functionality?
Support
2009-03-12T19:41:14Z
Hi,

we can't give any updates yet regarding this particular functionality.
Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
ErikC
2010-04-23T07:10:55Z
Hi,

I'd like to have the functionality to run jobs at a specific workday of the month. I did a search in this forum and saw this post so I want to put it to your attention again.

Now I need to run a job at the 4th workday of the month at 8PM. I think I'm going to make some external process to make the calculation which day is the 4th workday and run my job the 1st seven days of the month. Than I will run this external process to check if it's the good day and will use a condition to continue or not.

This could be done easier if there is an option to select the good workday.

Hope to see this feature included in the next version 😍.

Regards,
Erik
Uses Visualcron since 2006.
Support
2010-04-23T21:43:15Z
ErikC
2010-04-26T08:32:09Z
Thanks!

I will test this version asap.

In the mean time i will use this code and will use a condition to check the output:

        static void Main(string[] args)
        {   //The 1st day of current month
            DateTime DatePointer = new DateTime(DateTime.Now.Year, DateTime.Now.Month, 1);

            //workday counter
            Int32 WorkdayCounter = 0;

            //Loop until the datepointer is the current date
            do
            {
                if(isWorkday(DatePointer))
                    WorkdayCounter++;          
      
                DatePointer = DatePointer.AddDays(1);
            } while (DatePointer <= DateTime.Today && WorkdayCounter < 23);

            //Amount of workday is max 23, and if today is weekend, it's no workday
            if (WorkdayCounter <= 23 && (isWorkday(DateTime.Now)))
                System.Console.WriteLine(WorkdayCounter.ToString());
            else
                System.Console.WriteLine("-1");
        }

        /// <summary>
        /// check if a date is a workday
        /// </summary>
        /// <param name="chkDate">the date to check</param>
        /// <returns>boolean, true = workday, false != workday </returns>
        static bool isWorkday(DateTime chkDate)
        {
            if(chkDate.DayOfWeek== DayOfWeek.Saturday ||chkDate.DayOfWeek== DayOfWeek.Sunday)
                return false;
            else
                return true;
        }

Regards,
Erik
Uses Visualcron since 2006.
Scroll to Top