Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default Custom Array Functions

Did you use ctrl+shift+enter ?

http://www.cpearson.com/excel/array.htm

Tim

"Syed Zeeshan Haider" wrote in
message ...
Hello Everybody,
I have Excel 2003 Pro on WinXP Pro.

I have been searching on internet but could not find any useful
information about creating custom array functions.
Can somebody tell me any links to the reference about creating
custom array functions?

Well, actually I saw a rather complex code on a site. This code
returned array but I couldn't spend next 2 to 3 hours in
understanding what was it supposed to calculate. No description was
provided.
I tried to experiment with my own following code:

Public Function DispArray(a_number As Integer) As Variant
' yes, varaibles are not logical
Dim aAd(1 To 12) As Integer
Dim n As Integer
For n = 1 To 12 Step 1
aAd(n) = n * a_number
Next n
DispArray = aAd
End Function

It is supposed to display multiplication table's result of a given
integer (a_number). But it returns same result in all select cells.

Thank you,
--
Syed Zeeshan Haider


-----------------------------------------------------------------------------------------------------------------------------
Download a free game to play with Internet Explorer from
http://szh.20m.com/entertainment/olwg.html



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Custom Array Functions

Yes, I used ctrl+shift+enter and visited said site.

"Tim Williams" <saxifrax@pacbell*dot*net wrote in message
...
Did you use ctrl+shift+enter ?

http://www.cpearson.com/excel/array.htm

Tim

"Syed Zeeshan Haider" wrote in
message ...
Hello Everybody,
I have Excel 2003 Pro on WinXP Pro.

I have been searching on internet but could not find any useful
information about creating custom array functions.
Can somebody tell me any links to the reference about creating custom
array functions?

Well, actually I saw a rather complex code on a site. This code returned
array but I couldn't spend next 2 to 3 hours in understanding what was it
supposed to calculate. No description was provided.
I tried to experiment with my own following code:

Public Function DispArray(a_number As Integer) As Variant
' yes, varaibles are not logical
Dim aAd(1 To 12) As Integer
Dim n As Integer
For n = 1 To 12 Step 1
aAd(n) = n * a_number
Next n
DispArray = aAd
End Function

It is supposed to display multiplication table's result of a given
integer (a_number). But it returns same result in all select cells.

Thank you,
--
Syed Zeeshan Haider


-----------------------------------------------------------------------------------------------------------------------------
Download a free game to play with Internet Explorer from
http://szh.20m.com/entertainment/olwg.html





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
Custom functions Palpha32 Excel Worksheet Functions 6 July 21st 08 12:36 AM
Custom functions GKW in GA Excel Discussion (Misc queries) 3 February 20th 08 02:16 PM
Custom Functions DTTODGG Excel Worksheet Functions 7 January 11th 08 07:37 PM
efficiency: database functions vs. math functions vs. array formula nickname Excel Discussion (Misc queries) 2 July 14th 06 04:26 AM
Using custom functions within custom validation Neil Excel Discussion (Misc queries) 4 December 14th 05 10:40 PM


All times are GMT +1. The time now is 03:08 AM.

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"