Hi.

Im trying to uninstall Communicator 2007, Live Meeting 2007, Live Meeting Outlook Conferencing add-in and then install Lync 2010 or 2013.

The problem I have is closing Outlook 2010 so the Conferenceing add-in can be uninstalled.

Lync 2010 has en exe installer that does all this automagically. But I have also made a vbscripts that does it just as good.

My problem is that when I run this with SCCM Outlook doesn't close, so the Conferencing add-in cant be uninstalled. Same problem with both the script and the Lync 2010 setup exe. When I run them manually everything works just fine.

To me it looks like a permission problems with the system account, but I have tested running both script and exe in a task sequence with my admin accounts and it doesnt make any difference. No errors but Outlook just wont close.

 

What am I missing?

0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Answers

0

Just a thought... could you use pskill.exe in your script to force Outlook to close, and then run the uninstaller?  Doesn't tell you why its failing but maybe a viable workaround?

Answered 05/14/2013 by: bretthexum
Yellow Belt

  • Yes I think so! I have tested taskkill and that works. I have skipped the graceful exit and made a new terminate script and that is working aswell. Looks like SCCM doesnt allow the script i posted earlier.
    I guess no more Mr Niceguy. :)
Please log in to comment
0

Silly question, you did run the advert as Admin?

My VB sucks, but test your script to make sure it terminates other users threads as well.
ie. Outlook.exe thread for me, Outlook.exe thread for you.

Could just be looking for Outlook.exe in the SYSTEM threads.

Is threads even the right word, maybe I should use process, anyway you know what I mean.

Theres another fella here whos really good at VB, so he will be able to help.

Answered 05/13/2013 by: rileyz
Red Belt

Please log in to comment
0

If you mean the Package Program, yes I have that set to "Run with Administrative rights".

I dont know how to set administrative rights on Advertisement?

The problem shouldnt be the VBscript since the EXE from MS has the same problem, right?

Also... there is only one outlook.exe process running as far as I can see. My script and EXE works 100% every time I run them manually, and never when ran through SCCM.

Same clients, same scenarios.

Answered 05/13/2013 by: nizzon
Orange Belt

  • Yeah, Package Program, not advert sorry.

    Re: Process. Start Outlook.exe and yourself, then start it another user so you have 2 proccess of Outlook.exe running. This is to check the the VB can close both process with no problem. This in essence is to check that when running as SYSTEM, it is able to close Outlook.exe processes running as other users. Hope you get what I mean.

    Re: Lync, that exe might just be a wrapper for the MSI. Check the event log for MSI logs, it will tell you if there was anything wrong. I suspect it will be moaning about a process running.

    In the past if I did a upgrade or whatever and use the MSI switch /qn it would just kill the process. Where as if you use /qb (basic GUI) it will prompt the user - you dont want to use /qb, really ugly.

    Your on the right path with the VB though. I friend passed me a VB script for killing IE, will see if I can dig it up tonight when Im home so you can compare.
Please log in to comment
0

I dont really understand how I am supposed to start two Outlook.exe. (Outlook 2010).

I dont want to kill Outlook since it can cause problems with PSTs etc.

Im using this script to close it... (if i understand it right it should close multiple instances)

 

Function IsProcessRunning( strServer, strProcess )
    Dim Process, strObject
    IsProcessRunning = False
    strObject   = "winmgmts://" & strServer
    For Each Process in GetObject( strObject ).InstancesOf( "win32_process" )
 If UCase( Process.name ) = UCase( strProcess ) Then
            IsProcessRunning = True
            Exit Function
        End If
    Next
End Function On Error Resume Next Dim strComputer, strProcess    strProcess = "OUTLOOK.EXE"
   strComputer = "." If( IsProcessRunning( strComputer, strProcess ) = True ) Then Set Outlook = GetObject(, "Outlook.Application")
If Err = 0 Then
Outlook.Session.Logoff
Outlook.Quit()
End If
Else
'MsgBox "Outlook is not running" End If

 

Answered 05/13/2013 by: nizzon
Orange Belt

  • Ohh, your doing a graceful exit, very nice you!

    Re: starting two outlooks. Create UserA and UserB. Login as both to create profiles to clear out no profile issues. Login as UserA and start Outlook as normal. Start the the second outlook as UserB by going to the exe in program files, right click the exe while holding shift. This will allow you to run as diff user. (assumming you are on Win7)

    I guess this will test if it can close another process running outlook as another user.

    Dont know if it will fix your problem though, I was thinking you were killing the process - not graceful exit.

    Plan B: really ugly and takes ages to get compliance, but you could set the advert to run when no user is logged on thru SCCM.
Please log in to comment
0

Still cant open two Outlook.exe, it insists on opening the mail for logged in user.

Would be nice to test this just like you say.

I have actually tried Plan B but ran into some other problems I cant remember right now, will try it again if all else fails. 

Answered 05/13/2013 by: nizzon
Orange Belt

Please log in to comment
Answer this question or Comment on this question for clarity