+ Reply to Thread
Results 1 to 13 of 13

Rows C-F have the address. I created a new column and need the address in one column,row J

  1. #1
    Registered User
    Join Date
    03-03-2019
    Location
    Anaheim, California
    MS-Off Ver
    Office Plus 2016
    Posts
    41

    Rows C-F have the address. I created a new column and need the address in one column,row J

    Rows C-F have the address of the users. I created a new column, and I need the address in just one column, (Row J)

    In this format: Street address, city, state ZIP. I believe this would be a script/ formulaAddress in one Column.JPG

    I have created a screen capture.


    Thank you.

  2. #2
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    03-03-2019
    Location
    Anaheim, California
    MS-Off Ver
    Office Plus 2016
    Posts
    41

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    Hello. and thanks for your help. I went to run that script and received an error. See screen capture.script error.JPG

  4. #4
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    No problems here add to a module not the sheet module
    Please Login or Register  to view this content.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    03-03-2019
    Location
    Anaheim, California
    MS-Off Ver
    Office Plus 2016
    Posts
    41

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    That didn't work. Are you calling my sheet, Sheets (1) ? Because I have named the sheet. Where do I enter my sheet name in the script?Mod.JPG
    I have named my column (J) "Full Address" in cell J1

  6. #6
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    so might not be sheet 1
    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    03-03-2019
    Location
    Anaheim, California
    MS-Off Ver
    Office Plus 2016
    Posts
    41

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    I'm not 100% clear on your reply. Let me enter the name in the script to see if it's correct. I have named my sheet Example. See below

    Sub address()
    Dim lrow As Long
    Dim i As Long
    lrow = Example.Range("a" & Rows.Count).End(xlUp).Row
    With Example
    For i = 2 To lrow
    .Range("j2:j" & lrow).Formula = "=c2&"" - ""&d2&"" - ""&e2&"" - ""&f2"
    .Columns(10).AutoFit
    Next
    End With
    End Sub

  8. #8
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    Please Login or Register  to view this content.

  9. #9
    Registered User
    Join Date
    03-03-2019
    Location
    Anaheim, California
    MS-Off Ver
    Office Plus 2016
    Posts
    41

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    That worked. Except the script added a hyphen in - between - each - address - block. screen shot dashes.JPG

  10. #10
    Registered User
    Join Date
    03-03-2019
    Location
    Anaheim, California
    MS-Off Ver
    Office Plus 2016
    Posts
    41

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    would it be hard to create a script and remove the hyphen and add a comma? in this format: 1 National Ave, Cleveland, OH 85623
    So a comma after the street, and city

  11. #11
    Forum Expert nigelog's Avatar
    Join Date
    12-14-2007
    Location
    Cork, Ireland
    MS-Off Ver
    Office 365 Windows 10
    Posts
    2,286

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    Please Login or Register  to view this content.
    change or omit dashes in red

    as in

    Please Login or Register  to view this content.
    Last edited by nigelog; 03-05-2019 at 09:08 AM.

  12. #12
    Registered User
    Join Date
    03-03-2019
    Location
    Anaheim, California
    MS-Off Ver
    Office Plus 2016
    Posts
    41

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    I received an error. error.JPG

  13. #13
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,706

    Re: Rows C-F have the address. I created a new column and need the address in one column,r

    Guessing that "1 E address" is in cell C2 (assuming that the top row is filled with column headers) paste the following into cell J2 then copy down: =C2&" "&D2&" "&E2&" "&F2
    Let us know if you have any questions.
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

+ 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] Using Address Function to create an address referencing the entire column
    By OliverS in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 05-28-2015, 01:06 AM
  2. Replies: 2
    Last Post: 11-07-2014, 06:10 PM
  3. Replies: 5
    Last Post: 06-26-2013, 06:16 PM
  4. Converting a complete, single column address into separate columns for ADDRESS, CITY, ST,
    By jeffrogerssn in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-08-2012, 10:34 AM
  5. Easy way to transpose address info from one long column into neatly sorted rows.
    By hhhava in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-28-2012, 03:26 AM
  6. Ping Host Name Column A IP address Result column B Response time Column c
    By NickMac in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-13-2012, 03:23 AM
  7. changing cell address to row/column address
    By michaelbails in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 04-30-2010, 09:47 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