Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

searching for a file


7 replies to this topic

jesse

jesse
  • Members
  • 7 posts

Posted 10 July 2001 - 21:05

Hi,

During the installation of our product I need to check if a particular file(for ex some db2.exe) is present on the end user's machine. If the file is present I need to perform a particular action. Is there a provision to search for a file. Please let me know. Any help is appreciated.

thanks,
--Jesse


Perotin

Perotin
  • Full Members
  • 407 posts

Posted 11 July 2001 - 10:38

If there is a registry key in
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths
then you have if,
if not, use FindFile(szPath, szFileName, svResult) to find a file in a defined directory (without subdirs), use FindAllFiles (szDir, szFileName, svResult, nOp) to find it in a directory structure (with subdirs)


Ide Nentjes

Ide Nentjes
  • Members
  • 222 posts

Posted 11 July 2001 - 16:13

If you use FindAllFiles, don't forget to use FindAllFiles (szDir, szFileName, svResult, CANCEL)  to release the found files, or else IS will keep them locked while the installation is running.

jesse

jesse
  • Members
  • 7 posts

Posted 11 July 2001 - 18:45

I was not able to find FindAllFiles or FindFile methods in the API documentation for MultiPlatformInstallShield. Could you please tell me in which class I can find that method.

jeremy

jeremy
  • Members
  • 2 posts

Posted 26 July 2001 - 18:02

Im looking for the same thing if you find a way can you post it here, please....

robsahm

robsahm
  • Members
  • 15 posts

Posted 20 December 2001 - 21:58

FindFiles is a IS6 API not a ISMP API.  Look in the API for fileservice.  One of the methods of fileservice has the functionality you need.

jeremy

jeremy
  • Members
  • 2 posts

Posted 21 December 2001 - 14:22

What version of installshield are you using?

robsahm

robsahm
  • Members
  • 15 posts

Posted 21 December 2001 - 19:15

ISMP 4.5