Ask Me Help Desk

Ask Me Help Desk (https://www.askmehelpdesk.com/forum.php)
-   Spreadsheets (https://www.askmehelpdesk.com/forumdisplay.php?f=395)
-   -   VBA for automatic Text to Columns (https://www.askmehelpdesk.com/showthread.php?t=612746)

  • Nov 16, 2011, 01:12 PM
    DrJ
    VBA for automatic Text to Columns
    Is there a way to write a VBA script that can accomplish the same as using Text to Columns? Right now, my users have to paste data into a spreadsheet, which then takes that data and fills in the necessary fields throughout the whole spreadsheet giving them instant access to all the calculations needed.

    All they have to do is paste into one cell... I was hoping Excel would save the spreadsheet ON the Data tab with the Text to Columns set up as Delimited with the delimiter set to a colon (:). However, it does not. Rather than having the user have to paste, select the Data tab, select Text to Columns, hit Next, uncheck Tab, check Other, put a : in the box, hit Next, and hit Finish (which may be easy enough for some but leaves too much room for error with a sales team), I was hoping there might be a more automated way of doing this.

    Any ideas?
  • Nov 16, 2011, 02:25 PM
    DrJ
    Holy cow! I just discovered the Record Macro button! I never knew Excel could do that! Makes it SOOOOO much easier than trying to code VB!

    For anyone else that may be looking into this, you have to enable the Developer tab (via Excel Options), select the developer tab, select Record Macro, do the command manually, then return to the Developer tab to stop recording... and it writes the macro for you!
  • Nov 16, 2011, 02:43 PM
    Curlyben
    Dude, Marcos, been around since the dawn of time ;)
    (well least since Office 2000, maybe 95)

    Where you been.
  • Nov 16, 2011, 04:18 PM
    ScottGem
    Macros and the ability to record them go back to VisiCalc. Welcome to the wonderful world of spreadsheets.

  • All times are GMT -7. The time now is 02:23 AM.