I need to Unregister and Register many, many DLLs. Directories of DLLs to "Fix" a problem with Crystal Reports 10. I can't find any module that is built for this and I am not asking for code.

My problem is I don't exactly know where to start. The W2K commandline regsrv32 only seems to work on one DLL at a time (that is regsvr32 *.dll doesn't work.) Which is probably safe and smart... Sadly I need neither of those at the moment. Seagate's (the makers of Crystal Reports) advice is basically, see which DLLs come up bad and manually register them. While that is fine advice it looks like about 125 or so DLLs need to be registered. And yes I'd love to not be using this product but it came bundled with a Third Party Vendor's software that my company HAS to use. I need to fix about 5 machines out of 120 which the TPV seems to think is "pretty good".

OK so here's how I see it. I read in the directory all the DLLs then create a commandline to Unregister all of the DLLs then Resgister all the DLLs I read in.

I would backtick ` the command (ie `regsvr32 -u crappycrystal.dll` ; Maybe print it out to a file to read later to see how it went. So there would be some loop.

Here's where things get fuzzy for me. I know how I would do a loop in the until ($foo=0) { way but I have no idea how to loop through all the DLLs. I don't how to tell it is done.

And because I have horrid self doubt I am pretty sure this is a stupid way to do this. So I ask you fellow Monks how would you handle this? And is there a wheel I don't need to reinvent?
--
ell em 52@g mail,com
There's more than one way to do it, but only some of them actually work.

20050114 Edit by castaway: Changed title from 'Resgistering DLLs, lots of them'


In reply to Registering DLLs, lots of them by ellem

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.