+ Reply to Thread
Results 1 to 8 of 8

Import CSV

  1. #1
    Forum Contributor
    Join Date
    09-14-2012
    Location
    mumbai,india
    MS-Off Ver
    Excel 2003
    Posts
    367

    Import CSV

    dear friends,
    i am trying to import csv in excel as required column (cells). Please find the attachment file.
    sorry for my bad english
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,560

    Re: Import CSV

    What is "RL" Col.E in the result?

  3. #3
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,844

    Re: Import CSV

    You have posted an .xlsm file in the VBA forum, suggesting to me that you are expecting a VBA solution. I would first ask -> are you required by some other constraint to use VBA for this? My inclination would be to use Excel's built in "Import External Data from text" command. Your profile says you are using 2003, and I don't remember exactly where that command was found in the menu system. If memory serves, it is in Data->Import External Data->Import from text. (If your profile is wrong and you are using a newer version of Excel, this help file should describe the command https://support.office.com/en-us/art...b-339e391393ba ).

    Once you click on the command button, Excel should bring up a file selector window, select the file which should bring up the text import wizard. Work through the wizard selecting the desired options (which can include ignoring certain columns, since your example does not show importing all columns). At the end, choose the desired data range properties and you are done.

    If this is a task that needs doing frequently, be sure to save the query definition, then future imports will be simple refresh operations.
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  4. #4
    Forum Expert Kenneth Hobson's Avatar
    Join Date
    02-05-2007
    Location
    Tecumseh, OK
    MS-Off Ver
    Office 365, Win10Home
    Posts
    2,573

    Re: Import CSV

    If this is a one time thing, then manual imports as detailed would be best. If many, then a recorded macro would give you something to work with and easily modified.

    For kicks, here is an ADO method. I doubt it will suit your needs since you are not importing all of the fields.
    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    09-14-2012
    Location
    mumbai,india
    MS-Off Ver
    Excel 2003
    Posts
    367

    Re: Import CSV

    Hi Jindon, RL and ELEVATION both are same.

  6. #6
    Forum Contributor
    Join Date
    09-14-2012
    Location
    mumbai,india
    MS-Off Ver
    Excel 2003
    Posts
    367

    Re: Import CSV

    Hello Kenneth Hobson, Thanks for answering, but I am trying to use this code, but it is not working.

  7. #7
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,560

    Re: Import CSV

    I think the suggestion from MrShorty is good enough though...

    Please Login or Register  to view this content.
    Last edited by jindon; 10-15-2017 at 10:24 PM.

  8. #8
    Forum Contributor
    Join Date
    10-02-2008
    Location
    Berkeley, CA
    MS-Off Ver
    Windows 2007
    Posts
    105

    Re: Import CSV

    Downloaded your 2 files. Both the same.

    Re Code, in looking at "Required Format.xlsm",
    when I look at it in Excel there is no code that shows up
    in the VBA module with it.
    Did you forget to include it?

    Mac

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Import Access query results into Excel show import status
    By mwatson4788 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-06-2016, 10:12 AM
  2. [SOLVED] Power Pivot SQL Data Import - How to update import filter
    By minnesotaart in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 10-29-2013, 12:39 PM
  3. Import exvel spreadsheet using a saved import specification
    By dubbdan in forum Access Tables & Databases
    Replies: 1
    Last Post: 08-19-2013, 05:13 PM
  4. Implementing TextFile import Delimiter settings on TXT Import VBA Script
    By Canuckle777 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-19-2013, 02:06 PM
  5. Import Macro sometimes adding data to end of last import
    By himynameisiain in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-30-2013, 07:06 AM
  6. Import CSV with VBA code fails on 2nd import
    By ronhb in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-03-2013, 11:17 PM
  7. Import External Data doesn't import
    By JakeAy in forum Excel General
    Replies: 7
    Last Post: 01-26-2010, 03:58 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