Find All Files makes the installer hanging

Got a problem you cannot solve? Try here.
samira
Posts: 21
Joined: Mon Jan 28, 2008 6:48 am

Find All Files makes the installer hanging

Postby samira » Thu May 15, 2014 2:34 am

Hi ,

I have below code in my installer and it makes the whole setup hanging and I noticed the reason is Find All Files.

=========================================================================================================================
if Variable CopyLocalCalc? Equals (Ignore Case) TRUE
Set Variable NATIVE_ENGINE to TRUE
Read from Text File #READALL\$PreviousLocation$\Server\CalcFieldFiles\DefineCompany.cff into Variable CompanyName
Parse String $CompanyName$ into Variables and CompanyName (Split at first occurrence of pattern)
if Variable CompanyName not Equals (Ignore Case) NoCompany
Find All Files in path $PreviousLocation$\Server\CalcFieldFiles\*.cff, write result into variable CustomizedCFF
for each Element EachFile in | delimited Collection of $CustomizedCFF$ do
if Variable EachFile Contains $CompanyName$
Parse String $EachFile$ into Variables CustomizedPath and CustomizedFileName (Split at last occurrence of pattern)
Parse String $CustomizedPath$ into Variables and CustomizedPath (Split at first occurrence of pattern)
Parse String $CustomizedFileName$ into Variables CustomizedFileName and (Split at first occurrence of pattern)
Copy Local Files $CustomizedPath$\$CustomizedFileName$ to $TARGETDIR$\Server\CalcFieldFiles\$CustomizedFileName$
end
next
Copy Local Files $CustomizedPath$\DefineCompany.cff to $TARGETDIR$\Server\CalcFieldFiles\DefineCompany.cff
Set Variable NATIVE_ENGINE to FALSE
end
end
=========================================================================================================================

Can you please advise ?

Thanks
Samira

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Find All Files makes the installer hanging

Postby FrancescoT » Fri May 16, 2014 3:51 am

Dear Samira,

without the possibility to verify your code, it is really difficult to give you an answer.

Anyway, the "Find all Files" can take time to complete its process and this depends on the number of files that are present with the target folder.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

samira
Posts: 21
Joined: Mon Jan 28, 2008 6:48 am

Re: Find All Files makes the installer hanging

Postby samira » Fri May 16, 2014 7:35 am

Hi Francesco,

This is my code :

~InstallAware Clipboard Data~
~End~
~{2374E4B5-4393-45EA-B3B6-FD025E98086F}~
~End~
~{F92CDB72-4B3E-410D-A666-5710F419380D}~
~Copy/Move Local Files~
~{60DD63F3-23EA-4EFA-A8FE-AE299FA9AE58}~
~$CustomizedPath$~
~DefineCompany.cff~
~$TARGETDIR$\Server\CalcFieldFiles~
~DefineCompany.cff~
~TRUE~
~FALSE|FALSE~
~MessageBox~
~{0DB72673-BB19-4B0C-97FF-0DD06AD1C2D8}~
~~
~CustomizedPath=$CustomizedPath$~
~0~
~1~
~~
~MessageBox~
~{2FA102C8-0F49-4E57-9655-0EE99CE0628D}~
~~
~End of loop~
~0~
~1~
~~
~Next~
~{367CE53F-4ADF-47CB-BA57-6E57CD80EE25}~
~End~
~{2ED04391-AD96-4442-BE1C-F7E2D83D6BEA}~
~Copy/Move Local Files~
~{B725A018-C96B-401F-8B92-70ADC49498F5}~
~$CustomizedPath$~
~$CustomizedFileName$~
~$TARGETDIR$\Server\CalcFieldFiles~
~$CustomizedFileName$~
~TRUE~
~FALSE|FALSE~
~MessageBox~
~{C4FC995F-7EFA-4A27-8852-A822944F4970}~
~~
~CustomizedFileName=$CustomizedFileName$~
~0~
~1~
~~
~MessageBox~
~{0343297A-E444-4E60-9511-04308EB89D3E}~
~~
~CustomizedPath=$CustomizedPath$ ~
~0~
~1~
~~
~Parse String~
~{1A0F7D63-79B8-4CFA-904D-D06D7CC14253}~
~$CustomizedFileName$~
~"~
~CustomizedFileName~
~~
~0~
~FALSE~
~TRUE~
~Parse String~
~{F1591714-5A0B-4DEC-AF51-3CDEFA173203}~
~$CustomizedPath$~
~"~
~~
~CustomizedPath~
~0~
~FALSE~
~TRUE~
~Parse String~
~{208D2E78-0D26-4432-8DE6-16B58C7EDB74}~
~$EachFile$~
~\~
~CustomizedPath~
~CustomizedFileName~
~1~
~TRUE~
~TRUE~
~MessageBox~
~{C2CC49CD-C5E0-45AD-AB1E-C3F0F391235E}~
~~
~EachFile=$EachFile$~
~0~
~1~
~~
~If~
~{8857B9E4-8925-40EE-A96B-71907628F101}~
~EachFile~
~1~
~$CompanyName$~
~FALSE~
~For Each~
~{499B99C1-189A-409C-9B4E-A259F2FAC2C2}~
~EachFile~
~|~
~$CustomizedCFF$~
~MessageBox~
~{A1DB4BEE-05FC-49B6-8E9A-54E01BB9845E}~
~~
~CustomizedCFFWithPaths=$CustomizedCFF$~
~0~
~1~
~~
~Find All Files~
~{3669AECC-08BD-4D6C-B0E3-644E740A69CA}~
~$PreviousLocation$\Server\CalcFieldFiles\*.cff~
~FALSE~
~FALSE~
~CustomizedCFF~
~If~
~{75D198AF-12EB-4698-9AA3-43A5D2C7BB7E}~
~CompanyName~
~4~
~NoCompany~
~TRUE~
~MessageBox~
~{39B99FDC-2139-43D6-BEE4-1E725F0CCF7A}~
~~
~CompanyName=$CompanyName$~
~0~
~1~
~~
~Parse String~
~{E41117CC-D221-4A1B-8D33-A8BA4035C473}~
~$CompanyName$~
~=~
~~
~CompanyName~
~0~
~TRUE~
~TRUE~
~Read from Text File~
~{E1F07FC5-B932-4FC5-972F-FD701AD1D769}~
~#READALL\$PreviousLocation$\Server\CalcFieldFiles\DefineCompany.cff ~
~CompanyName~
~~
~If~
~{17C46B2C-72A1-4F28-88B5-CDFC34C9DEFD}~
~CopyLocalCalc?~
~4~
~TRUE~
~FALSE~



Thanks for your help
Samira

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Find All Files makes the installer hanging

Postby FrancescoT » Fri May 16, 2014 11:08 am

Dear Samira,

I didn't mean this ... I can even check your code, but if the command hangs, it may depend on the number of files the command have to parse ....and of course, this can require some time.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

samira
Posts: 21
Joined: Mon Jan 28, 2008 6:48 am

Re: Find All Files makes the installer hanging

Postby samira » Tue May 20, 2014 2:33 am

Dear Francesco,

I don't think it is because the number of files that my installer hangs I tried only with 1 file and waited for 10 mins or more but still it only shows that it is still in find all file !

Thanks
Samira

samira
Posts: 21
Joined: Mon Jan 28, 2008 6:48 am

Re: Find All Files makes the installer hanging

Postby samira » Tue May 20, 2014 7:18 am

Hi ,

I also noticed if I install it with out using find all files and it copies the file from the old location to the new location and then I un-install it and delete the folder and add back find all files command then it doesn't hang so it means it only hangs when the first time it tries to find the file !

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Find All Files makes the installer hanging

Postby FrancescoT » Tue May 20, 2014 10:29 am

Dear Samira,

I can assure you that "Find Files" has nothing to do with your possible issue, instead I see that you are using "Copy/Move local files" command with your code.

When do you execute the code in your setup sequence?

... "Copy/Move local files" is a Windows Installer command and its execution is deferred to Apply Install execution, unless you use the IA NATIVE ENGINE.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE

samira
Posts: 21
Joined: Mon Jan 28, 2008 6:48 am

Re: Find All Files makes the installer hanging

Postby samira » Fri May 30, 2014 8:50 am

Hello

I added message box before and after Find All Files and I can get the message box before it but not the one after it. So I', pretty sure it is hanging there. I have around 20 files in the folder I waited for more than 1 hour but it doesn't return :(

So basically I have sth like this but it doesn't work:

MessageBox: , CustomizedCFF=$CustomizedCFF$
Find All Files in path $PreviousLocation$\Server\CalcFieldFiles\*.cff, write result into variable CustomizedCFF
MessageBox: , CustomizedCFF=$CustomizedCFF$


I changed the location of setting NATIVE_ENGINE to True and din't help

Can you please help me on this issue ?
Thanks
Samira

FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Find All Files makes the installer hanging

Postby FrancescoT » Fri May 30, 2014 11:27 am

Dear Samira,

I just tested the command and I am not able to replicate the same.

I suppose there is something else causing your problem.
Please try with releasing a very minimal project that demonstrates the issue and I'll have a look.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE


Return to “Technical Support”

Who is online

Users browsing this forum: Google [Bot] and 147 guests