10-13-2023, 05:23 AM
(10-12-2023, 02:45 PM)Jack Wrote: @random1The whole program contains almost 30K lines of code. The code in question, the final step is shown below.
you are not showing the code of your program, the code I suggested will not print 7.000000000000001D-2 but .070, clearly you are doing something else there
show your code so that we can help
DCNT, K, KP and FT1 are _fload
K = (KP/FT1)
K$ = StrN$(K, 5, "f") 'RENAMED THE FUNCTION TO StrN$
DCNT(L2)=VAL(K$) ' K$ is stored in DCNT() as VAL(K$) 'I suspect this is my problem
The array DCNT() is dimmed as _float and has more than one purpose, I am thinking this is the problem.
What I need to do is create a string array to hold K$ instead of storing as VAL(K$)
Mixing data types is a major nemesis for me as I don't fully understand what goes on. After thinking about
I am sure that saving k$ as VAL(K$) is the problem, I will add a second string array to hold K$ and let you
know if it takes care of the problem.
R1