Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 102
Default Arrays and Strings

"v" was a typo....

I think I undertand this except for one point....

In the else portion what I really want was:


a3(count,1) = a1(i,1) & a1(i,2) & a2(i,2) &......&a2(i,k-1) (inclusive
of all the dimesions between 2 and k-1 on a2.

Would something like this work?

Function BuildArray(a1,a2)
Dim a3(1,1)
count = 0
k = ArrayDimensions(a2)
For i = 1 to UBound(a1,1)
For j = 1 to UBound(a2,1)
If a2(j,1) = a1(i,1) Then
count = count+1
ResizeArray a3,count,2
a3(count,1) = a1(i,1) & a1(i,2)
a3(count,2) = a2(i,k)
If k 2 then
For h = 2 to k-1
a3(count,1) = a3(count,1) & a2(i,h)
Next h
End If
End If
Next j
Next i
End Function

.....but how does ArrayDimensions(a2) know that I want the size of the
2nd dimension?

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
find and replace numeric strings in larger text strings Mr Molio Excel Worksheet Functions 8 November 9th 11 05:17 PM
How to find number of pairs of strings from list of strings? greg_overholt Excel Worksheet Functions 5 January 27th 06 10:42 PM
Arrays and Strings [email protected] Excel Programming 2 September 2nd 04 02:53 AM
Finding strings within strings Rod[_6_] Excel Programming 1 December 2nd 03 05:34 PM
Finding strings within strings Rod[_6_] Excel Programming 1 December 2nd 03 05:19 PM


All times are GMT +1. The time now is 06:31 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"