+ Reply to Thread
Results 1 to 12 of 12

Change Multiple Columns to TEXT Data Type

  1. #1
    Registered User
    Join Date
    06-15-2016
    Location
    San Francisco
    MS-Off Ver
    2016
    Posts
    24

    Change Multiple Columns to TEXT Data Type

    I have a spreadsheet that I am trying to copy into Access; but before I can do this I have to change the format of several of the columns from GENERAL to TEXT, so the values make it into the Access table with their integrity intact. These columns are not adjacent, they are randomly dispersed throughout the spreadsheet, which has 80 or so columns. Manually selecting each column is labor-intensive, and rife with the potential for human error mucking up the data.

    Is there a simple way to do this, without having to address each column individually?
    Last edited by deekadelic; 07-19-2016 at 12:34 PM.

  2. #2
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Change Multiple Columns to TEXT Data Type

    Is there a simple way to do this, without having to address each column individually?
    Perhaps like this but be warned this will set all of the used range on the active sheet to text format.

    Please Login or Register  to view this content.
    Alf

  3. #3
    Registered User
    Join Date
    06-15-2016
    Location
    San Francisco
    MS-Off Ver
    2016
    Posts
    24

    Re: Change Multiple Columns to TEXT Data Type

    That will mess up all my date and currency columns, though. No way to do it by calling only specific columns?

  4. #4
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Change Multiple Columns to TEXT Data Type

    No way to do it by calling only specific columns?
    Sure, try

    Please Login or Register  to view this content.
    Alf

  5. #5
    Registered User
    Join Date
    06-15-2016
    Location
    San Francisco
    MS-Off Ver
    2016
    Posts
    24

    Re: Change Multiple Columns to TEXT Data Type

    I see where you're going with that; but still that's only one column. Better than a range of columns, true, but I need it to do all of the specified (read: hard-coded) columns at once. If there's a way.

  6. #6
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Change Multiple Columns to TEXT Data Type

    Last chance

    Please Login or Register  to view this content.
    Alf

  7. #7
    Registered User
    Join Date
    06-15-2016
    Location
    San Francisco
    MS-Off Ver
    2016
    Posts
    24

    Re: Change Multiple Columns to TEXT Data Type

    BOOM, that's it.

    Thanks!

  8. #8
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Change Multiple Columns to TEXT Data Type

    You are welcome.

    Don't forget to mark your thread solved.

    Alf

  9. #9
    Registered User
    Join Date
    06-15-2016
    Location
    San Francisco
    MS-Off Ver
    2016
    Posts
    24

    Re: Change Multiple Columns to TEXT Data Type

    Got it, thank you.

  10. #10
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Change Multiple Columns to TEXT Data Type

    Did an extrac check as I normally don't like using "Select" and found that the short form of the macro works just as well.

    Please Login or Register  to view this content.
    Alf

  11. #11
    Registered User
    Join Date
    06-15-2016
    Location
    San Francisco
    MS-Off Ver
    2016
    Posts
    24

    Re: Change Multiple Columns to TEXT Data Type

    Nice. Is there a way to trigger that code from the toolbars, or at least without having to build in any buttons or other objects?

  12. #12
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: Change Multiple Columns to TEXT Data Type

    Yes that seems to be possible, see link for how to do so:

    http://www.excel-easy.com/vba/exampl...e-toolbar.html

    Alf

+ 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. [SOLVED] multiple conditions to count large amount of data by Type, month & activity type
    By norfolk_lass in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-03-2014, 12:54 PM
  2. Text to Columns (changing data type to text)
    By rasikvekaria in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 01-17-2013, 05:44 PM
  3. importing multiple text files with the same data type
    By cmoral1266 in forum Excel Formulas & Functions
    Replies: 15
    Last Post: 08-30-2011, 12:38 PM
  4. Table Sorting When Multiple Columns Contain the Same Type of Data
    By blackholeinacan in forum Excel General
    Replies: 5
    Last Post: 03-09-2011, 12:20 PM
  5. How do I change text from all caps to normal type?
    By Karol in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-20-2006, 11:55 AM
  6. Replies: 3
    Last Post: 06-15-2006, 04:20 PM
  7. [SOLVED] Text to columns by format type???
    By Matt in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-07-2006, 06:00 PM

Tags for this Thread

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