Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default calling a method on a object that you know the string name for.


say you have an object, and you want to call a method, but that method
name is a string.

is there a way to execute this method?

obviously, you can't do

obj.methodname

need something like

Invoke(obj, "methodname")... to execute that method on the object.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22
Default calling a method on a object that you know the string name for.

Check out CallByName. I think it does what you're talking about.


scotty wrote:
say you have an object, and you want to call a method, but that method
name is a string.

is there a way to execute this method?

obviously, you can't do

obj.methodname

need something like

Invoke(obj, "methodname")... to execute that method on the object.


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
calling a method on an object created in a different addin scotty[_2_] Excel Programming 1 January 12th 07 02:32 PM
Calling a sub method richcoleuk[_5_] Excel Programming 5 June 7th 06 10:33 AM
Calling Excel/Opentext method via ActiveX in a service application Salar Madadi Excel Programming 1 January 30th 06 11:33 PM
Calling a C++ DLL which returns a String Vorreiter Johann \(IFDA\) Excel Programming 2 January 13th 04 06:59 AM
Calling a module function from a class method ranafout[_2_] Excel Programming 1 November 12th 03 11:08 AM


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