Normal Topic having problem with decimals (Read 723 times)
debmckee
Full Member
***
Offline



Posts: 123
Joined: Oct 5th, 2011
having problem with decimals
Mar 27th, 2012 at 11:32pm
Print Post Print Post  
this is my command in my print file.

PrintString(@decimals(@formfieldValue("PO Line Items","le0",0),2),-1, VStartY, 0, "calibri", 14,0)// the 30 as in 1/30


Instead of printing " 30.00 it is printing .0030.  How do I fix it??
  
Back to top
 
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: having problem with decimals
Reply #1 - Mar 28th, 2012 at 2:59pm
Print Post Print Post  
Hello Deb,

That's not making much sense. If you add the following line of programming to your code what do you get in the Writeln() window

Code
Select All
Writeln(@decimals(@formfieldValue("PO Line Items","le0",0),2)) 



-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
debmckee
Full Member
***
Offline



Posts: 123
Joined: Oct 5th, 2011
Re: having problem with decimals
Reply #2 - Mar 28th, 2012 at 3:27pm
Print Post Print Post  
This is what shows in window


/.00
/.00


  
Back to top
 
IP Logged
 
debmckee
Full Member
***
Offline



Posts: 123
Joined: Oct 5th, 2011
Re: having problem with decimals
Reply #3 - Mar 28th, 2012 at 3:29pm
Print Post Print Post  
Ray,

It is the exact same code that we put in the sales memo file which I just copied over with the applicable name changes.  It works fine in Sales Memo

  
Back to top
 
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: having problem with decimals
Reply #4 - Mar 28th, 2012 at 6:50pm
Print Post Print Post  
Hello Deb,

Okay let's take this a step further. Change that Writeln to

Code
Select All
Writeln(@formfieldValue("PO Line Items","le0",0))  



and let me know what it gives as an output.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
debmckee
Full Member
***
Offline



Posts: 123
Joined: Oct 5th, 2011
Re: having problem with decimals
Reply #5 - Mar 29th, 2012 at 4:27pm
Print Post Print Post  
What I get with changed writeln is

/
/

  
Back to top
 
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: having problem with decimals
Reply #6 - Mar 29th, 2012 at 7:31pm
Print Post Print Post  
Hello Deb,

Are you sure that LE0 is the correct element in the subform for the value you want?

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged