Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Assign print using to a string.
#9
Try: 

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
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. Tongue
Reply


Messages In This Thread
Assign print using to a string. - by eoredson - 03-30-2024, 03:29 AM
RE: Assign print using to a string. - by SMcNeill - 03-30-2024, 04:55 AM
RE: Assign print using to a string. - by eoredson - 03-31-2024, 11:23 PM
RE: Assign print using to a string. - by eoredson - 04-01-2024, 02:54 AM
RE: Assign print using to a string. - by SMcNeill - 04-01-2024, 06:04 AM
RE: Assign print using to a string. - by eoredson - 04-02-2024, 12:52 AM
RE: Assign print using to a string. - by SMcNeill - 04-02-2024, 01:36 AM
RE: Assign print using to a string. - by eoredson - 04-02-2024, 01:49 AM
RE: Assign print using to a string. - by SMcNeill - 04-02-2024, 02:56 AM



Users browsing this thread: 1 Guest(s)