Checking File Date

If you have a new question you’d like our support staff to post a response to, please visit our customer community, Data Security Insiders, to pose the question in our Discussion Boards. We have a thread “Ask Our Tech Experts” that our support team monitors on a regular basis, or you can start a new discussion where other GoAnywhere users and support staff can weigh in. Log in or create your new account at

If you need an immediate response, please create a support ticket or contact our support team by email at [email protected].
2 posts Page 1 of 1


Posts: 1
Joined: Mon Nov 19, 2018 4:00 pm

Post by Malbanese » Tue Dec 31, 2019 12:29 pm
Hello ~ I am trying to have a conditional statement that checks the data of a file and if it does not match the current system date to send me an email, otherwise the file gets SFTP to a vendor. I am having trouble with the syntax that checks the file date.

This is my "IF" condition:

${FileInfo('C:\Program Files\HelpSystems\GoAnywhere\userdata\webdocs\Temp\FULLUPBAL.CSV')}:lastModifiedDate < system.currentDate

Which throws this error:

[8046 - If: ${FileInfo('C:\Program Files\HelpSystems\Go...] Invalid condition syntax in attribute 'condition' of element 'if'. Unrecognizable character '}' found at position '87'.

Any help would be appreciated


User avatar
Posts: 10
Joined: Tue Jul 17, 2018 9:14 am

Post by Support_Jake » Wed Jan 08, 2020 2:51 pm
Your syntax is off just a little bit, and also I think you may be missing a timestamp task in your project. I have attached my XML for your example but most importantly below is the string I ended up using (Please replace with your full file name as mine is just for testing).

IF Condition:
${FileInfo('C:\Users\jacob.przybysz\Desktop\MFT Testing\custsample.csv'):lastModifiedDate < TimestampNow}

Code: Select all
<project name="Check if File edited today" mainModule="Main" version="2.0" logLevel="verbose">

	<module name="Main">

		<print version="1.0">
			<![CDATA[${FileInfo('C:\Users\jacob.przybysz\Desktop\MFT Testing\custsample.csv'):lastModifiedDate}]]>

		<timestamp version="1.0">
			<format outputVariable="TimestampNow" />

		<if condition="${FileInfo(&apos;C:\Users\jacob.przybysz\Desktop\MFT Testing\custsample.csv&apos;):lastModifiedDate &lt;  TimestampNow}" disabled="false">

			<print version="1.0">
				<![CDATA[~~This was edited BEFORE the timestamp was taken~~]]>

			<exitProject version="1.0" />


		<print version="1.0">
			<![CDATA[***This was edited AFTER the timestamp was taken***]]>


Jacob Przybysz
Support Analyst
e. [email protected]
p. 1.800.949.4696
2 posts Page 1 of 1