Batch File is not working correctly

Hey Everyone,
I've got a batch file that I'm trying to get to work and seem to be running into difficulties on getting the whole batch file to work. I'm guessing that I have something missing or incorrect.  What
I'm trying to accomplish is we currently have Java versions 7.0.45 both x64 & x86 platforms installs on all production client machines. My batch file will uninstall the x86 version of Java 7.0.45 and theninstall the
latest version of Java 7.0.51 x86 without any problems. It's the x64 that my batch file is running into problems and does not uninstall it or install the new version of java (7.0.51 x64).
Here's what my batch file looks like:
@ECHO OFF
cls
:KillIE&JavaProcesses
echo *** This will kill Browsers and Java Processes
Rem ***
taskkill /F /IM iexplorer.exe
taskkill /F /IM iexplore.exe
taskkill /F /IM firefox.exe
taskkill /F /IM chrome.exe
taskkill /F /IM jusched.exe
taskkill /F /IM jp2launcher.exe
taskkill /F /IM java.exe
taskkill /F /IM javaw.exe
taskkill /F /IM jqs.exe
rem cd x64
rem msiexec.exe /i jre1.7.0_51.msi /qn AUTOUPDATECHECK=0 JAVAUPDATE=0 JU=0 EULA=1 /NORESTART /log c:\java_7_51_x64_install.log
rem cmd.exe /C rmdir "%PROGRAMDATA%\Microsoft\Windows\Start Menu\Programs\Java" /S/q
rem cd..
cd x86
msiexec.exe /i jre1.7.0_51.msi /qn AUTOUPDATECHECK=0 JAVAUPDATE=0 JU=0 EULA=1 /NORESTART /log c:\java_7_51_x86_install.log
cmd.exe /C rmdir "%PROGRAMDATA%\Microsoft\Windows\Start Menu\Programs\Java" /S/q
The CM 2012 exemgr log shows that the batch file installed successfully. Please help.
Thanks!

Can't really tell without you posting more details. Here are a few pointers:
Don't use relative paths such as CD X86. Use absolute paths instead:
CD F:\X86.
There is no process called "iexplorer.exe". It should be "iexplore.exe".
What is the point of spawning an extra command processor to remove a folder?
Why do you try to delete the Java folder twice?
Did you invoke the batch file from a Console so that you can see the messages it generates?
What were these messages?
Did you run the batch file under elevated admin privileges?
Try this version:
@ECHO OFF
echo *** This will kill Browsers and Java Processes ***
taskkill /F /IM iexplore.exe
taskkill /F /IM firefox.exe
taskkill /F /IM chrome.exe
taskkill /F /IM jusched.exe
taskkill /F /IM jp2launcher.exe
taskkill /F /IM java.exe
taskkill /F /IM javaw.exe
taskkill /F /IM jqs.exe
cd /d "F:\x64"
msiexec.exe /i jre1.7.0_51.msi /qn AUTOUPDATECHECK=0 JAVAUPDATE=0 JU=0 EULA=1 /NORESTART /log c:\java_7_51_x64_install.log
rmdir "%PROGRAMDATA%\Microsoft\Windows\Start Menu\Programs\Java" /S/q
cd /d "F:\x86"
msiexec.exe /i jre1.7.0_51.msi /qn AUTOUPDATECHECK=0 JAVAUPDATE=0 JU=0 EULA=1 /NORESTART /log c:\java_7_51_x86_install.log
rem ??? rmdir "%PROGRAMDATA%\Microsoft\Windows\Start Menu\Programs\Java" /S/q

Similar Messages

  • Test Stand seq w/ dll batch file execution not working

    I am using Test Stand 4.1, running a seq that calls a dll.  The dll contains a batch file execution function that has not been working properly.  I am not 100% sure what the function is as I do not have access to the direct code from which the dll was created.  I believe I have a file, however please remember this is a guess that I am looking at the correct function/file. 
    This is a Pass/Fail test step that calls a batch file.  The batch file runs properly without the use of Test Stand and called by the dll.  In the code that I believe is running, I see there is a step that I am guessing does not run (see below for test steps).  It seems as though these steps are being "stepped over" and not running, however the test does seem to be entering this function.  The test reports a pass/fail status as the data is reported into a txt file.  If the txt file contains the correct data, the test step reports PASS, even though the batchfile does not run.
    :Note:  [batchfile.bat] is the name of the batch file being called; the [ ] are not present 
    // Run Batch File
     ChkErr(LaunchExecutableEx([batchfile.bat] ,windowState,&handle));   
     // Wait for batch file to complete task
     do{
      ProcessSystemEvents();
     }while(!ExecutableHasTerminated (handle));
     RetireExecutableHandle (handle);
    Any one have any suggestions as to why the batch file is not being called and running properly?
    Thank you
    Jason_C

    Thanks for the feed back.  I have realized and it seems as though sometimes the CWD varies.  The current working directory when the batch file does not run seems to be set to the desktop, not to the specified directory.  The batch file is used to program a chip, calling the exe to run using commands.  The file are speciifed by an absolute path, however the exe is not.  The batch file is as below and seems to match up with a problem with the CWD.  How can change though?  I will have to check in the Start in field, but where can I find that property? 
     Thank You
    --Jason
    del ..\misc\mplab.txt
    echo C:\Program Files\JTRS\01_P55461U\bin\uutsw\CR1_T2V3L_PMM_STUB_LOAD.hex
    ..\misc\pm3cmd /5 /BLCC:\Program Files\JTRS\01_P55461U\misc\t2v3l_pmm_stub_load\t2v3l_pmm_stub_load.pm3 /k /m /y /e >> ..\misc\mplab.txt >> ..\misc\mplab.txt
    ..\misc\pm3cmd /5 /BVCC:\Program Files\JTRS\01_P55461U\misc\t2v3l_pmm_stub_load\t2v3l_pmm_stub_load.pm3 >> ..\misc\mplab.txt

  • Lightroom 2.0: Save Metadata to File is not working correctly!

    Hi,
    I have this JPG file with no EXIF data whatsoever but I know it's capture time so I went to "Metadata » Edit Capture Time" and changed the capture time. On Lightroom in the Library module, I can see the capture time but then I save the metadata with "Metadata » Save Metadata to File". However, when I check the file on Windows Explorer, the capture time (or date taken as named by Windows) is not specified at all.
    Why isn't the "Save Metadata do File" working correctly?

    > Ok, this problem was working on only a specific file, so I just re-exported the file and it's all good.
    Exporting to a JPEG and writing metadata to the original JPEG is two different things.
    My experience was that when saving xmp metadata, LR does not create an EXIF section in a file where it was initially missing (And that's a common scenario with scanned film). The date and time information is only stored in the embedded xmp, of which Windows Explorer does not know a thing.
    When exporting your original to a JPEG, that's a completely different thing. You create a new file, rather than modifying your original. SO, Lightroom will create a brand new valid jpeg with a valid exif section and everything.

  • Database file views not working correctly

    I have recently set up an Access database on my local
    coldfusion server. When I go to the application panel and go to the
    'databases' tab, I can see a list of my databases just fine. The
    problem is that, when I open the individual tables of a database
    I've created, the files show up as the path to the file and not the
    file name as it normally should. For example, I'm working through a
    lynda.com tutorial and have build a database called 'teacloud'.
    When I open the teacloud tables in Dreamweaver, they should show
    the individual names of the tables, like the following:
    Products
    ProductTypes
    Reviews
    Users
    UserTypes
    Instead, I get the following:
    C:\CFusionMX7\wwwroot\database\teacloud.Products
    C:\CFusionMX7\wwwroot\database\teacloud.ProductTypes
    C:\CFusionMX7\wwwroot\database\teacloud.Reviews
    C:\CFusionMX7\wwwroot\database\teacloud.Users
    C:\CFusionMX7\wwwroot\database\teacloud.UserTypes
    How do I get rid of the file path structure to where
    Dreamweaver simply shows the Table name only? This is very
    annoying, as it prevents me from being able to see the individual
    table names in many of the functions within Dreamweaver.

    The problem was introduced during the CF 7.01 update. I
    understand that the
    7.02 update fixes the issue.
    Paul Whitham
    Certified Dreamweaver MX2004 Professional
    Adobe Community Expert - Dreamweaver
    Valleybiz Internet Design
    www.valleybiz.net
    "JTuran" <[email protected]> wrote in
    message
    news:f0lhv9$1p9$[email protected]..
    >I have recently set up an Access database on my local
    coldfusion server.
    >When
    > I go to the application panel and go to the 'databases'
    tab, I can see a
    > list
    > of my databases just fine. The problem is that, when I
    open the
    > individual
    > tables of a database I've created, the files show up as
    the path to the
    > file
    > and not the file name as it normally should. For
    example, I'm working
    > through
    > a lynda.com tutorial and have build a database called
    'teacloud'. When I
    > open
    > the teacloud tables in Dreamweaver, they should show the
    individual names
    > of
    > the tables, like the following:
    >
    > Products
    > ProductTypes
    > Reviews
    > Users
    > UserTypes
    >
    > Instead, I get the following:
    >
    > C:\CFusionMX7\wwwroot\database\teacloud.Products
    > C:\CFusionMX7\wwwroot\database\teacloud.ProductTypes
    > C:\CFusionMX7\wwwroot\database\teacloud.Reviews
    > C:\CFusionMX7\wwwroot\database\teacloud.Users
    > C:\CFusionMX7\wwwroot\database\teacloud.UserTypes
    >
    > How do I get rid of the file path structure to where
    Dreamweaver simply
    > shows
    > the Table name only? This is very annoying, as it
    prevents me from being
    > able
    > to see the individual table names in many of the
    functions within
    > Dreamweaver.
    >

  • Standalone PDF file system not working correctly

    I have built a website http://greatayton.wikidot.com/ where one PDF Menu file calls up lots of other PDF files.
    I now want to use the same menu system to call PDF files on a PC hard disk with the Internet turned off.
    I used hyperlinks to link from the PDF Meny to the PDF files.
    This works but first calls up Internet Explorer then displays the actual file which makes the operation slow and unweildy.
    How do I just get the hyperlinks to call up the PDF files?
    Thanks
    Mike

    I have bought Adobe Acrobat X Standard & now works

  • Two Macs Networked, file sharing not working correctly

    Okay, I've had a Mac Pro since February this year and it has been connected to a new iMac since about two days ago. Both computers can see each other on the ethernet network (their respective icons appear in the Finder sidebar). However, something weird is happening because not only are the correct "iMac" and "Mac Pro" icons showing, but also Windows "blue screen of death" icons are appearing also! These icons are named "mac001ffXXXXXXX" where XXXXXXX are a bunch of numbers. I can access the other computer's files by clicking on EITHER the official Mac icons in the sidebar, OR by clicking on the "blue screen of death" icons.
    It should be noted that a Windows XP computer is also a part of this network. I currently have only the AFP sharing option selected (I did have both AFP and SMB, but I disabled SMB because Windows sharing is not really needed), but still the old Windows icon is appearing alongside the iMac icon -- both icons applicable to the iMac.
    I believe this problem is connected to the file sharing issue I am having. While folders I have shared on the iMac can be seen by the Mac Pro, files on the Mac Pro for which I have specified Read and Write guest access to "Everyone" are not visible on the iMac -- the only way to access these files is to log in as a Registered User. I have tried a whole bunch of different things, but nothing seems to work. I was under the impression that communication between two Macs would be completely problem-free!
    So is there something I am missing, or is it a Leopard issue?

    A simple possibility is that you just don't have also have "Personal File Sharing" turned on for the Macs.
    Otherwise, I bet it's on the PC end. Under windows filesharing (SMB), one machine will take control as the server. When there is a PC on the net, the Macs will generally cede that responsibility to the PC Try watching for that in the console log: take all the CPUs off the net, bring a Mac on, then the PC, open the "Console" app on the Mac, and look at the messages. If the problem -is- on the PC end, I'm sorry, but I'm not PC-savvy enough to tell you how to fix it. Hopefully, this will get you closer.

  • File associations not working correctly in Firefox

    Hi,
    I'm using Firefox 3.5.3 on KDE 4.3.2 and have configured Firefox to open files with the "xdg-open" tool. That way you should be able to double-click on files in the download list to open them directly.
    However, Firefox does not use the preferred applications I have chosen in KDE to open a specific type of file. For example it opens whaawmp instead of smplayer for video files.
    When I run xdg-open from a terminal it opens the correct application. Maybe it uses Gnome settings when invoked by Firefox?
    How can I fix this, so that Firefox uses my KDE file-type settings?

    I don't know how to import the KDE mime-types into Firefox but...
    You can change the incorrect associations for filetypes from within Firefox -- from the menu bar select 'Edit > Preferences > Applications'.  Choose the 'Content Type' you wish to change by clicking on it and a dropdown box will appear in the next column.  Then just pick the appropriate program or action.

  • Batch File Naming - not working

    In Automate > Batch... can someone tell me how to make File Naming work? I put in my name info, but PS is ignoring it and saving the new file with the original file name.
    Thx,
    Steven
    OS X 10.4.11 PS 10.0.1 (CS3), 867 MHz PowerPC G4 Quicksilver with 1.5 GB RAM

    SFW is exporting the file and you must either save or close (preferable-and without saving) the original. Therefore you better use Bridge for the renaming part :-)
    I do find the destination section to confusing to0. That is why I record actions with the save as and destination part in it. It is really a peace of cake to select the in the finder and move to other folders, it takes less time then selecting (and/or creating new folders) in the destination section.
    I know everyone has its own way but this is mine. I develop Raw in ACR and finish them in PSCS using various actions for most of the parts, last action sharpens the files and saves them as PSD file in one particular folder. In Bridge I select this files adding metadata and (batch)renaming.
    After this I have several actions for resizing and save as. One is creating 4 different sizes and a SFW version each saved in a predestinated set of folders. I end each batch with closing the file without saving which is leaving the original psd file untouched.
    But as I said, so much photographers so much workflows... :-(

  • Process Multiple Files is not working correctly

    When using Process Multiple Files to resize several images, the resulting files are way too small.  I am resizing to 12"x8" at 150dpi which used to result in about a 2 meg file.  Now the files are about 200k.  Something has changes and I can't find it. Help!

    Hi,
    I don't have access to my ECC 6 system right now, I would check 2 things:
    1) it is possible that the BAdI definition class (for classic BAdIs, it is usually CL_EX_BATCH_MASTER) has been changed manually by SAP, and they removed the LOOP, or have added an EXIT right before the ENDLOOP. I know they sometimes do it.
    2) I would check if the BATCH_MASTER classic BAdI has been migrated to new BAdI, in that case I think you should migrate your BAdI implementations
    3) Just to be sure: if an implementation raises an exception, that's normal that the other implementations are not executed.
    BR
    Sandra

  • File.execute() not working for bat file

    Dear all,
    The purpose of my function copyToWinClipboard (text) is to get a string directly into the Windows Clipboard. The purpose is to allow the user of my project just to paste into the open-dialog of the application EndNote. I’m not certain whether the FM clipboard (supported by the copy/cut/paste methods for Doc) really fills into the Windows Clipboard also.
    In the PhotoShop script forum I found the idea how to do this.
    #target framemaker
    // note the blank in the path
    copyToWinClipboard ("E:\\_DDDprojects\\FM+EN escript\\FM-11-testfiles\\BibFM-collected.rtf");
    function copyToWinClipboard (text) {
      var theCmd, clipFile = new File(Folder.temp + "\\ClipBoardW.bat");
      clipFile.open('w');
    //  theCmd = "echo \"" + text + "\" | clip"; // this doesn’t help either
      theCmd = "echo " + text + " | clip";
      clipFile.writeln (theCmd);
      clipFile.close ();
      clipFile.execute ();
    Running this script provides a short flicker (the command prompt), but the clipboard does not contain the expected string. However, when double clicking on the generated I:\!_temp\ClipBoardW.bat the clipboard is filled correctly.
    IMHO the execute method does not work correctly for bat files. In another area of my project-script i run an exe file with this method correctly.

    Hi Klaus,
    sorry for my late response.
    execute definitely works witch batch-files
    Here's a "batch" - example you can test.
    There are two methods to prevent window from closing:
    "|more" - kind of pagebreak
    "pause"
    var oTemp = app.UserSettingsDir + "\\tmp";
        var MyDosCommand = "ipconfig.exe /a|more";
        var MyPath = new Folder (oTemp);
        if (!oTemp.exists)
            var MyPath = new Folder (oTemp);
            var lFehler = MyPath.create();
        oTemp = oTemp + "\\" +"nw.bat";
        var MyFile = new File (oTemp);
             MyFile.open ('w');
               if (MyFile.error > "")
                    alert("ERROR");
            MyFile.writeln(MyDosCommand);
            MyFile.writeln("pause");
            MyFile.close();
            MyFile.execute();

  • Email pushing not working correctly for office email - 3 seperate devices/carriers

    We switched email hosts several months ago and since our email pushing has not worked correctly. Our host/IT guy has been very unwilling to help me through this (I get the pleasure of being the in-house IT source)
    I personally am on AT&T have no problems with the other 3 emails I have set up on my blackberry. However I receive my work account one time a day at roughly 6:15. Another user is on Alltel and he receives spotty emails throughout the day, but his gmail account comes through instantly. The third user is on nextel and he receives his 2-3 times per day.
    I began to think this was an email host issue since the three of us are all on different carriers, until I found out a fourth user, also on nextel, receives his emails fine.
    Users 1-3 are on Outlook 07 on various versions of the Curve. We have all our messages to stay on the server.
    User 4 is on the older nextel blackberry push to talk, and is not on outlook. 
    We do not have an exchange server. Our emails were all set up through our devices.
    Any suggestions? The answers I have received through our carriers is to make sure that our messages are set to be left on the server. Everyone else at the office has given up - but for me this is the quest for the Holy Grail.......I'm determined find the answer!
    Thank you in advance for any suggestions.
    Caitlin Talbot 

    Potential solution for windows for a side-by-side install. This works for me.
    To setup a firefox install side by side so that links from external programs (like email) can open (so you don't get a "Firefox is already running but is not responding" message) do the following.
    The solution entails the use of the -no-remote switch. Don't use it for the default browser. Use it for the non default browser.
    I'll use firefox 3.6 and firefox 4.0 as examples but this should work for future versions.
    + Install firefox 3.6 and Firefox 4.0 in different directories. Eg.
    C:\Program Files\Mozilla Firefox\firefox.exe
    C:\Program Files\Mozilla Firefox 4\firefox.exe
    + Open profile manager. Start > Run : firefox.exe -ProfileManager
    + In profile manager create Two Profiles.
    firefox3.6
    firefox4
    + In profile manager select firefox 4 as your default (assuming you want to default to the latest) and tick "Don't ask at startup"
    + Create two windows shortcuts.
    * General: Mozilla Firefox 4 (default). Shortcut > Target: "C:\Program Files\Mozilla Firefox 4\firefox.exe". Shortcut > Start In: "C:\Program Files\Mozilla Firefox 4"
    * General: Mozilla Firefox 3.6. Shortcut > Target: "C:\Program Files\Mozilla Firefox\firefox.exe" -p firefox3.6 -no-remote. Shortcut > Start In: "C:\Program Files\Mozilla Firefox"
    That's it. Links from external programs should now open in your default browser.
    Further details see. [http://kb.mozillazine.org/Opening_a_new_instance_of_your_Mozilla_application_with_another_profile Opening a new instance of your Mozilla application with another profile]

  • SSRS 2008 R2/SSRS 2012 Tab Delimited setup is not working correctly in Report Designer

    I have changed a RSReportDesigner.config to add a tab delimited option for report export, but it is not working correctly in vs2008/vs2010 report designer. I get a duplicate of CSV (comma delimited) in the export dropdown list.
    I have tested SSRS 2008 R2/SSRS 2012 on Windows 7 64 bit professional.
    It is working correctly in the report manager.
    <Extension Name="TAB" Type="Microsoft.ReportingServices.Rendering.DataRenderer.CsvReport,Microsoft.ReportingServices.DataRendering">
            <OverrideNames>
                <Name Language="en-US">TAB delimited</Name>
            </OverrideNames>
            <Configuration>
                <DeviceInfo>
                    <FieldDelimiter xml:space="preserve">&#9;</FieldDelimiter>
                    <Encoding>ASCII</Encoding>
                    <UseFormattedValues>False</UseFormattedValues>
                    <NoHeader>False</NoHeader>
                    <FileExtension>TXT</FileExtension>
                </DeviceInfo>
            </Configuration>
          </Extension>

    Hi Dave0323,
    According to your description, you want to export your report into TXT file and change the delimiter to be a Tab. Right?
    In Reporting Services, when exporting to a CSV file, we can change the default field delimiter to any character that we want, including TAB, by changing the device information settings in the configuration file. For example, to use TAB,
    update the FieldDelimiter setting to <FieldDelimiter xml:space="preserve">[TAB]</FieldDelimiter>. And we can change the FileExtension to be TXT if we want to export it into a TXT file. So in this scenario, we just need to modify the configuration
    file like below:
    The result looks like below:
    Reference:
    CSV Device Information Settings
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou

  • Text formatting in Numbers is not working correctly.

    In Numbers on Chrome text formatting is not working correctly, it's almost as if a CSS file is not being loaded. To be precise, when I try to make a cell Bold there is no bolding. I am using Arial as a font. This has been an issue on Mac and Windows. Any ideas?

    Do you have the same problem with Safari or Firefox?

  • Web File manager not working

    The web file manager in NSS322 does not work correctly.  The admin button doesnt work.  I get some limited use when I click compatibility view but not ideal

    Kriss,
    Please call into SBSC @ 1-8866-606-1866 and speak with next available engineer on this issue.
    Thanks
    Jasbryan

  • Share point in server admin not working correctly... I think

    I suspect that the share point in server admin is not working correctly. In workgroup manager when I click on a user and then click on the "home" tab, under the full path field I see a file path of:
    afp://server.mydomain.com/Users
    However if I go to Server Admin -> AFP -> Share Points then click on the Users share and then click on the share point tab below, enable auto mount is disabled. How can this be possible? I thought for a directory to show up in home in workgroup manager it had to be set as an auto mount. Has something possibly corrupted? And what?

    Here's a bit more information about our setup and our experiences with Apple's CUPS implementation:
    On the server, all printer queues are set up with only lpr and ipp sharing enabled with the PPD setting for each printer set to Generic Postscript. We found that setting the PPD to the printer specific one on the server caused problems when clients tried to use printer specific options, like paper tray selection, etc.. The selection would be undone, apparently because the driver on the server would override the previous settings. Using Generic Postscript allows the client PPD settings to go through unmodified. Our printers are general a mix of HP LaserJets and some Sharp Copiers.
    All clients use lpd to the server queues with the printers' actual PPDs configured. Using ipp is superior in that printer feedback (jams, out of toner, etc) makes it back to the clients, but ipp only works when the client, the server, and the printer are on the same network. If the ipp client is not on the same network, the client spooler immediately goes into a paused state and the print job is stuck on the client.
    Using lpd to the server queues works reliably, but there is no feedback to the client. Jobs disappear from the client queue and go to the server, appearing to the user as a successful print. If the printer is down, there's nothing they can see or do about it.

Maybe you are looking for