View Full Version : Find *.jkl files
Unregistered
12-13-2007, 05:20 PM
I need to look for the existance of files in a directory matching a wildcard patten like *.xyz (sadly It looks like most file operations do not support wildcards). In this case I simply need to know if there are any files matching the pattern and I do not need to know any of the filenames. Any ideas?
I'm using SetupBuilder v6.0.1750
andrea
12-18-2007, 08:21 AM
Hello,
Most (99%) of the file functions support wildcards. 1% does not support wildcards because it would not make sense (e.g. Get File Information -> File Version, etc.)
You can use the "Handle File Listing..." script function to do what you want (IMO).
Does this help?
Unregistered
12-18-2007, 02:07 PM
I don't seem to have a "Handle file listing" function. Perhpas that's not available in my version. I'm using SetupBuilder Developer v6.0.1750. In this version, things like "Search for file" do not support wildcards (according to help), yet the help also syays it can return a list of matches. It seems wildcards would be useful here. Does any of the newer versions support wildcards here and what version do I need to use the "Handle File Listing" functions? Thanks,
linder
12-19-2007, 01:02 AM
Hello,
It's not available in 6.0.1750. We introduced it in SetupBuilder 6.6 Build 2016 (October 12, 2007)
The full history list can be obtained through the following link:
www.lindersoft.com/HISTORYSB.TXT
BTW, the function "Search for File" allows you to search for a *specific* file. Wildcards would not make sense here. But the "Handle File Listing" function can do this (including wildcards).
Does this help?
Friedrich
linder
12-19-2007, 01:14 AM
By the way, what you are trying to do looks like this in SB67:
Set Variable %TESTLIST% to FUNCTION:Handle File Listing(Load File List, ) of "c:\7\*.xyz"
Set Variable %COUNT% to FUNCTION:Handle File Listing(Count File List Items)
If %COUNT% Greater Than "0" Then
Display Message Box "%COUNT% File(s) found!" -- ""
End
Friedrich
Unregistered
12-19-2007, 09:08 PM
Yes, that helps, thank you.
linder
12-20-2007, 01:09 AM
You are very welcome!
Friedrich
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.