Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #2  
Old 02-19-2020, 09:04 PM
macropod's Avatar
macropod macropod is offline Dim statement for Split array Windows 7 64bit Dim statement for Split array Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

If you declare an array, you need to populate it with code like:
Code:
Dim x As Long, y as long
Dim BlueLite As String          'Light blue RBG values
BlueLite = "219,229,241"        '.
Dim RGBVals() As Variant        'Array for indivicdual RGB values
x = UBound(Split(BlueLite, ","))
ReDim RGBVals(x)
For i = 0 To x
  RGBVals(y) = Split(BlueLite, ",")(y)  '.
Next
It's not apparent why you'd want to go down the array path for RGB values, though, whichever approach you take.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Dim statement for Split array Mail Merge - split merged documents and rename each split document based on text in header FuriousD Word VBA 1 05-12-2019 04:06 AM
Converting a Select statement in Excel to an update statement shabbaranks Excel Programming 5 10-31-2018 11:47 PM
Split word file into several PDF using the bookmarks as split positions and name Fixxxer Word VBA 7 10-08-2018 01:10 AM
Split function in Excel (split the screen) Officer_Bierschnitt Excel 1 07-05-2017 07:02 AM
Dim statement for Split array Convert String Array to Integer Array from a User Input? tinfanide Excel Programming 4 12-26-2012 08:56 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 05:56 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft