Hi Team,
Please see the attached excel, i need a short cut to make Column B data to repeat each item in column A,
I tried some excellent formula from this forum, but that will not fit to my need.
Thanks in advance,
Cheers.
RGIN
Hi Team,
Please see the attached excel, i need a short cut to make Column B data to repeat each item in column A,
I tried some excellent formula from this forum, but that will not fit to my need.
Thanks in advance,
Cheers.
RGIN
This little macro will accomplish what you want on a newly added sheet.
How/Where to install the macro:Please Login or Register to view this content.
1. Open up your workbook
2. Get into VB Editor (Press Alt+F11)
3. Insert a new module (Insert > Module)
4. Copy and Paste in your code (given above)
5. Get out of VBA (Press Alt+Q)
6. Save as a macro-enabled workbook (.xlsm)
The macro is installed and ready to use.
Make sure your data sheet is onscreen and then press Alt-F8 and select it from the macro list to run it.
_________________
Microsoft MVP 2010 - Excel
Visit: Jerry Beaucaire's Excel Files & Macros
If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
Always put your code between code tags. [CODE] your code here [/CODE]
?None of us is as good as all of us? - Ray Kroc
?Actually, I *am* a rocket scientist.? - JB (little ones count!)
you need help of VB script
just change catagory to VBA funtions
or do one thing paste code one by one
example
if pn are 4 then copy code from b3 to b10 and (total 8 values) paste 4*8 = 32 cells i.e. for I Column press f5 and in goto window type "i1:i32" just paste
and now for pn copy a3:a6 and paste it for 8 times and sort it in another sheet and paste in H column
JBeaucaire thanks, i will try and let you know, on question can any modification of the below formula will help with out macro.
IF(ROWS($1:1)>MAX($J:$J),"",INDEX(G:G,MATCH(ROWS($1:1)-1,$J:$J)+1). this i found from another thread in this forum but it will repeat both Colum A and Column B to certain times, but that will not fill my concern.
But i am okay with your Macro.
@morevijay1982, thanks for you quick reply to my issue, but i didn't understand what you mentioned.
Update, JBeaucaire it worked in my case perfectly. Please check if any way we can make it with formula.
Thanks once again.
Sorry, the macro is the way I would (and did) solve this problem. The formula version isn't on my radar.
If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.
No issues JBeaucaire, I just asked, but yours was the solution for my issue and i did it with you macro.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks