Results 1 to 9 of 9

Removing Quotation from text. (Using EOF)

Threaded View

tjsdndnjs Removing Quotation from text.... 02-10-2015, 09:37 PM
shg Re: Removing Quotation from... 02-10-2015, 10:15 PM
tjsdndnjs Re: Removing Quotation from... 02-10-2015, 11:02 PM
shg Re: Removing Quotation from... 02-10-2015, 11:05 PM
tjsdndnjs Re: Removing Quotation from... 02-11-2015, 01:33 AM
shg Re: Removing Quotation from... 02-11-2015, 01:44 AM
jindon Re: Removing Quotation from... 02-11-2015, 02:13 AM
tjsdndnjs Re: Removing Quotation from... 02-11-2015, 03:07 AM
shg Re: Removing Quotation from... 02-11-2015, 12:32 PM
  1. #1
    Registered User
    Join Date
    10-15-2012
    Location
    Canada
    MS-Off Ver
    Excel 2003
    Posts
    13

    Removing Quotation from text. (Using EOF)

    Hey guys. I am trying to write .txt into excel using VBA.

    This is something I got from the internet. I've attached the text file.

    I am trying to select the first couple of lines which has quotation around them. What can I do to select the lines with quotation and remove them. At the same time, leaving the numeric data lines written on excel.

    Thank you.

    Public Sub textToexcel()
    Dim FilePath As String
    Dim strLine As String
    Dim i As Integer

    Dim lines As Collection
    Set lines = New Collection

    FilePath = "C:\Users\Deepsheit\Desktop\School\lab 5\singleSpecimen.txt"
    Open FilePath For Input As #1

    If Err <> 0 Then
    MsgBox "Not found: " & Filename, vbCritical, "ERROR-GDS"
    Exit Sub
    End If
    i = 1
    While EOF(1) = False
    Line Input #1, strLine
    Cells(i, 1) = strLine
    i = i + 1

    Wend



    End Sub
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Removing double quotation marks from numeric data.
    By Bill Cameron in forum Excel General
    Replies: 1
    Last Post: 03-08-2014, 11:38 AM
  2. Single quotation and VBA pasting as text.
    By mhamlon in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 10-23-2013, 06:15 AM
  3. Replies: 3
    Last Post: 07-29-2013, 08:55 AM
  4. [SOLVED] Removing quotation marks in a txt-file
    By Reedhill in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-28-2006, 03:20 PM
  5. joining text and quotation mark
    By yakuzza in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-11-2005, 08:23 AM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1