How to call user defined function in module from stimulsoft report ?

Stimulsoft Reports.NET discussion
Post Reply
stvhui
Posts: 51
Joined: Wed Apr 22, 2009 3:12 am

How to call user defined function in module from stimulsoft report ?

Post by stvhui »

Hello to you,
I'm using VB.NET 2005, Stimulsoft Report 2010.1

I develop in WinForm Platform.

I'm newbie using Stimulsoft Report.

Let say, I have created simple functions in VB.NET module (not class)

How to call the function from report?

Please advice & guide me step by step, or would you mind to send a sample code.

Thanks in advance.

Regards,
Steven
email : stvhui@yahoo.com
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

How to call user defined function in module from stimulsoft report ?

Post by Alex K. »

Hello,

As a way, you can put your simple functions in report on tab "Code".

Thank you.
Attachments
881.SampleReport.mrt
(3.32 KiB) Downloaded 639 times
hotcat
Posts: 10
Joined: Wed Mar 02, 2011 12:59 am

How to call user defined function in module from stimulsoft report ?

Post by hotcat »

Hi

I can find the Page1 and Preview,But can't find the Code

Steven
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

How to call user defined function in module from stimulsoft report ?

Post by Alex K. »

Hello,

Please see screenshot in attachment.

Thank you.
Attachments
950.Screen.png
950.Screen.png (103.4 KiB) Viewed 4989 times
RichFinnegan
Posts: 23
Joined: Fri Sep 23, 2011 4:43 am
Location: Germany

How to call user defined function in module from stimulsoft report ?

Post by RichFinnegan »

This showed me how to use user defined functions, but are they callable from inside a databand? In a text block it works fine but in a databand connected to a buisnessobject it doesn't.

regards

Richard
Ivan
Posts: 960
Joined: Thu Aug 10, 2006 1:37 am

How to call user defined function in module from stimulsoft report ?

Post by Ivan »

Hello,

We couldn't reproduce this issue.
Can you please send us a sample report template with data or a simple test project, which reproduces the issue?

Thank you.
RichFinnegan
Posts: 23
Joined: Fri Sep 23, 2011 4:43 am
Location: Germany

How to call user defined function in module from stimulsoft report ?

Post by RichFinnegan »

Hi,

Sorry about the delayed reply. I was on holiday. What you can use is the samples\CSharp\Pure\BusinessObjects example. All I did was to add the following code:

public string MyFunc()
{
return "XYZ";
}

and then change one column entry to {MyFunc()}. If you run the example nothing will be displayed in this column. If its important I'm using the Silverlight trial Version 2011.2.1100/19.09.2011.

Thanks.
Attachments
1413.BusinessObjects.zip
(5.81 MiB) Downloaded 491 times
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

How to call user defined function in module from stimulsoft report ?

Post by HighAley »

RichFinnegan wrote:Sorry about the delayed reply. I was on holiday. What you can use is the samples\CSharp\Pure\BusinessObjects example. All I did was to add the following code:

public string MyFunc()
{
return "XYZ";
}

and then change one column entry to {MyFunc()}. If you run the example nothing will be displayed in this column. If its important I'm using the Silverlight trial Version 2011.2.1100/19.09.2011.
Unfortunately, user functions isn't supported by Silverlight.

Thank you.
RichFinnegan
Posts: 23
Joined: Fri Sep 23, 2011 4:43 am
Location: Germany

How to call user defined function in module from stimulsoft report ?

Post by RichFinnegan »

Thanks for the reply. We came to this conclusion aswell. We wanted to write
additional functions to access dynamic properties. They are stored in a
dictionary. Is this possible and if so how? Is it possible to extend
the list of internal functions available by registering an external function
with the report designer? Both questions assume use of the silverlight version
of the designer/viewer.

Thanks.
HighAley
Posts: 8430
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

How to call user defined function in module from stimulsoft report ?

Post by HighAley »

Hello.
RichFinnegan wrote:Thanks for the reply. We came to this conclusion aswell. We wanted to write
additional functions to access dynamic properties. They are stored in a
dictionary. Is this possible and if so how? Is it possible to extend
the list of internal functions available by registering an external function
with the report designer? Both questions assume use of the silverlight version
of the designer/viewer.
At this moment it is impossible, because parser doesn't support third-party call methods.
If we'll make something in this area, we will let you know.

Thank you.
Post Reply