Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Urgent help from all excel expert !


Dear excel expert, I would like to create macro which can perform belo
function hopefully someone can help me as I am not strong in exce
programming.

in column A i got all the model number (string) in each row such as :
Column A
AB-12345
AB-12345A
AB-12345AB
AB-12345ACB
BA-A23
BA-A23A
BA-A23AB
BA-A23ABC

I want a macro which can perform as below once activated.
Column A...................Column B.......or...Column B
AB-12345...................AB-12345.............BA-A23
AB-12345A.................AB-12345A...........BA-A32A
AB-12345AB...............AB-12345AB.........BA-A32AB
AB-12345ACB
BA-A23
BA-A23A
BA-A23AB
BA-A23ABC

Up to 2 alphabet charecter after the number charecter within 1 string

You help is very appreciate. Thanks

--
brandon
-----------------------------------------------------------------------
brandonb's Profile: http://www.excelforum.com/member.php...fo&userid=3251
View this thread: http://www.excelforum.com/showthread.php?threadid=52341

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,069
Default Urgent help from all excel expert !

Are you trying to get models numbers that begin with AB in one column and
those that start with BA in another?

"brandonb" wrote:


Dear excel expert, I would like to create macro which can perform below
function hopefully someone can help me as I am not strong in excel
programming.

in column A i got all the model number (string) in each row such as :
Column A
AB-12345
AB-12345A
AB-12345AB
AB-12345ACB
BA-A23
BA-A23A
BA-A23AB
BA-A23ABC

I want a macro which can perform as below once activated.
Column A...................Column B.......or...Column B
AB-12345...................AB-12345.............BA-A23
AB-12345A.................AB-12345A...........BA-A32A
AB-12345AB...............AB-12345AB.........BA-A32AB
AB-12345ACB
BA-A23
BA-A23A
BA-A23AB
BA-A23ABC

Up to 2 alphabet charecter after the number charecter within 1 string

You help is very appreciate. Thanks !


--
brandonb
------------------------------------------------------------------------
brandonb's Profile: http://www.excelforum.com/member.php...o&userid=32511
View this thread: http://www.excelforum.com/showthread...hreadid=523413


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Urgent help from all excel expert !


John Wrote:
Are you trying to get models numbers that begin with AB in one colum
and
those that start with BA in another?

Ok what I want is lets say i enter BA-A23 the macro will find from al
my model list (maybe more than 1000 raw) then it will find the simila
model name such as BA-A23A, BA-A23AB, BA-A23ABC. The result will b
display unto another column

--
brandon
-----------------------------------------------------------------------
brandonb's Profile: http://www.excelforum.com/member.php...fo&userid=3251
View this thread: http://www.excelforum.com/showthread.php?threadid=52341

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Urgent help from all excel expert !


Where you entering your model number, from a userform or on the shee
itself

--
gti_jober
-----------------------------------------------------------------------
gti_jobert's Profile: http://www.excelforum.com/member.php...fo&userid=3063
View this thread: http://www.excelforum.com/showthread.php?threadid=52341

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Urgent help from all excel expert !


ok i've just wrote this for you, not checked it....but should work


Code
-------------------

Dim myArray(), maxArray%, myModelNo$

Erase myArray

myModelNo = where ever you get your _
value (from user form? from entry on sheet??)

'find all you model numbers based on input
i = 1
Do
If InStr(1, Cells(i, 1).Value, myModelNo, vbTextCompare) < 0 Then

maxArray = maxArray + 1
ReDim Preserve Arry(1 To maxArray)
Arry(maxArray) = Cells(i, 1).Value 'Stores your model in Array

End If
i = i + 1
Loop Until Cells(i, 1).Value = ""

'output model numbers to new column
i = 1
Do
Cells(i, 2).Value = Arry(i)
i = i + 1
Loop Until i = maxArray

-------------------

--
gti_jober
-----------------------------------------------------------------------
gti_jobert's Profile: http://www.excelforum.com/member.php...fo&userid=3063
View this thread: http://www.excelforum.com/showthread.php?threadid=52341



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
MOS Excel Expert 2003 Fowmy New Users to Excel 2 January 6th 11 10:22 PM
IME MODE FOR EXCEL 2007 (URGENT URGENT) Stella Wong Excel Discussion (Misc queries) 1 August 23rd 08 11:16 PM
excel expert with data JVANWORTH Excel Worksheet Functions 5 June 15th 07 01:00 AM
What next to become a developer or excel expert CmK Excel Discussion (Misc queries) 1 February 25th 07 04:09 PM
Excel Expert James Fok Excel Programming 0 October 21st 03 02:52 AM


All times are GMT +1. The time now is 05:26 PM.

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

About Us

"It's about Microsoft Excel"