Inventory Rule on a modified date
I need to setup an inventory rule that will give me the modified date of a specific dll file.
The current inventory rule that I am using is : FileInfoReturn(c:\Program Files\SAP\Retail Systems\Point of Sale\JDGEFT.dll, ModifiedDate,2013/04/19) This rule is not working!
I need to know which pc in the organization have this file with this specific modified date. My rule is not working am I doing something wrong?
Answers (2)
Hello,
the documentation about the FileInfoRetun function that you can find at http://www.kace.com/uk/support/resources/kb/article/what-are-the-steps-to-create-a-custom-data-field-inventory tells that the syntax is the following:
FileInfoReturn(string fullPath, string attributeToRetrieve, string valueType)
Three valueTypes are supported "TEXT", "NUMBER", and "DATE". These values determine what kind of sorting/searching you can do. Note that NUMBER is specifically an integer value.
The following list of supported attributes can be retrieved from the FileInfoReport() function.
- Comments
- CompanyName
- FileBuildPart
- ...
So the right syntax in your case should be FileInfoReturn(c:\Program Files\SAP\Retail Systems\Point of Sale\JDGEFT.dll, ModifiedDate,DATE)
If you want to use a comparison condition with a particual date value you may try one of these custom rule functions:
- FileInfoGreaterThan(fullpath, attribute, type, value)
- FileInfoLessThan(fullpath, attribute, type, value)
- FileInfoEquals(fullpath, attribute, type, value)
Kind regards,
StockTrader