Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Using VBA Functions in a worksheet

Within VBA I can access worksheet functions, like ROMAN, as follows:

TryString = Application.WorksheetFunction.Roman(i)

In the worksheet I can access worksheet functions and any UDFs I define.

How can I access VBA functions, like DIR(), in the worksheet?

--
Gary''s Student
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,337
Default Using VBA Functions in a worksheet

Maybe with a worksheet_event macro. Right click the sheet tabview codeleft
window worksheetright window for different events

--
Don Guillett
SalesAid Software

"Gary''s Student" wrote in message
...
Within VBA I can access worksheet functions, like ROMAN, as follows:

TryString = Application.WorksheetFunction.Roman(i)

In the worksheet I can access worksheet functions and any UDFs I define.

How can I access VBA functions, like DIR(), in the worksheet?

--
Gary''s Student



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Using VBA Functions in a worksheet

This is similar to what I am attempting to avoid. For example IsDate() is
available in VBA, but is not a worksheet function. To use IsDate() in the
worksheet, I create a UDF as follows:

Function isdt(s As Range) As Boolean
isdt = IsDate(s)
End Function

I can then use isdt (a.k.a IsDate) anywhere in the worksheet.

Do I have to create a UDF for every VBA function I want to use in the
worksheet??
--
Gary''s Student


"Don Guillett" wrote:

Maybe with a worksheet_event macro. Right click the sheet tabview codeleft
window worksheetright window for different events

--
Don Guillett
SalesAid Software

"Gary''s Student" wrote in message
...
Within VBA I can access worksheet functions, like ROMAN, as follows:

TryString = Application.WorksheetFunction.Roman(i)

In the worksheet I can access worksheet functions and any UDFs I define.

How can I access VBA functions, like DIR(), in the worksheet?

--
Gary''s Student




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
Help with worksheet functions Angeline Excel Discussion (Misc queries) 2 October 11th 06 11:19 PM
IF AND OR Worksheet Functions ExcelBob Excel Discussion (Misc queries) 2 May 5th 06 11:23 AM
UDF x worksheet functions Rogerio Takejame Excel Worksheet Functions 3 March 9th 06 08:11 PM
Worksheet functions Joe D. Excel Worksheet Functions 0 March 8th 06 02:24 PM
Public Functions As Worksheet Available Functions Steve King Excel Programming 3 February 12th 05 07:55 PM


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