Uninstall ActiveX Controls via the command line or other means

s there a way to uninstall ActiveX controls from C:\windows\downloaded program files using the command line to right click the  control to remove it. I need to do this to ~400 machines but not manually. Manually you can right click and select remove. I want to script the removal some how. I need to remove a previous install of authorware web player before installing a new one. It is the only way for the new one to work is uninstalling the old one.
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

You can simulate the action of Internet Explorer by using the same procedure it uses. The procedure is called RemoveControlByName() and is located in occache.dll which normally resides in the system32 directory. You'll need to do a loadLibrary on that.

The procedure's signature is :-

HRESULT RemoveControlByName(LPCTSTR lpszFile,
    LPCTSTR lpszTypeLibID,
    BOOL bForceRemove,
    DWORD dwIsDistUnit

and is documented at MSDN. http://msdn.microsoft.com/en-us/library/aa768173.aspx

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Why don't youpost a real live situation for us nubies that don't speak your language.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Browsers

From novice to tech pro — start learning today.