CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2000
    Location
    England
    Posts
    185

    Differences between DOS and UNIX format files

    I need to create a text file in VB that can be read in UNIX. As far as I can see there seems to be a difference between the way the return characters are handled, but does anyone know a way in which I can write the file correctly.

    Thanks

    Andrew


  2. #2
    Join Date
    Oct 2001
    Location
    Phoenix, AZ
    Posts
    54

    Re: Differences between DOS and UNIX format files

    Unix just uses a linefeed character whereas Windows uses a carriage return and line feed. So just terminate the strings you want to line feed in Unix with a vbLf or chr(10). For Macintosh, just use vbCr or chr(13).

    Software is like sex, it's better when it's free - Linus Torvalds
    Software is like sex, it's better when I get paid for it. - me

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured