Home | Forums | Contact | Search | Syndication  
 
 [login] [create account]   Thursday, August 14, 2025 
 
slxdeveloper.com Community Forums  
   
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
 Web Forums - SalesLogix Web Platform & Application Architect
Forum to discuss the use of the SalesLogix Web Platform, Client and Customer Portals, and the Application Architect (For version 7.2 and higher only). View the code of conduct for posting guidelines.
Forums RSS Feed


 Back to Forum List | Back to SalesLogix Web Platform & Application Architect | New ThreadView:  Search:  
 Author  Thread: How to format control type of numeric to show no decimals? (in 7.5)
Byrnes
Posts: 43
 
How to format control type of numeric to show no decimals? (in 7.5)Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 28 Oct 08 4:59 PM
I have a new detail tab against the Account entity and added a few numeric controls. I want only whole numbers displayed. No decimals, percents, etc. Tell me this is a simple option that I've just overlooked somewhere. All I see is 'Number', 'Percent', 'Decimal', and 'Scientific'.

Where's this set at?
[Reply][Quote]
Nick Hollis
Posts: 549
Top 10 forum poster: 549 posts
 
Re: How to format control type of numeric to show no decimals? (in 7.5)Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 29 Oct 08 4:22 AM
I havent looked in 7.5 but there is no property for this in all of the 7.2 releases. It is likely you will have to do this in the quickformload C# snippet..

Something like:
Sage.Entity.Interfaces.IAccount acc = this.BindingSource.Current as Sage.Entity.Interfaces.IAccount;

if (acc.YOURVALUE != null)
{
YOURTEXTCONTROL.Text = String.Format("{0:N}", acc.YOURVALUE);
}
YOURTEXTCONTROL.Attributes.Add("onkeypress", "if (((event.keyCode < 48) || (event.keyCode > 57)) & (event.keyCode != 46)) {event.returnValue = false;}");


Ive even added a javascript onkeypress event to the form item to disable users entering any text characters, as error handling is very poor in this respect on the web (it is in 7.2 anyway).
[Reply][Quote]
Nick Hollis
Posts: 549
Top 10 forum poster: 549 posts
 
Re: How to format control type of numeric to show no decimals? (in 7.5)Your last visit to this thread was on 1/1/1970 12:00:00 AM
Posted: 29 Oct 08 4:32 AM
I havent looked in 7.5 but there is no property for this in all of the 7.2 releases. It is likely you will have to do this in the quickformload C# snippet..

Something like:
Sage.Entity.Interfaces.IAccount acc = this.BindingSource.Current as Sage.Entity.Interfaces.IAccount;

if (acc.YOURVALUE != null)
{
YOURTEXTCONTROL.Text = String.Format("{0:d}", acc.YOURVALUE);
}
YOURTEXTCONTROL.Attributes.Add("onkeypress", "if (((event.keyCode < 48) || (event.keyCode > 57)) & (event.keyCode != 46)) {event.returnValue = false;}");


Ive even added a javascript onkeypress event to the form item to disable users entering any text characters, as error handling is very poor in this respect on the web (it is in 7.2 anyway).

Should work....if you cant find a property in 7.5 to set this.
[Reply][Quote]
 Page 1 of 1 
  You can subscribe to receive a daily forum digest in your user profile. View the site code of conduct for posting guidelines.

   Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
 

 
 slxdeveloper.com is brought to you courtesy of Ryan Farley & Customer FX Corporation.
 This site, and all contents herein, are Copyright © 2025 Customer FX Corporation. The information and opinions expressed here are not endorsed by Sage Software.

code of conduct | Subscribe to the slxdeveloper.com Latest Article RSS feed
   
 
page cache (param): 8/14/2025 5:33:44 AM