View Single Post
  #3  
Old 11-25-2009, 01:20 PM
ktak ktak is online now
Registered User
 
Join Date: 08-31-2009
Posts: 5
Looking at the SingleInstance example, I am getting incorrect behavior on the step to clear the "stale marker".

The conditional expression for that step is the following:

[DateDiff("h", Now, vbld_ParseFormattedDateTime(vbld_GetFileContents(" E:/scripts/markerfile"))) >1]
(is true)

if the date is over 1 hour it should delete the marker file.


The marker file I am using for this example has this date inside of it:
D20091125T094945

I made sure that the marker file is way older than 1 hour, however the condition didn't evaluate to true.

Afterwards, I entered this line in a run script step to see what dates were getting sent in as parameters for the DateDiff function.

var t = vbld_ParseFormattedDateTime(vbld_GetFileContents(" E:/scripts/markerfile"));
Builder.LogMessage(t);

Surprisingly, I got a time stamp off by a month.
"Fri Dec 25 09:49:45 PST 2009"

I checked my machine to make sure the system clock is correct, and it was.

Is this a bug on VBP?
Reply With Quote