LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 661
Default passing arguments to events

Hello and goodmorning, I don't know if this is possible but I would like to
pass an object to an event. I want to do something like this:
sub main()
dim somearray(50) as string
.... other code

call commandbutton_Click(byval somearray())
.... other code
end sub

private sub commandbutton_Click(somearray() as string)
.... code goes here
end sub

my problem is that when I do this it says that there is a duplicate private
sub commandbutton_Click(somearray() procedure and wrong number of arguments.
I am wondering what I can do. Maybe a class? I am not sure what I can do. Any
help would be greatly appreciated.
Paul
PS Any additional information you may need please let me know and I will
provide it.

 
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
Passing Arguments in Excell UB Excel Worksheet Functions 3 February 13th 07 04:08 PM
Passing arguments to VB Function Tom Excel Programming 1 March 29th 06 01:19 AM
Use of public variables vs. passing arguments quartz[_2_] Excel Programming 1 February 9th 05 08:25 PM
Passing Arguments Grant Reid Excel Programming 8 May 24th 04 01:39 PM
Passing arguments to a sub routine... Jeff Harbin[_2_] Excel Programming 2 January 29th 04 03:25 AM


All times are GMT +1. The time now is 12:18 PM.

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"