StrataFrame Forum

Odd behaviour with richtextbox and right trim

http://forum.strataframe.net/Topic25211.aspx

By Aaron Young - 11/14/2009

Hi

I noticed some strange behaviour with a richtextbox bound to a field with right trim set in the business object mapper. When I enter 3 new lines as follows:-

1 [cr]
2 [cr]
3 [cr]

The lines are displayed in reverse order.

3
2
1

If I remove the right trim option in the business object mapper, then I can enter new lines and they are displayed in the correct order, i.e.

1
2
3

Looks like the trim is removing control codes along with spaces.

Aaron

By Les Pinter - 11/16/2009

Hi Aaron,

   I can't reproduce this. I created a CustomersBO from the StrataFrame sample data, set the Trim property for Address2 to Trim Right, dropped the BO on a Maintenance form, then clicked Edit and entered 1 [Enter], 2 [Enter], 3 [Enter], and behavior was as expected. I'm sure your experience was as you described, but I can't get the same result on my computer. Do you have any suggestions to help me repro it?

Les

By Aaron Young - 11/17/2009

Hi Les,

I noticed that the BindingFormat defaults to "Rtf" and when this is set I have the behavour I mentioned. However, if I change the BindingFormat to "Text" then it works.

Aaron