Leading spaces in Variables from the dictionary seems to be trimmed

Stimulsoft Reports.NET discussion
Post Reply
spv123
Posts: 26
Joined: Mon Oct 02, 2006 8:07 am
Location: Sheffield, UK

Leading spaces in Variables from the dictionary seems to be trimmed

Post by spv123 »

I have a number of text fields on my report which simply contain variables from the dictionary eg {Field1}

I'm setting this in code at runtime by code similar to :

dim rpt as new Stimusoft.report.stireport
rpt.load("myreport.mrt")
rpt.dictionary.variables("Field1")=" Hello"
rpt.compile
rpt.render
rpt.show

When this displays the word "Hello" appears on the left hand side of the field (ie the leading spaces have been removed).

How do I stop this?
EDV Gradl
Posts: 228
Joined: Sat Jun 17, 2006 9:50 am
Location: Germany

Leading spaces in Variables from the dictionary seems to be trimmed

Post by EDV Gradl »

I had a similar problem. It think it is a problem of GDI+.
spv123
Posts: 26
Joined: Mon Oct 02, 2006 8:07 am
Location: Sheffield, UK

Leading spaces in Variables from the dictionary seems to be trimmed

Post by spv123 »

Was there any solution ?
Vital
Posts: 1278
Joined: Fri Jun 09, 2006 4:04 am

Leading spaces in Variables from the dictionary seems to be trimmed

Post by Vital »

Yes, you are right. This is problem of GDI+. Please use property Margins of Text component.

Thank you.
spv123
Posts: 26
Joined: Mon Oct 02, 2006 8:07 am
Location: Sheffield, UK

Leading spaces in Variables from the dictionary seems to be trimmed

Post by spv123 »

Sorry, I'm confused... Can you give me a little more of a pointer.. ? How do you mean "Margins of Text" ???
Vital
Posts: 1278
Joined: Fri Jun 09, 2006 4:04 am

Leading spaces in Variables from the dictionary seems to be trimmed

Post by Vital »

This property allows you to set the distance between each border and content of StiText. Format of property: left;right;top;bottom

Thank you.
Post Reply