04-02-2024, 01:36 AM
Try:
As I mentioned, just change the size of the NewImage so that it's large enough to hold the number of characters needed. If you need more than 32,000 characters (which is a little less than the actual limit, I think), you're doing something wrong. Break that damn line down into segments and process it one chunk at a time!
PS: I want to see the screen where you're printing your output to. What size monitor are you using for:
For x = 1 To 1024
x$ = x$ + Str$(x)
Next
Print Using "&"; x$
At a max of characters per value (space + 4 digit number + space), that's about 6000 characters. Since Print UUsing doesn't do word wrap, you'd almost expect to see all 6000 of those characters on a single line. At 8 pixels width, that's only 48000 pixels -- while Windows itself only allows *any* screen to be 32000 pixels...
Something seems wrong here, mate.
Code: (Select All)
Print FormatStr(String$(800, "#"), "&")
Function FormatStr$ (temp$, using$)
Static tempimage
If tempimage = 0 Then tempimage = _NewImage(10000, 1, 0)
d = _Dest: s = _Source
_Dest tempimage: _Source tempimage
Cls
Print Using using$; temp$;
For i = 1 To _Width
p = Screen(1, i)
If p = 0 Then Exit For
text$ = text$ + Chr$(p)
Next
_Dest d: _Source s
FormatStr$ = RTrim$(text$)
End Function
PS: I want to see the screen where you're printing your output to. What size monitor are you using for:
For x = 1 To 1024
x$ = x$ + Str$(x)
Next
Print Using "&"; x$
At a max of characters per value (space + 4 digit number + space), that's about 6000 characters. Since Print UUsing doesn't do word wrap, you'd almost expect to see all 6000 of those characters on a single line. At 8 pixels width, that's only 48000 pixels -- while Windows itself only allows *any* screen to be 32000 pixels...
Something seems wrong here, mate.