Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Can't Convert an INT to a String
#1
What is wrong with this line -

Code: (Select All)
    TempString$ = LTRIM(STR$(AYear%))

All variables are DIMed yet I get an Illegal string-number conversion error on that line. FWIW removing LTRIM has no effect on the error. This is driving me nuts.

Thanks

TR
Reply
#2
It should be:


Code: (Select All)
TempString$ = LTrim$(Str$(AYear%))
Reply
#3
I have days like this, no $'s in sight!
b = b + ...
Reply
#4
@James D Jarvis Thanks for being more observant than me. After a ton of bugs being squashed the little program appears to work.

@bplus Being in the UK, I never have $ only £.

TR
Reply
#5
(05-22-2022, 05:01 PM)TarotRedhand Wrote: @James D Jarvis Thanks for being more observant than me. After a ton of bugs being squashed the little program appears to work.

@bplus Being in the UK, I never have $ only £.

TR

I've spent hours rewriting subs tying to get them to work right and then I see I missed a "$" or typed "m" once out of dozens of times when I meant to use an n and the first version of the sub would have worked fine.
Reply




Users browsing this thread: 1 Guest(s)