Jump to content

[SOLVED] How copy & not copy any file(s) ?


Recommended Posts

Posted (edited)

:help:

@ Ricks

@ Everybody

My KO Approach INTL addon is almost ready. But i have few problems. Setup must copy many files whose aren't the same for all languages.

ex: Approach.exe have english for default & native language but don't have a language file (Approach[en_US].xml) in application folder named "locale".

example below (sorry for presentation) :huh: :

D  E  L  E  T  E

After analyzing Rick's Img Burn Intl addon, I try to do my addon like that. But no success. :(

Any idea on how to do that or tricks are welcome.

Thanx.

Edited by Ken@fri
Posted (edited)

OK. This is EXACTLY what i'm trying to have:

xplorer2_Addon.png

And this is my INF file:

;=====================================

; ::_Ken@fri aka Xtr3mnician _:: | 2008 |

;=====================================

;18.09.2008 : 1rst release } <---------- just for me ONLY :)

;

;19.09.2008 : updated --> Fran

Edited by Ken@fri
Posted

Before I advize you on how to do this I want to take the chance to tell you that you can use only one line with taskkill to close more than one program like this

TASKKILL /F /IM xplorer2.exe /IM editor2.exe /T

OK now, let me download the program and I can advize you how to best use Intl strings

  • 1 month later...
Posted (edited)
I tried making sense but I gol lost, only you know what you were trying

I can tell you tho that you are on the right track

@ Rick

I found how to do the job about my xplorer2 lite 1.7.1.4 INTL addon: by using one of your tricks (thanx for that, man) :thumbsup_anim: .


[Version]
Signature="$Windows NT$"

[Optional Components]
xplorer2

[DefaultInstall]
RegisterDLLs=Install.x2

[Install.x2]
11,,rundll32.exe,,,"advpack.dll,LaunchINFSection %01%\%THIS_INF%,Install"

[Install]
BeginPrompt =BeginInsPrompt
EndPrompt =EndInsPrompt
RunPreSetupCommands =Create.i386:1
RunPostSetupCommands=Delete.i386
CopyFiles =snap.Files,THIS_INF.Copy,%LOCALIZE_1%,%LOCALIZE_2%,%LOCALIZE_3% <----- Rick's trick I used
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems =x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut,Hlp.St
artcut,x2.Startcut,Web.Startcut

[BeginInsPrompt]
Title ="::. %Loc_InsTitle% .::"
Prompt ="%Loc_InsPrompt%"
ButtonType=YESNO

[EndInsPrompt]
Prompt="%Loc_EndInsTitle%"

;Creates i386 temp directory and copies install files to it
[Create.i386]
CMD /Q /C MD """%01%\i386""" & COPY /D /Y """%01%\*.cab""" """%01%\i386"""

; Deletes i386 temp directory after install is complete
[Delete.i386]
RUNDLL32 advpack.dll,DelNodeRunDLL32 %01%\i386,8

[xplorer2]
OptionDesc ="xplorer2 lite"
Tip ="%APP_TIP%"
Modes =0,1,2,3
CopyFiles =snap.Files,%LOCALIZE_1%,%LOCALIZE_2%,%LOCALIZE_3%
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems=x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut
,Hlp.Startcut,x2.Startcut,Web.Startcut

[SourceDisksNames.x86]
1="xplorer2 lite Files","xplorer2.cab",,"I386"

[DestinationDirs]
snap.Files =16422,"%SNAP%"
DefaultDestDir=16422,"%PATH_X2%"
THIS_INF.Copy =17
PNF.File =17

[SourceDisksFiles]
de_ed2t1.txt=1
de_ed2t2.txt=1
%Editor2%=1
%loc0%x2t.dll=1
%loc1%ed2t.dll=1
%loc%x2hlp.htm=1
%Registry%=1
%tip_rtf%x2tip.rtf=1
%tip_txt%x2tip.txt=1
;- IMGS -
%loc%accel.png=1
%loc%altK.png=1
%loc%args.png=1
%loc%atrib.png=1
%loc%axpre.png=1
%loc%batch.png=1
%loc%ccf.png=1
%loc%ckat.png=1
%loc%cnsol.png=1
%loc%cpyto.png=1
%loc%dvbar.gif=1
%loc%dupe.png=1
%loc%epud.gif=1
%loc%find.png=1
%loc%grep.png=1
%loc%hiera.gif=1
%loc%katx.png=1
%loc%licer.png=1
%loc%maex.png=1
%loc%main.png=1
%loc%make.png=1
%loc%next.gif=1
%loc%ordef.png=1
%loc%org.png=1
%loc%play.gif=1
%loc%prev.gif=1
%loc%regi.png=1
%loc%rule.png=1
%loc%skrap.png=1
%loc%split.png=1
%loc%sync.png=1
%loc%scres.png=1
%loc%tibar.gif=1
%loc%tno.gif=1
%loc%trops.png=1
%loc%tyep.gif=1
%loc%uncas.png=1
%loc%up.gif=1
;----
changes.txt=1
ed2t.exe=1
ed2t.man=1
licence.txt=1
x2Edit.exe=1
x2help.css=1
x2lite.exe=1
x2lite.man=1
x2skin.bmp=1
x2skinBW.bmp=1

[snap.Files]
accel.png,%loc%accel.png
altK.png,%loc%altK.png
args.png,%loc%args.png
attrib.png,%loc%atrib.png
axpre.png,%loc%axpre.png
batch.png,%loc%batch.png
ccf.png,%loc%ccf.png
ckat.png,%loc%ckat.png
consol.png,%loc%cnsol.png
copyto.png,%loc%cpyto.png
drivebar.gif,%loc%dvbar.gif
dupe.png,%loc%dupe.png
epud.gif,%loc%epud.gif
find.png,%loc%find.png
grep.png,%loc%grep.png
hiera.gif,%loc%hiera.gif
katx.png,%loc%katx.png
licer.png,%loc%licer.png
maex.png,%loc%maex.png
mainfr.png,%loc%main.png
make.png,%loc%make.png
next.gif,%loc%next.gif
ordef.png,%loc%ordef.png
org.png,%loc%org.png
play.gif,%loc%play.gif
prev.gif,%loc%prev.gif
regi.png,%loc%regi.png
rule.png,%loc%rule.png
skrap.png,%loc%skrap.png
split.png,%loc%split.png
sync.png,%loc%sync.png
syncres.png,%loc%scres.png
titlebar.gif,%loc%tibar.gif
tno.gif,%loc%tno.gif
trops.png,%loc%trops.png
tyep.gif,%loc%tyep.gif
uncas.png,%loc%uncas.png
up.gif,%loc%up.gif

[THIS_INF.Copy]
xplorer2.inf

[Nothing]

[Default]
xplorer2_lite.exe.manifest,x2lite.man
changes.txt
editor2.exe,ed2t.exe
editor2.exe.manifest,ed2t.man
licence_free.txt,licence.txt
Editor2.txt
registry.txt
x2help.htm,%loc%x2hlp.htm
x2help.css
x2SettingsEditor.exe,x2Edit.exe
xplorer2_lite.exe,x2lite.exe
;Visterish skin made by FMG ---(Feel free to remove it too)
x2skin.bmp
x2skinBW.bmp
x2tips.rtf,%tip_rtf%x2tip.rtf
x2tips.txt,%tip_txt%x2tip.txt

[Translate_1]
xplorer2_lite.exe.manifest,x2lite.man
changes.txt
editor2.exe,ed2t.exe
editor2.exe.manifest,ed2t.man
licence_free.txt,licence.txt
x2help.css
x2SettingsEditor.exe,x2Edit.exe
xplorer2_lite.exe,x2lite.exe
x2skin.bmp
x2skinBW.bmp
%x2t_intl%,%loc0%x2t.dll
%ed2t_intl%,%loc1%ed2t.dll
x2tips.rtf,%tip_rtf%x2tip.rtf
x2tips.txt,%tip_txt%x2tip.txt
x2help.htm,%loc%x2hlp.htm
%Editor2%
%Registry%

[Translate_2]
xplorer2_lite.exe.manifest,x2lite.man
changes.txt
editor2.exe,ed2t.exe
editor2.exe.manifest,ed2t.man
licence_free.txt,licence.txt
x2help.css
x2SettingsEditor.exe,x2Edit.exe
xplorer2_lite.exe,x2lite.exe
x2skin.bmp
x2skinBW.bmp
%x2t_intl%,%loc0%x2t.dll
%ed2t_intl%,%loc1%ed2t.dll
x2tips.rtf,%tip_rtf%x2tip.rtf
x2tips.txt,%tip_txt%x2tip.txt
x2help.htm,%loc%x2hlp.htm
%Registry%
Editor2-GE-01a.txt,de_ed2t1.txt
Editor2-Nutzung-01a.txt,de_ed2t2.txt

[Translate_3]
xplorer2_lite.exe.manifest,x2lite.man
changes.txt
editor2.exe,ed2t.exe
editor2.exe.manifest,ed2t.man
licence_free.txt,licence.txt
x2help.css
x2SettingsEditor.exe,x2Edit.exe
xplorer2_lite.exe,x2lite.exe
x2skin.bmp
x2skinBW.bmp
%x2t_intl%,%loc0%x2t.dll
x2tips.rtf,%tip_rtf%x2tip.rtf
x2tips.txt,%tip_txt%x2tip.txt
x2help.htm,%loc%x2hlp.htm
%Editor2%
%Registry%

@ Everybody

But now, I'm trying to do that by another way. You can see below the script I wrote. In this 2nd solution, i'd like xplorer2 lite installation finds the right location of XPLORER2.CAB and goes silently, without user prompt. Until now,none solution. Only DefaultInstall section goes fine. Any ideas ??


[Version]
Signature="$Windows NT$"

[DefaultInstall]
RegisterDLLs=Install.x2

[Install.x2]
11,,rundll32.exe,,,"advpack.dll,LaunchINFSection %01%\xplorer2.inf,Install.%LANG%"

[Install.ENU]
BeginPrompt =BeginInsPrompt
EndPrompt =EndInsPrompt
RunPreSetupCommands =Create.i386:1
RunPostSetupCommands=Delete.i386
CopyFiles =x2.Files,snap.Files,@xplorer2.inf
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems =x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut,Hlp.St
artcut,x2.Startcut,Web.Startcut

[Install.DEU]
BeginPrompt =BeginInsPrompt
EndPrompt =EndInsPrompt
RunPreSetupCommands =Create.i386:1
RunPostSetupCommands=Delete.i386
CopyFiles =x2.Files,x2.Localized.Files,x2.Files.DEU,snap.Files,@xplorer2.inf
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems =x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut,Hlp.St
artcut,x2.Startcut,Web.Startcut

[Install.INT]
BeginPrompt =BeginInsPrompt
EndPrompt =EndInsPrompt
RunPreSetupCommands =Create.i386:1
RunPostSetupCommands=Delete.i386
CopyFiles =x2.Files,x2.Localized.Files,snap.Files,@xplorer2.inf
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems =x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut,Hlp.St
artcut,x2.Startcut,Web.Startcut

[Install.PTB]
BeginPrompt =BeginInsPrompt
EndPrompt =EndInsPrompt
RunPreSetupCommands =Create.i386:1
RunPostSetupCommands=Delete.i386
CopyFiles =x2.Files,x2.Files.PTB,snap.Files,@xplorer2.inf
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems =x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut,Hlp.St
artcut,x2.Startcut,Web.Startcut

[BeginInsPrompt]
Title ="::. %Loc_InsTitle% .::"
Prompt ="%Loc_InsPrompt%"
ButtonType=YESNO

[EndInsPrompt]
Prompt="%Loc_EndInsTitle%"

[Create.i386]
CMD /Q /C MD """%01%\i386""" & COPY /D /Y """%01%\*.cab""" """%01%\i386"""

[Delete.i386]
RUNDLL32 advpack.dll,DelNodeRunDLL32 %01%\i386,8

[Optional Components]
xplorer2

[xplorer2]
OptionDesc ="xplorer2 lite"
Tip ="%X2_TIP%"
Modes =0,1,2,3
RegisterDLLs =x2.InstallNow <-------- 1rst TEST (setup starts at T-23)
;AddReg =x2.RunOnce <-------- 2nd TEST (setup starts at T-13)

;[x2.RunOnce]
;HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce","xplorer2 lite",,"rundll32.exe advpack.dll,LaunchINFSection xplorer2.inf,Launch.x2.Install"

;[Launch.x2.Install]
;RunPostSetupCommands=x2.InstallNow

[x2.InstallNow]
;rundll32.exe advpack.dll,LaunchINFSection %17%\xplorer2.inf,Install.x2.%LANG% |
;rundll32.exe advpack.dll,LaunchINFSectionEx %01%\i386\xplorer2.inf,Install.x2.%LANG%,%01%\i386\xplorer2.cab,4,N | <---- What's the correct command ???
;rundll32.exe advpack.dll,LaunchINFSectionEx %17%\xplorer2.inf,Install.x2.%LANG%,%01%\i386\xplorer2.cab,4,N |

11,,rundll32.exe,,,"advpack.dll,LaunchINFSectionEx %17%\xplorer2.inf,Install.x2.%LANG%,%01%\i386\xplorer2.cab,4,N" |

[Install.x2.ENU]
CopyFiles =x2.Files,snap.Files
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems=x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut
,Hlp.Startcut,x2.Startcut,Web.Startcut

[Install.x2.DEU]
CopyFiles =x2.Files,x2.Localized.Files,x2.Files.DEU,snap.Files
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems=x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut
,Hlp.Startcut,x2.Startcut,Web.Startcut

[Install.x2.INT]
CopyFiles =x2.Files,x2.Localized.Files,snap.Files
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems=x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut
,Hlp.Startcut,x2.Startcut,Web.Startcut

[Install.x2.PTB]
CopyFiles =x2.Files,x2.Files.PTB,snap.Files
AddReg =x2.Settings.AddReg,Uninstall.AddReg
DelReg =Organiz.Start.Menu
ProfileItems=x2.Deskcut,x2.Quickcut,ed2t.Quickcut,Editor2.Startcut,ed2t.Startcut
,Hlp.Startcut,x2.Startcut,Web.Startcut

[SourceDisksNames.x86]
1="xplorer2 lite Files","xplorer2.cab",,"I386"

Where i'm wrong below (the correct command please) :

[xplorer2]

OptionDesc ="xplorer2 lite"

Tip ="%X2_TIP%"

Modes =0,1,2,3

RegisterDLLs =x2.InstallNow <-------- 1rst TEST (setup starts at T-23)

;AddReg =x2.RunOnce <-------- 2nd TEST (setup starts at T-13)

;[x2.RunOnce]

;HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce","xplorer2 lite",,"rundll32.exe advpack.dll,LaunchINFSection xplorer2.inf,Launch.x2.Install"

;[Launch.x2.Install]

;RunPostSetupCommands=x2.InstallNow

[x2.InstallNow]

;rundll32.exe advpack.dll,LaunchINFSection %17%\xplorer2.inf,Install.x2.LANG% |

;rundll32.exe advpack.dll,LaunchINFSectionEx %01%\i386\xplorer2.inf,Install.x2.%LANG%,%01%\i38\xplorer2.cab,4,N

;rundll32.exe advpack.dll,LaunchINFSectionEx %17%\xplorer2.inf,Install.x2.%LANG%,%01%\i386\xplorer2.cab,4,N

Edited by Ken@fri
Posted

Why do you use so many strings in your inf? Especially in source disk files section???

%loc%ckat.png=1

What does that mean? Where is your strings section buddy :P

ANd use codebox next time, this way the page is tooo big to display :S

Waiting for your response. Please remove those %%'s from [sourceDisksFiles] and file copy sections. I didnt see a coding like this before ;)

  • 2 months later...
Posted
Why do you use so many strings in your inf? Especially in source disk files section???

%loc%ckat.png=1

What does that mean? Where is your strings section buddy :P

ANd use codebox next time, this way the page is tooo big to display :S

Waiting for your response. Please remove those %%'s from [sourceDisksFiles] and file copy sections. I didnt see a coding like this before ;)

FIXED :thumbsup_anim: . See HERE

Thanx 4 ur help & advices. :worthy:

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...