Menu
Forum
General Car Audio
Subwoofers
Speakers
Amplifiers
Head Units
Car Audio Build Logs
Wiring, Electrical and Installation
Enclosure Design & Construction
Car Audio Classifieds
Home Audio
Off-topic Discussion
The Lounge
What's new
Search forums
Gallery
New media
New comments
Search media
Members
Registered members
Current visitors
Classifieds Member Feedback
SHOP
Shop Head Units
Shop Amplifiers
Shop Speakers
Shop Subwoofers
Shop eBay Car Audio
Log in / Register
Forum
Search
Search titles and first posts only
Search titles only
Search titles and first posts only
Search titles only
Log in / Join
What’s new
Search
Search titles and first posts only
Search titles only
Search titles and first posts only
Search titles only
General Car Audio
Subwoofers
Speakers
Amplifiers
Head Units
Car Audio Build Logs
Wiring, Electrical and Installation
Enclosure Design & Construction
Car Audio Classifieds
Home Audio
Off-topic Discussion
The Lounge
What's new
Search forums
Menu
Reply to thread
Forum
Off-topic Discussion
The Lounge
Programming in Perl - Need Some Help
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Message
<blockquote data-quote="qtipextra" data-source="post: 4855878" data-attributes="member: 555270"><p>So I had a DUH moment. I used the function in notepad "find and replace" to clear out all text before the file name, and eliminate "" 2: The system cannot find the file specified." on all lines, so now a line in the log.log looks like this:</p><p></p><p>[CODE]BEEP.SYS" to "C:\UBCD4Win\BartPE\I386\SYSTEM32\DRIVERS\BEEP.SYS[/CODE]</p><p>I also forgot to use the push function to add each element back into the array, so I got back each line in the file.</p><p></p><p>I am, however, still having trouble splitting after the file name. Right now this will display each line in the file, without cutting anything out.</p><p></p><p>My script so far:</p><p></p><p>[CODE]system ("cls") ;</p><p>open( FILE, 'log.log' ) or die( "Cannot open: $!" );</p><p>@log = &lt;FILE&gt; ;</p><p>close (FILE) or die ( "Cannot open: $!" );</p><p>foreach (@log) { </p><p>split ( /M#"#/, $_) ; </p><p>push (@output, $_) </p><p>}</p><p></p><p>print @output ;[/CODE]</p><p>Any Ideas?</p></blockquote><p></p>
[QUOTE="qtipextra, post: 4855878, member: 555270"] So I had a DUH moment. I used the function in notepad "find and replace" to clear out all text before the file name, and eliminate "" 2: The system cannot find the file specified." on all lines, so now a line in the log.log looks like this: [CODE]BEEP.SYS" to "C:\UBCD4Win\BartPE\I386\SYSTEM32\DRIVERS\BEEP.SYS[/CODE] I also forgot to use the push function to add each element back into the array, so I got back each line in the file. I am, however, still having trouble splitting after the file name. Right now this will display each line in the file, without cutting anything out. My script so far: [CODE]system ("cls") ; open( FILE, 'log.log' ) or die( "Cannot open: $!" ); @log = <FILE> ; close (FILE) or die ( "Cannot open: $!" ); foreach (@log) { split ( /M#"#/, $_) ; push (@output, $_) } print @output ;[/CODE] Any Ideas? [/QUOTE]
Insert quotes…
Verification
Post reply
Forum
Off-topic Discussion
The Lounge
Programming in Perl - Need Some Help
Top
Menu
What's new
Forum list