CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2003
    Location
    Colombia
    Posts
    15

    Thumbs down Simple question

    I am writing to a text file some values wich are separated by ","
    unfortunatly when The file is written the values are encolsed in "
    this realy dose not help me, what could I do?

    Data= 123,123

    open "Data.csv" for ouput as #1
    write #1, Data
    close #1

    the file contains

    "123,123"

    How do I get rid of the "

    THanks
    Santiago

  2. #2
    Join Date
    Dec 2002
    Location
    NC
    Posts
    125
    I ran your code with a few minor sp errors and it worked for me.

    it ends up as a comma seperated value file that is opened by MS Excel.

    Code:
    Private Sub Command1_Click()
    Dim data As String
    data = "123,123"
    
    Open "c:\Data.csv" For Output As #1
    Write #1, data
    Close #1
    
    End Sub
    This and let me know
    R.L.T.W. A+, NET+, CCNA

    doin' my best

  3. #3
    Join Date
    Apr 2002
    Location
    Melbourne, Victoria, Australia
    Posts
    1,792
    Use

    Print #1

    instead of write

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