kalewis Posted May 16, 2006 Share Posted May 16, 2006 I am using FileExists to see if a particular directory exists. I want to use wildcards and the function doesnt seem to support wildcards. What I am doing is seeing if DotNet framework is installed on the computer by searching FileExists(EnvGet("WINDIR") & "\Microsoft.Net\Framework\v2.0*") The wildcard gets ignored. I dont want to hard code this as if the version changes with a service pack or something it will keep re-installing itself. Any ideas or other ways around this? Thanks, Keith Lewis Link to comment Share on other sites More sharing options...
Xenobiologist Posted May 16, 2006 Share Posted May 16, 2006 Hi, don't you think it could be easier to check the registry? So long, Mega Scripts & functions Organize Includes Let Scite organize the include files Yahtzee The game "Yahtzee" (Kniffel, DiceLion) LoginWrapper Secure scripts by adding a query (authentication) _RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...) Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc. MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times Link to comment Share on other sites More sharing options...
kalewis Posted May 16, 2006 Author Share Posted May 16, 2006 I dont know of any registry key that is consistant with what version of framework is installed. Even if there was you would still be stuck on the wildcard. I dont see anything that lets you search a specified registry key with a wildcard. Thanks KAL Link to comment Share on other sites More sharing options...
Developers Jos Posted May 16, 2006 Developers Share Posted May 16, 2006 I dont know of any registry key that is consistant with what version of framework is installed. Even if there was you would still be stuck on the wildcard. I dont see anything that lets you search a specified registry key with a wildcard.ThanksKALUse FileFindFirst()/FileFindNext(), that allows wildcards and check for Directories.... SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
kalewis Posted May 16, 2006 Author Share Posted May 16, 2006 Thank you for this. FileFindFirst worked like a charm. I looked at this but didnt see any mention about directories.KALUse FileFindFirst()/FileFindNext(), that allows wildcards and check for Directories.... Link to comment Share on other sites More sharing options...
Developers Jos Posted May 16, 2006 Developers Share Posted May 16, 2006 (edited) Thank you for this. FileFindFirst worked like a charm. I looked at this but didnt see any mention about directories. KALOften make mistake Just test if its a directory by something like: If StringInStr(FileGetAttrib($Whole-Path-to-File), "D") > 0 Then Edited May 16, 2006 by JdeB SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now