Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Here's Print Using Mismatch error
#11
(01-14-2024, 02:05 PM)SMcNeill Wrote:
Code: (Select All)
Print Using "In the year ####, & was ## years old."; 1973, "Steve", 0

Just like the above, which is a little more obvious when tossed into a sentence like so, for us.  Wink
The comma is wrong here.  Wink

Code: (Select All)

Print Using "In the year #### & was ## years old."; 1973, "Steve", 0 
Reply
#12
One can also "Print Using" separate.

Code: (Select All)

Option _Explicit

Dim As Integer i
Dim As Double salary

Randomize Timer
For i = 1 To 12
  Print Using "& ##"; "Month"; i;
  salary = (Rnd * 500) + 2800
  Print " : "; Using "###,#.##"; salary
Next i

End
Reply
#13
@SMcNeill: I can't find any reference to the freq() that you used anywhere, but it doesn't error out - what is it, and what does it do?  Huh
Of all the places on Earth, and all the planets in the Universe, I'd rather live here (Perth, W.A.) Big Grin
Please visit my Website at: http://oldendayskids.blogspot.com/
Reply
#14
(01-15-2024, 01:15 AM)PhilOfPerth Wrote: @SMcNeill: I can't find any reference to the freq() that you used anywhere, but it doesn't error out - what is it, and what does it do?  Huh

No idea.  It was part of Dimster's original code.  If I had to guess, I'd bet on it being a function or array used elsewhere in his code and which just kinda got copied/pasted over with what he was questioning over.  Wink
Reply
#15
Yep, that sounds reasonable. Thanks.
Of all the places on Earth, and all the planets in the Universe, I'd rather live here (Perth, W.A.) Big Grin
Please visit my Website at: http://oldendayskids.blogspot.com/
Reply
#16
Hi Phil.  ya, freq() is an array. I'm trying to design a distribution chart. freq() is intended to hold the frequency of multiple event occurrences.
Reply




Users browsing this thread: 3 Guest(s)