Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Pal Pal is offline
external usenet poster
 
Posts: 27
Default problems calling this function

I am having problems calling this function
It returns the YEAR, MONTH, DAY, HOUR from a Julian Day.
So the only input to the call is the Julian Day and a Gregorian calendar
flag which equals 1
But I don't know how a function can return a value and put it into other
cells.

If I just call =swe_revjul_d(E8,1) With E8=Julian day then I get an error.

If I put =swe_revjul_d(E8,1,F9,G9,H9,I9) in cell E9 with Julian Day in E8,
I get 0 as a result in E9, otherwise I get errors.
But there is nothing returned to F9 to I9.

Private Declare Function swe_revjul_d Lib "swedll32.dll" _
Alias "_swe_revjul_d@24" ( _
ByRef tjd As Double, _
ByVal gregflg As Long, _
ByRef year As Long, _
ByRef month As Long, _
ByRef day As Long, _
ByRef hour As Double _
As Long)

Thanks


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default problems calling this function

Pal,

It can't, it can only return a value to the calling cell.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Pal" wrote in message
news:kL7Xb.302879$xy6.1487323@attbi_s02...
I am having problems calling this function
It returns the YEAR, MONTH, DAY, HOUR from a Julian Day.
So the only input to the call is the Julian Day and a Gregorian calendar
flag which equals 1
But I don't know how a function can return a value and put it into other
cells.

If I just call =swe_revjul_d(E8,1) With E8=Julian day then I get an error.

If I put =swe_revjul_d(E8,1,F9,G9,H9,I9) in cell E9 with Julian Day in E8,
I get 0 as a result in E9, otherwise I get errors.
But there is nothing returned to F9 to I9.

Private Declare Function swe_revjul_d Lib "swedll32.dll" _
Alias "_swe_revjul_d@24" ( _
ByRef tjd As Double, _
ByVal gregflg As Long, _
ByRef year As Long, _
ByRef month As Long, _
ByRef day As Long, _
ByRef hour As Double _
As Long)

Thanks




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 function in my SQL-DB from VBA KSor Excel Discussion (Misc queries) 0 March 11th 09 02:08 PM
Calling function from a userform Jeff Excel Discussion (Misc queries) 0 September 27th 06 03:27 PM
calling a new function Excel gives me #NAME? Mark Dvorkin Excel Worksheet Functions 4 July 10th 05 01:29 AM
Calling VBA function that is in another module Jag Man Excel Programming 2 January 7th 04 03:37 AM
Calling a function from within EXCEL pcor[_2_] Excel Programming 3 July 18th 03 05:10 PM


All times are GMT +1. The time now is 02:40 PM.

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"