
01-20-2012 09:56 AM
How do I format a numeric value as a percentage?
value 0.1 = 10%
I am using the QFDataGrid control columns collection.
In the bound field I see the property TextFormatString.
What do I put in there to make this work?
I also tried the Custom Format Column
Properties are Format Code and FormatMethod Name I've tried everything I can think of in these and nothing seems to work.
Documentation in help file is less than helpful.
"TextFormatString - gets or sets the text format string. Use this to add string formatting to bound data." Really?? How abouyt the magic incantation to make it work??
I've evn tried holding my tongue in different positions. Sheesh...
01-20-2012 10:17 AM
Are you configuring an Editable Grid control with a Numeric column in 7.5.4? If so, would Format Type=Percent do what you need?
<script type="text/javascript" src="../../SkinSupport/MadCapMerging.js"></script>
<script type="text/javascript" src="../../SkinSupport/MadCapAliasFile.js"></scrip
|
Description: |
Used to convert a numeric value to a string. |
|
|
|
|
To use this property: |
Select a value from the drop-down list. Available options for the control are:
Available options for the grid column are:
|
|
|
|
|
Default Value: |
Number |
01-20-2012 10:26 AM
Nope, just a DataGrid.
It's what the new form wizard pumps out.
to access properties.
01-20-2012 04:11 PM - last edited on 01-23-2012 11:47 AM
I'm told that TextFormatString should take the same syntax as the data bindings Format String.
The Format String property uses standard .NET Composite Formatting String syntax, which is defined at http://msdn.microsoft.com/en-us/library/txafckwd.a
For example, on the data bindings for a Button control, bind ToolTip to AccountManager and set its Format String = "Click to see Tickets for {0}"
- From AA help topic "Bind Control Properties Collection Editor"
I'll verify and update this post next week. Your question will help the doc, so thank you.
01-20-2012
04:47 PM
- last edited on
01-23-2012
10:02 AM
by
lorir-w
Ok,
Composite formating syntax is the trick here.
using
works as expected. (open curly brace zero colon P close curly brace)
A cleaner example on the editable grid would be nice as well. The one in the help file is very simplistic. An option to have an editible grid from the wizard would be nice as well.
where does the drop down in the "Applied Security" get its contents? My entity (A custom entity in my implementation) I am working with does not have an entry there. My Entity is exposed properly through SData and functioning properly. I know because we have our own custom app that uses it daily. I'm just now getting around to doing customizations fro the web client.
01-23-2012 11:52 AM - last edited on 01-23-2012 11:58 AM
Thank you for verifying that composite formatting string syntax is what this property accepts. I'll update the help. I'll also check if it applies to the PickList control property, Name Format String, and the Aggregate control property, Popup Caption Format String.
Regarding the Editable Grid control: There are three examples in the help; the first example was intended to be very basic. The second example demonstrates the use of a child entity, and the third example demonstrates consuming an external feed. Let's correspond about more scenarios that should be covered in examples. And I'll submit your suggestion about an option to have an editible grid from the wizard.
Regarding Secure Actions, the drop down Applied Security lists only the secured actions provided in the base product and any that you have added through the Web Client (as of 7.5.4) See the Application Architect help topic, "Applied Security".