Instead of using / / try splitting with /\s+/,$fti

 

Best Wishes
Matt


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Naresh Bajaj
Sent: Saturday, March 11, 2006 1:49 PM
To: [email protected]
Subject: Removing the blank spaces

 

Hello,
This is my problem. I have extracted one variable value from a file and saved it another fie.
Problem is that it has too many spaces as shown in this example. I want to remove those blank spaces.
If I use split, /  / $fti, I am getting partial results as shown below.
Please let me know how can I remove those spaces.  I appreciated.
Example:
Here is the output saved file looks like:
!  fti =
        240
 
! vtnid =
        16
     
! avntreject=
        On
     
! smtptreject=
        On

----------------------------------------------------------
I want to saved it as shown here
!  fti = 240
! vtnid =16
! avntreject=On
! smtptreject=On    
--------------------------------------------------------
If I use split command,
!  fti =
240

! vtnid =
16

! avntreject=
On

! smtptreject=
On    

I hope I clearly explained the problem. Please let me know if you are not clear about my issue. Thanks,

--
Naresh Bajaj, Intern,
Cardiac Rhythm Disease Management,
Medtronic Inc.,
763-514-3799

_______________________________________________
ActivePerl mailing list
[email protected]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to