Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Populate Range

What´s wrong with this? And, is there a way to populate a range in one
line code? Thanks in advance.


Sub Test
Range("E1:F3").value = Array(1,2,3,4,5,6)
end sub

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 301
Default Populate Range

It takes 2 lines:
Sub Test()
Range("E1:F3").FormulaArray = "={1,2;3,4;5,6}"
Range("E1:F3").Formula = Range("E1:F3").Value
End Sub
Bob Umlas
Excel MVP

"Fabio" wrote in message
oups.com...
What´s wrong with this? And, is there a way to populate a range in one
line code? Thanks in advance.


Sub Test
Range("E1:F3").value = Array(1,2,3,4,5,6)
end sub


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Populate Range

Thanx a lot

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Populate Range

Bob,

Actually the first pair is string
"={"Word1","Word2";1,2;3,4}"

Any help?

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
How to Delete blanks between a range and populate only the names inthe given range Yuvraj Excel Discussion (Misc queries) 2 November 4th 09 08:32 PM
Populate cell range lost and confused in excel-land[_2_] Excel Worksheet Functions 1 July 13th 08 07:07 AM
Populate a Combobox from range. ex1302[_8_] Excel Programming 14 July 22nd 05 05:32 PM
Populate a range of cells from a function 4eyed Excel Programming 2 June 1st 05 11:17 PM
using For each loop to populate a range Sean Excel Programming 2 September 30th 04 02:13 PM


All times are GMT +1. The time now is 09:28 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"