+ Reply to Thread
Results 1 to 2 of 2

Help needed in using concatenate function in Excel macro

  1. #1
    Registered User
    Join Date
    06-13-2013
    Location
    UAE
    MS-Off Ver
    Excel 2010
    Posts
    3

    Help needed in using concatenate function in Excel macro

    I have written the following code.

    ActiveCell.FormulaR1C1 = _
    "=CONCATENATE(RC[5],""-"",RC[6],""-"",RC[7],""-"",RC[ILastThread])"


    Here iLastThread is the name of a variable where i stored the column number of a particular column. But this code is not working. But instead when i hard code the value in the variable there, then it will work. But i need to use the variable itself. as i dont know the column number or name in advance.

    Please help me in regard of this.

  2. #2
    Forum Expert judgeh59's Avatar
    Join Date
    02-07-2013
    Location
    Boise, Idaho
    MS-Off Ver
    Excel 2016
    Posts
    2,310

    Re: Help needed in using concatenate function in Excel macro

    try this...

    Please Login or Register  to view this content.
    untested
    Ernest

    Please consider adding a * if I helped

    Nothing drives me crazy - I'm always close enough to walk....

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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