Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default standard function in userfunction?

Aloha,

Im in the progress of learning VBA I have created some simple vb
functions but Im woundering how I inser standard excel function in m
"home made function".
In my function called funcBatch I divide the weiht with 50 and get th
result 104,9.
funcBatch = (dblWeight / 50)
Now I want to use the CEILING function to get the result to 105.

But how Can I do this in the VBA code?
funcBatch = ceiling((dblWeight / 50);1) dosent seems to work

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
rog rog is offline
external usenet poster
 
Posts: 39
Default standard function in userfunction?


The worksheet functions which can be accessed (and not all
of them can) need to be qualified with the
WorksheetFunction object - so to use ceiling you should
write :

WorksheetFunction.Ceiling

Rgds

Rog

-----Original Message-----
Aloha,

Im in the progress of learning VBA I have created some

simple vba
functions but Im woundering how I inser standard excel

function in my
"home made function".
In my function called funcBatch I divide the weiht with

50 and get the
result 104,9.
funcBatch = (dblWeight / 50)
Now I want to use the CEILING function to get the result

to 105.

But how Can I do this in the VBA code?
funcBatch = ceiling((dblWeight / 50);1) dosent seems to

work.


---
Message posted from http://www.ExcelForum.com/

.

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
Pivot Tables - standard Data Field function KDJ Excel Discussion (Misc queries) 1 October 2nd 08 03:22 AM
Does anyone know if excel has a function to calculate standard er. mb Excel Worksheet Functions 2 March 25th 08 11:24 AM
Which function to determine 1 and 2 standard deviation? Eric Excel Worksheet Functions 2 November 24th 06 01:40 PM
What is the function to calculate standard errors of the mean? Steph Excel Worksheet Functions 2 July 17th 06 02:44 PM
Standard Error Maral Excel Worksheet Functions 2 December 4th 04 06:45 PM


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