?
Solved

crystal Int function not working

Posted on 2008-10-07
4
Medium Priority
?
614 Views
Last Modified: 2013-11-15
I created a function.  Inside I have two value. 1080.00  and  1062.00
I substract them; I display them using the int function. Still I get back a non-integer value: 18.00
I know it is pretty straght forward and very simple, but ... here I am asking
Any idea? anyone?
Thanks
All The Best

Yossele

Code:
--------------------------------------------
Local NumberVar MyStart := 1062.00;
Local NumberVar MyEnd   := 1080.00;
int (MyEnd - MyStart);
--------------------------------------------
 the result is  18.00  ( instead of  18 )
0
Comment
Question by:Yossele
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 45

Accepted Solution

by:
Kent Olsen earned 120 total points
ID: 22662289
Hi Yossele,

The int function doesn't control the display of a value.  It merely drops the fractional part of the value.

Rt-click on the field and select format -> number -> custom style.  Select "0" in the decimals field.


Kent
0
 
LVL 101

Assisted Solution

by:mlmcc
mlmcc earned 80 total points
ID: 22662861
Agree.

mlmcc
0
 

Author Closing Comment

by:Yossele
ID: 31503950
Thank you for such a prompt response.
Sometimes a simple answer will catapulte you toward a different search path where you find the solution.
Amaizing DIVINITY

Thanks
All The Best

Yossele
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 22664278
Yossele -  You really should have given all the points and the compliment to KDO.

KDO - Grading Comments:
Thank you for such a prompt response.
Sometimes a simple answer will catapulte you toward a different search path where you find the solution.
Amaizing DIVINITY

Thanks
All The Best

Yossele

I will reopen the question if you wish so you can grade it appropriately.

mlmcc
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hi, In my previous Article  (http://www.experts-exchange.com/Database/Reporting/A_15199-Introduction-to-Microstrategy.html)I discussed some basic understanding of Microstrategy that how we can get in Intro of Microstrategy (MSTR). Now it's tim…
Hello, In my precious Article  (http://www.experts-exchange.com/Database/Reporting/A_15280-Create-Project-in-Microstrategy-Part-I.html)we saw the Configuration part for Microstrategy which included Metadata Creation and DataSource Preparation as …
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question