| |
ActiveReports for .NET 2.0 Support
Started by gullu_sibi at 03-12-2010 1:25 PM. Topic has 4 replies.
 
 
 
|
|
Sort Posts:
|
|
|
|
03-12-2010, 1:25 PM
|
gullu_sibi
Joined on 03-10-2010
Posts 19
|
Add a trailing space to field...
|
|
|
|
|
Hi,
I have a report with amount field in detail section. The values in this field are right aligned. I was asked to add some padding space in the right ... Could some one please tell me how to add padding... I tried padding it using style property and also in the designer.. it didn't work... May be I'm missing something...
eg: if input is 223.23, I want the output like this 223.23 and a space after this... something like this 223.23<space>
|
|
|
|
|
Report
|
|
|
|
03-15-2010, 8:43 AM
|
abacrotto

Joined on 01-09-2009
Bahía Blanca, Buenos Aires, Argentina
Posts 28
|
Re: Add a trailing space to field...
|
|
|
|
|
Hello, gulu.
You can add a handler for the FetchData event. In the event you set the .Text property of your control like this:
this.myText.Text = this.Fields["MyField"].Value.ToString("0.00") + " ";
Where myText is the TextBox you can change the text in, and MyField is the name of the field containing the numeric values.
Regards.
Ariel.
I'm only, I'm the best (read it from YOUR viewpoint, not mine) :)
|
|
|
|
|
Report
|
|
|
|
03-15-2010, 8:50 AM
|
AnkitN
Joined on 03-03-2009
Posts 844

|
Re: Add a trailing space to field...
|
|
|
|
|
Hello,
Have you tried setting the style like “font-weight: bold; font-size: 14pt; padding-right: 50px;”? If you only want to insert the extra space in the textbox then you can use the following code in the section format event;
textBox1.Text += "";
I would also like to inform you that in ActiveReports 6, the textbox also has a padding property. To know more about ActiveReports 6 you may check this link.
Regards, Ankit Nigam
|
|
|
|
|
Report
|
|
|
|
03-15-2010, 2:49 PM
|
gullu_sibi
Joined on 03-10-2010
Posts 19
|
Re: Add a trailing space to field...
|
|
|
|
|
Hi abacrotto and Ankit,
Thanks for your reply... But it didn't work... I tried all these things before posting... I even tried it now... None worked for me...
1) “font-weight: bold; font-size: 14pt; padding-right: 50px;” 2) this.myText.Text = this.Fields["MyField"].Value.ToString("0.00") + " "; 3) textBox1.Text += "";
It happens only for right aligned fields... for left aligned fields, padding left is working... but for right aligned fields... i debugged the code... it pads the empty space in the right... but when printing the PDF, it trims the space... I don't know why...
|
|
|
|
|
Report
|
|
|
|
03-16-2010, 9:52 AM
|
AnkitN
Joined on 03-03-2009
Posts 844

|
Re: Add a trailing space to field...
|
|
|
|
|
Hello,
I was able to replicate the issue at my end. However I would like to tell you that Active Reports for .NET 2.0 is no longer in active development, so we cannot add new feature for padding in this version.
As I already informed you that the ActiveReports 6 has a padding property for the controls. If you want you can install the evaluation version of ActiveReports 6 and test this property.
Regards, Ankit Nigam
|
|
|
|
|
Report
|
|
|
|
|
GrapeCity » Product Support » ActiveReports f... » Add a trailing space to field...
|
|
|
|
|