Array sub-script within an an arry element

KG Old Wolf

Board Regular
Joined
Sep 20, 2009
Messages
65
I have the Bill Jelen book "VBA and MACROS" but I am missing something pretty basic.

I want to load a string to an array element and then examine a character or set of characters within it. For instance, I want to load "Ph: (212) 555-1212" and examine if the first three characters = "Ph:" or if the fifth character = "(".

I have been able to do this in other languages (sub-scripting an array element) but I am missing something here. I have loaded the string to an "Array as Variant" and then reDim Array (1 to 18) and then attempted to access "Array (1,2,3)" but that doesn't work.

I can accomplish this using other VBA commands but I want to leverage the power of array processing. What am I missing?

Thanks,
KG~
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,151,863
Messages
5,766,814
Members
425,379
Latest member
thedoctor00

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top