View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
[email protected] Eran.Yasso@gmail.com is offline
external usenet poster
 
Posts: 2
Default Return value from excel macro

Hi All,

I have application in C# which I call excel MACRO. All works fine. the
point is that i want to return value(even simple - 0\1). I saw some
samples in vb but it doesn't work in C#.

This is what I do:

Excel
Public Function te() As Long
te = 1
End Function

C#
int k = ( int )oXL.Run( function_name , val0,val1...val28);

in this case, i get exeption in C#.

thanks for the help