#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default arrays

I have a template that needs to be filled out from fields coming from other
excel spreadsheet available in the server( actually sheet names), I want to
make available only this values to make the choice on Worksheet_change on
that excel template, I can get all the worksheet names in msgbox one by one
but I don't know how to pass them to one of the cells in my template, should
do it on arrays?, how?, I want also to move the focus from the first cell
the one on the right side and following one to right side, like for example
if A7 is the first cell, 2nd one B7, 3rd C7, 4th D7, next A8, B8, C8, D8,
etc..

Thanks


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default arrays

Tajin,

If you can get the worksheet names, to write them to your template is as
simple as coding within your template

strSheetName = ...... use the same method which you are using to get the
name for the msgbox

Thisworkbook.Worksheets("Sheet1").Range("A7").Valu e = strSheetName

As to moving the focus, there are as many methods as there are VBA coders,
and the best method depends on how you are actually doing your procedure.
For example, you could simply loop:

For myCol = 1 to 4
For myRow = 7 to 15
Cells(MyRow,MyCol).Value = "whatever ..."
Next myRow
Next myCol

But, as I've said, the best method depends on what you are doing overall in
your procedure.

HTH,
Bernie
MS Excel MVP

"Tajin" wrote in message
...
I have a template that needs to be filled out from fields coming from

other
excel spreadsheet available in the server( actually sheet names), I want

to
make available only this values to make the choice on Worksheet_change on
that excel template, I can get all the worksheet names in msgbox one by

one
but I don't know how to pass them to one of the cells in my template,

should
do it on arrays?, how?, I want also to move the focus from the first cell
the one on the right side and following one to right side, like for

example
if A7 is the first cell, 2nd one B7, 3rd C7, 4th D7, next A8, B8, C8, D8,
etc..

Thanks




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
Use of IF with arrays Andrew L Excel Worksheet Functions 5 August 15th 08 10:15 PM
arrays again RobcPettit Excel Programming 3 January 24th 04 10:33 PM
Arrays David Excel Programming 5 January 10th 04 05:09 AM
arrays solo_razor[_44_] Excel Programming 2 December 15th 03 12:06 PM
arrays and others.. Locachica[_3_] Excel Programming 4 December 3rd 03 09:39 PM


All times are GMT +1. The time now is 05:42 PM.

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"