Automatically "left-shift" a field

Stimulsoft Reports.NET discussion
Post Reply
User avatar
Fabio Pagano
Posts: 355
Joined: Mon Apr 16, 2007 12:38 pm
Location: Bari (Italy)

Automatically "left-shift" a field

Post by Fabio Pagano »

I have three fields, one with a fixed text, one with a sum of a database field (eg. "Sum(Amount)") the other one with a fixed text. I need to obtain something like:

"Total amount: 123,45 including VAT."

The value "123,45" represents the second field.

I have designed the report this way:

Image

but the result is:

Image

while i wanted this:

Image

In few words, i need that the third field ("including VAT") shifts to left according to dynamic dimension of the second field.

I know that i can do a single text field, but i need to format the value field, so it must be separated from the others.

Is there a way to solve this?

Thanks.
EDV Gradl
Posts: 228
Joined: Sat Jun 17, 2006 9:50 am
Location: Germany

Automatically "left-shift" a field

Post by EDV Gradl »

Use one field and use the GetValueEvent.

Marco
User avatar
Fabio Pagano
Posts: 355
Joined: Mon Apr 16, 2007 12:38 pm
Location: Bari (Italy)

Automatically "left-shift" a field

Post by Fabio Pagano »

I cannot use events during rendering because the report isn't managed by the program itself but through a generic dll that incapsulates the stimulsoft dlls.

Thanks.
Vital
Posts: 1278
Joined: Fri Jun 09, 2006 4:04 am

Automatically "left-shift" a field

Post by Vital »

Why don't use for second text following expression:

Code: Select all

{Sum(Moviment)} including Vat.
?

Thank you.
Vital
Posts: 1278
Joined: Fri Jun 09, 2006 4:04 am

Automatically "left-shift" a field

Post by Vital »

For also you can use Tabulation in text expression.

Thank you.
User avatar
Fabio Pagano
Posts: 355
Joined: Mon Apr 16, 2007 12:38 pm
Location: Bari (Italy)

Automatically "left-shift" a field

Post by Fabio Pagano »

Vital wrote:Why don't use for second text following expression:

Code: Select all

{Sum(Moviment)} including Vat.
?
The value must be in an isolated field because it must be formatted, if i add a fixed string after the value the "format" doesn't work.

Thanks.
Brendan
Posts: 309
Joined: Sun Jul 16, 2006 12:42 pm
Location: Ireland

Automatically "left-shift" a field

Post by Brendan »

You could try Left Docking and CanShrink = true on the Text component that contains your numerical format.
Vital
Posts: 1278
Joined: Fri Jun 09, 2006 4:04 am

Automatically "left-shift" a field

Post by Vital »

You can use following expression:

Code: Select all

Total amount: {string.Format("C", Sum(Moviment))} including Vat.
Thank you.
Post Reply