Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 60
Default Help, probably easy

Hey,

I could do with some more help, I have a set of values (will be 16
characters long) and they are unique to a certain code (1 code can have
multipul values) E.g.

Code Value
111 000752
111 005894
111 007277
111 012297
111 029580
111 033820
111 046019
111 047341
111 071340
111 072354
111 112763
111 180351
113 006661
113 024007
113 030180
113 036242
113 037290
113 037591
113 037648
113 038938
113 061387
113 066591
113 073563

I need to some macro code/formula to copy and paste the value into another
cell in a list for each Code.

E.g.

Code: 111 in cell A1
List 000752,005894,007277,etc,etc in B1

I need the values to be seperated by a comma and no spaces, they must keep
the 0's infront of the numbers though.

So basically i need to search the column with the 3digit codes in and past
the values that are in the cell next to that code into the same cell in a
list. I need it to do this for every code i have (about 150) with each code
being on a seperate line

Need it to look something like below.

Column A B
Row Code List
1 111 000752,002561,007277,etc,etc
2 113 006661,024007,030180,etc,etc
3
4
5
6


Thanks in Advance
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 222
Default Help, probably easy

The function I use for this StringConcat by Chip Pearson

http://www.cpearson.com/excel/stringconcatenation.aspx

The benefit of this tool once you install it in your sheet is that it will
take an IF statement.

So if you codes are in column A1:A100 and you values are in column B1:B100,
you could put one of the codes in C1 (111 for instance) and in D1 this
formula would string concatenate:

=StringConcat(",",IF($A$1:$A$100 = C1, $B$1:$B$100,"") )

.....entered as an array formula with Ctrl-Shift-Enter. Works great. The
results would be exactly what you asked for.


--
"Actually, I *am* a rocket scientist." -- JB

Your feedback is appreciated, click YES if this post helped you.


"N1KO" wrote:

Hey,

I could do with some more help, I have a set of values (will be 16
characters long) and they are unique to a certain code (1 code can have
multipul values) E.g.

Code Value
111 000752
111 005894
111 007277
111 012297
111 029580
111 033820
111 046019
111 047341
111 071340
111 072354
111 112763
111 180351
113 006661
113 024007
113 030180
113 036242
113 037290
113 037591
113 037648
113 038938
113 061387
113 066591
113 073563

I need to some macro code/formula to copy and paste the value into another
cell in a list for each Code.

E.g.

Code: 111 in cell A1
List 000752,005894,007277,etc,etc in B1

I need the values to be seperated by a comma and no spaces, they must keep
the 0's infront of the numbers though.

So basically i need to search the column with the 3digit codes in and past
the values that are in the cell next to that code into the same cell in a
list. I need it to do this for every code i have (about 150) with each code
being on a seperate line

Need it to look something like below.

Column A B
Row Code List
1 111 000752,002561,007277,etc,etc
2 113 006661,024007,030180,etc,etc
3
4
5
6


Thanks in Advance

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Should be easy, but... mr tom Excel Worksheet Functions 7 March 6th 07 06:26 PM
Here's an EASY one for you, not me :( barbierim Excel Worksheet Functions 4 October 28th 05 12:36 AM
new user with easy question? not easy for me speakeztruth New Users to Excel 5 June 3rd 05 09:40 PM
An easy one! Dr. Schwartz[_3_] Excel Programming 2 January 19th 04 12:33 PM
Really easy? PaulSinki[_6_] Excel Programming 3 December 16th 03 09:55 AM


All times are GMT +1. The time now is 02:35 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"