Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Need help with arrays (I think)


I have a slight problem that Excel either can not do or I can not enter
the formula
correctly. I am asking for your expertise. What I need is to enter
Value A
into a cell and then enter Value B into a cell, have Excel do the
division,
and then generate a table with that number of rows. For example, if I
enter
"20" into cell A2, enter "5" into cell B2, I need Excel to generate a
table
in cell C4 that starts at 1 and then in cell C5 is 2, then 3 .... Any
help would be greatly appreciated.

Thanks
Robert


--
rbhedal
------------------------------------------------------------------------
rbhedal's Profile: http://www.excelforum.com/member.php...o&userid=28199
View this thread: http://www.excelforum.com/showthread...hreadid=477412

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Need help with arrays (I think)

Sub abc()
If IsNumeric(Range("A2")) And IsNumeric(Range("B2")) And _
Not IsEmpty(Range("B2")) Then
If CLng(Range("B2")) < 0 Then
For i = 1 To Range("A2") / Range("B2")
Range("C4").Offset(i - 1, 0).Value = i
Next
End If
End If

End Sub

--
Regards,
Tom Ogilvy



"rbhedal" wrote in
message ...

I have a slight problem that Excel either can not do or I can not enter
the formula
correctly. I am asking for your expertise. What I need is to enter
Value A
into a cell and then enter Value B into a cell, have Excel do the
division,
and then generate a table with that number of rows. For example, if I
enter
"20" into cell A2, enter "5" into cell B2, I need Excel to generate a
table
in cell C4 that starts at 1 and then in cell C5 is 2, then 3 .... Any
help would be greatly appreciated.

Thanks
Robert


--
rbhedal
------------------------------------------------------------------------
rbhedal's Profile:

http://www.excelforum.com/member.php...o&userid=28199
View this thread: http://www.excelforum.com/showthread...hreadid=477412



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
Arrays Tobro88 Excel Discussion (Misc queries) 3 November 18th 05 11:28 PM
Arrays Dani Excel Programming 1 June 7th 05 05:28 PM
Arrays ryan wells Excel Programming 1 June 13th 04 06:20 AM
Arrays Lacy Excel Programming 3 June 8th 04 07:15 PM
arrays Dave B[_3_] Excel Programming 2 November 11th 03 03:32 AM


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