Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 95
Default Another loop & sheet question

Linc,

The 'Dim' statement is used to declare a variable (its name is short for
'Dimension', going back to the earliest days of the BASIC programming
language), and the 'As Long' indicates what type of variable is being
declared. A Long type of variable is 4 bytes in length, and can contain a
whole number between about +/- 4 billion.

So the statement

Dim Index As Long

essentially tells VBA to declare a Long type variable and give it a name
'Index'. Code can then store whole numbers between +/- 4 billion in this
variable.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Linc" wrote in message
...

Can you tell me what this part of your code is doing?

<SNIP

Dim clSheets As Collection
Dim ws As Worksheet
Dim index As Long
Set clSheets = New Collection

<END SNIP


I don't really know what 'DIM' is asking and what 'Long' is all about.

Linc

Sorry, very new at this.


------------------------------------------------
~~ Message posted from http://www.ExcelTip.com/
~~View and post usenet messages directly from http://www.ExcelForum.com/



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
Loop question aelewis Excel Discussion (Misc queries) 2 October 24th 07 08:12 PM
Loop question N.F[_2_] Excel Discussion (Misc queries) 0 July 12th 07 08:02 PM
Loop QUESTION to end of data range... mniccole Excel Worksheet Functions 2 December 4th 06 09:25 PM
Loop QUESTION to end of data range... mniccole Excel Worksheet Functions 2 December 4th 06 05:19 PM
Password Loop question. Andy Tallent Excel Discussion (Misc queries) 1 April 8th 05 01:16 PM


All times are GMT +1. The time now is 01:59 AM.

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"