realbasic-nug
[Top] [All Lists]

Re: Store colors in an array

To: RBNUG <realbasic-nug at lists dot realsoftware dot com>
Subject: Re: Store colors in an array
From: Seth Duke <seth at johnfinley dot com>
Date: Tue, 28 Feb 2006 13:04:47 -0500
Delivered-to: realbasic-nug at lists dot realsoftware dot com
On 2/28/06 11:42 AM, "Gary Edge" <rb at panamind dot com> wrote:

> I'm trying to store colors in an array:

It seems to work with a dictionary:

Dim i As Integer
Dim Colors As Dictionary

Colors = New Dictionary
Colors.Value(Colors.Count) = RGB(27,27,27)
Colors.Value(Colors.Count) = RGB(255,255,255)
Colors.Value(Colors.Count) = RGB(55,55,55)
  
if Colors <> Nil then
  For i = 0 to Colors.Count-1
    g.ForeColor = Colors.Value(i).ColorValue
    g.DrawLine 2*i, 2*i, 200, 2*i
  Next
end If

-Seth
--
<http://realopen.org>


_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>


<Prev in Thread] Current Thread [Next in Thread>