radyofon Posted March 13, 2014 Share Posted March 13, 2014 Merhaba Arkadaşlar, Herhangi bir bat dosyası oluşturup File.Run komutunu kullanmadan aşağıdaki komutları Autoplay Media Studio'da nasıl yazabiliriz? Yardımcı olursanız sevinirim. taskkill /f /im java.exe /T REM Java 2 Runtime Environment Standard Edition v1.3 %systemroot%\IsUninst.exe -f"%SystemDrive%\Program Files\JavaSoft\JRE\1.3\Uninst.isu" -a REM JRE Runtime Environment 6.0 MsiExec.exe /uninstall {3248F0A8-6813-11D6-A77B-00B0D0160000} /passive /norestart REM Remove Java Reg Keys reg delete "HKLM\SOFTWARE\JavaSoft" /va /f REM Remove Java Quick Starter "C:\Program Files (x86)\Java\jre6\bin\jqs.exe" -disable Quote Link to comment Share on other sites More sharing options...
KintaRo Posted March 13, 2014 Share Posted March 13, 2014 biri için örnek vereyim, gerisini sen devam edersin: Shell.Execute("taskkill", "open", "/f /im winamp.exe /T", _SystemFolder, SW_SHOWNORMAL, true) Quote Link to comment Share on other sites More sharing options...
DivaneTR Posted March 13, 2014 Share Posted March 13, 2014 Args = "taskkill /f /im winamp.exe /T" Shell.Execute("cmd.exe", "open", "/C "..Args, _SystemFolder, SW_SHOWNORMAL, true) bu şekilde bir örnek daha açık olacaktır. Cmd üzerinden tüm komutları gönderebilirsiniz. 5. parametreyi SW_HIDE yaparak cmd ekranı görünmeden işlem yaptırabilirsiniz. Quote Link to comment Share on other sites More sharing options...
radyofon Posted March 13, 2014 Author Share Posted March 13, 2014 Niye _SystemFolder da Program Files(x86) değil veya AppData Quote Link to comment Share on other sites More sharing options...
NotToday Posted March 13, 2014 Share Posted March 13, 2014 Niye _SystemFolder da Program Files(x86) değil veya AppData Çalışma konumu o.Cmd.exe _SystemFolder (C:\Windows\System32) bulunduğu klasör yani Quote Link to comment Share on other sites More sharing options...
radyofon Posted March 14, 2014 Author Share Posted March 14, 2014 @KintaRo Üstadım senin yazdığın komutta bir sakatlık var çalışmadı. @DivaneTR' nin yazdığı tamam çalışıyor. Quote Link to comment Share on other sites More sharing options...
KintaRo Posted March 15, 2014 Share Posted March 15, 2014 bence de o daha mantıklı bir yöntem, sorunun çözüldüyse sorun yok ;) Quote Link to comment Share on other sites More sharing options...
radyofon Posted March 17, 2014 Author Share Posted March 17, 2014 Merhaba Arkadaşlar, Aşağıdaki kodları çalıştırınca hata alıyorum. Hata görüntüsü de aşağıdadır. Yardımcı olursanız sevinirim. Args13 = "_ProgramFilesFolder\\JavaSoft\\JRE\\1.3\\Uninst.isu" Args131 = "_ProgramFilesFolder\\JavaSoft\\JRE\\1.3.1\\Uninst.isu" Shell.Execute("IsUninst.exe", "open", " -f", "C:\\Windows\\" ..Args13, SW_HIDE, true); Shell.Execute("IsUninst.exe", "open", " -f", "C:\\Windows\\" ..Args131, SW_HIDE, true); Quote Link to comment Share on other sites More sharing options...
KintaRo Posted March 17, 2014 Share Posted March 17, 2014 "C:\\Windows\\" ..Args13 dersen eğer şu şekilde bir görüntü olur: C:\Windows\C:\Program Files\JavaSoft\JRE\1.3\Uninst.isu Eğer IsUninst.exe Windows klasöründeyse Şu şekilde deneyin: Shell.Execute("IsUninst.exe", "open", " -f " .. Args13, "C:\\Windows", SW_HIDE, true); Quote Link to comment Share on other sites More sharing options...
radyofon Posted March 17, 2014 Author Share Posted March 17, 2014 @KintaRo Üstad komutları şu şekilde düzelttim fakat log file ile ilgili olarak yukarıdaki mesajda resim olarak verdiğim hatayı yine alıyorum. Ayrı bir parametre daha girilmesi gerekiyor galiba. Args13 = _ProgramFilesFolder .."\\JavaSoft\\JRE\\1.3\\Uninst.isu" Args131 = _ProgramFilesFolder .."\\JavaSoft\\JRE\\1.3.1\\Uninst.isu" Shell.Execute("IsUninst.exe", "open", " -f" ..Args13, "C:\\Windows", SW_HIDE, true); Shell.Execute("IsUninst.exe", "open", " -f" ..Args131, "C:\\Windows", SW_HIDE, true); Quote Link to comment Share on other sites More sharing options...
KintaRo Posted March 17, 2014 Share Posted March 17, 2014 -f" ..Args13 buraları birleştirme, arada boşluk bırakman gerekir -f " ..Args13 Ayrıca parametre hakkında bilgim yok sadece syntax'ı düzeltmeye çalışıyorum ben. Quote Link to comment Share on other sites More sharing options...
milano88 Posted March 18, 2014 Share Posted March 18, 2014 (edited) strFolder = _ProgramFilesFolder.."\\JavaSoft\\JRE\\1.3\\Uninst.isu"; strFolder2 = _ProgramFilesFolder.."\\JavaSoft\\JRE\\1.3.1\\Uninst.isu"; sArgs = "\""..strFolder.."\""; sArgs2 = "\""..strFolder2.."\""; Shell.Execute("IsUninst.exe", "open", "-f "..sArgs.." -a", _WindowsFolder, SW_HIDE, true); Shell.Execute("IsUninst.exe", "open", "-f "..sArgs2.." -a", _WindowsFolder, SW_HIDE, true); Edited March 18, 2014 by milano88 Quote Link to comment Share on other sites More sharing options...
Editor pairs Posted March 18, 2014 Editor Share Posted March 18, 2014 IsUninst.exe bu dosyanın yanında log dosyası mevcutmu.Bazı uninstall işlemleri log dosyasını ister. Quote Link to comment Share on other sites More sharing options...
radyofon Posted March 18, 2014 Author Share Posted March 18, 2014 (edited) @pairs Haklısın, log dosyası olmadığından veya log dosyası oluşturamadığından kaynaklanıyor ya da var olan bir log dosyasının adını belirtmediğimizden. Konu Autoplay Media Studio ile değil java ile alâkalı fakat bunu çözmem lâzım. Tüm java versiyonlarını kaldıracak bir program hazırlıyorum ve istenilen java kalsın diye de java'ları v1.3 v1.5 ....v5 v6 v7 diye grupladım. Her ne kadar java 1.3 1.4 1.5 kullanan yoktur ama yine de tüm java versiyonları içerisinde olsun istedim. Edited March 18, 2014 by radyofon Quote Link to comment Share on other sites More sharing options...
radyofon Posted March 19, 2014 Author Share Posted March 19, 2014 (edited) Dos command file' daki aşağıdaki kodu bir türlü ams ile yapamadım. DOS Command REM JRE Runtime Environment 6.0 MsiExec.exe /uninstall {3248F0A8-6813-11D6-A77B-00B0D0160000} /passive /norestart Autoplay Media Studio File.Run(_SystemFolder .. "\\msiexec.exe", " /uninstall" .. {7148F0A8-6813-11D6-A77B-00B0D0142000}, "/passive /norestart", SW_SHOWNORMAL, true); olarak yazdım ama çalışmıyor. Edited March 19, 2014 by radyofon Quote Link to comment Share on other sites More sharing options...
DivaneTR Posted March 19, 2014 Share Posted March 19, 2014 Bu şekilde deneyiniz ; Arg = [[MsiExec.exe /uninstall {3248F0A8-6813-11D6-A77B-00B0D0160000} /passive /norestart]] Shell.Execute("cmd.exe", "open", "/C "..Arg, _SystemFolder, SW_SHOWNORMAL, true) Quote Link to comment Share on other sites More sharing options...
NotToday Posted March 19, 2014 Share Posted March 19, 2014 Neden parametreyi parçaladın ki? Tamamını tırnak içine al.Özel karakterlerin önüne / koyarsan sorun olmaz.Mesela /{7148... gibi Quote Link to comment Share on other sites More sharing options...
radyofon Posted March 19, 2014 Author Share Posted March 19, 2014 (edited) Bu şekilde deneyiniz ; Arg = [[MsiExec.exe /uninstall {3248F0A8-6813-11D6-A77B-00B0D0160000} /passive /norestart]] Shell.Execute("cmd.exe", "open", "/C "..Arg, _SystemFolder, SW_SHOWNORMAL, true) [[ ]] bilmiyordum. Çift parantez neden konuyor? Neden tek değil? Bir de; cmd.exe çalıştırmadan yani command file açmadan msiexec.exe komutu direk çalışmaz mı? Msiexec.exe komutu nihayetinde _SytemFolder içerisinde. Edited March 19, 2014 by radyofon Quote Link to comment Share on other sites More sharing options...
DivaneTR Posted March 19, 2014 Share Posted March 19, 2014 İşe yaradı mı ? Çift tırnak içinde yazılan string olduğu gibi depolanır, o köşeli parantezler olmasa / veya " gibi özel karakterler sıkıntı yaratır. Quote Link to comment Share on other sites More sharing options...
radyofon Posted March 19, 2014 Author Share Posted March 19, 2014 (edited) İşe yaradı mı ? Çift tırnak içinde yazılan string olduğu gibi depolanır, o köşeli parantezler olmasa / veya " gibi özel karakterler sıkıntı yaratır. Yaramaz mı üstadım, hem nasıl!... Kaç gündür bunu yapacağım diye uğraşıyorum. Bir türlü parametreleri ayıramamıştım. Peki, yukarıda belirtmiştim, "cmd.exe" kullanmasak olmaz mı? msiexec.exe zaten system32 içeriinde. Başlangıcını benim yazdığım gibi yapsak nasıl olur? Hatalı mı benim yazdığım script'in başı. Edited March 19, 2014 by radyofon Quote Link to comment Share on other sites More sharing options...
DivaneTR Posted March 19, 2014 Share Posted March 19, 2014 (edited) Sonuçta aynı kapıya çıkıyor, ha cmd.exe çalışmış ha cmd+msiexec. Küçük bir düzenleme ile olacak iş, ilgileniyorum. Edit : Bu şekilde deneyiniz ; Arg = "/uninstall {3248F0A8-6813-11D6-A77B-00B0D0160000} /passive /norestart" Shell.Execute("MsiExec.exe", "open", Arg, "", SW_SHOWNORMAL, false); Edited March 19, 2014 by DivaneTR Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.