Page 1 of 1

Put Images into your Purebasic-Board-thread

Posted: Tue Mar 15, 2005 3:41 pm
by HeX0R
Code updated for 5.20+

Whenever you try to get help here on a code-example, and your code-example needs an image to be loaded, its a little annoying for others when they try to test your code.
Most of the time, they won't have your used image and get an error.

This one will help.
You select an Image and this little script will create an usable pb-source-code for you. (its in the clipboard afterwards).

Have fun

Code: Select all

UseJPEGImageDecoder()
UsePNGImageDecoder()
File$ = OpenFileRequester("Select Image", "", "All (*.*)|*.*", 0)
If File$
  Size.l = FileSize(File$)
  If LoadImage(0, File$) = 0
    MessageRequester("Error", GetFilePart(File$) + " is no Image, or not supported!")
    End
  EndIf
  FreeImage(0)
  If ReadFile(0, File$) = 0
    MessageRequester("Error", "Not able to read '" + File$ + "' !")
    End
  EndIf
  *Buffer = AllocateMemory(Size)
  If *Buffer = 0
    MessageRequester("Error", "Could not allocate " + StrF(Size / 1024, 2) + "kb Memory!")
    End
  EndIf
  ReadData(0, *Buffer, Size)
  CloseFile(0)
 
  Select LCase(GetExtensionPart(File$))
    Case "jpg"
      HeaderInclude.s = "UseJPEGImageDecoder()" + #CRLF$
    Case "png"
      HeaderInclude.s = "UsePNGImageDecoder()" + #CRLF$
    Default
      HeaderInclude.s = ""
  EndSelect

  Header.s = HeaderInclude
  Header   + ";-----------Usage-Example-----------" + #CRLF$
  Header   + "If CatchImage(0, ?MyImage) And OpenWindow(0, 1, 1, ImageWidth(), ImageHeight(), 0, " + Chr(34) + Chr(34) + ") And CreateGadgetList(WindowID())" + #CRLF$
  Header   + "  ImageGadget(0, 1, 1, ImageWidth(), ImageHeight(), UseImage(0))" + #CRLF$
  Header   + "  Repeat" + #CRLF$
  Header   + "  Until WaitWindowEvent() = #WM_CLOSE" + #CRLF$
  Header   + "EndIf" + #CRLF$
  Header   + "End" + #CRLF$
  Header   + ";-----------------------------------" + #CRLF$
  Header   + #CRLF$
  Header   + "DataSection" + #CRLF$
  Header   + "  MyImage:" + #CRLF$
 
  Footer.s = "EndDataSection" + #CRLF$
 
  Length_Total.l = Len(Header) + Len(Footer)
  Length_Total + (Int(Size / 8) + 1) * 11
  Length_Total + (Int(Size / 4) + 1) * 11
  If Length_Total > 102400 And MessageRequester("Warning!!", "The Data in the ClipBoard will be very big (" + StrF(Length_Total / 1024, 2) + " kB)" + Chr(10) + "Will you go on anyway ?", #PB_MessageRequester_YesNo) <> 6
    FreeMemory(*Buffer)
    End
  EndIf
  OpenClipboard_(0)
  *Handle = GlobalAlloc_(#GMEM_MOVEABLE, Length_Total + 100)
  If *Handle = 0
    MessageRequester("Error", "Could not allocate Global Memory!")
    FreeMemory(*Buffer)
    CloseClipboard_()
    End
  EndIf
  *Out_Buffer = GlobalLock_(*Handle)
  If *Out_Buffer = 0
    MessageRequester("Error", "Could not lock Global Memory!")
    CloseClipboard_()
    FreeMemory(*Buffer)
    End
  EndIf
  PokeS(*Out_Buffer, Header)
  Mem_Pointer.l = Len(Header)

  For p = 0 To Size Step 32
    Line.s = "  Data.l "
    For i = 0 To 7
      If (p + i * 4) > Size
        Break
      EndIf
      Long.l = PeekL(*Buffer + p + (i * 4))
      Line + "$" + RSet(Hex(Long), 8, "0") + ", "
    Next i
    Line = Left(Line, Len(Line) - 2) + #CRLF$
    PokeS(*Out_Buffer + Mem_Pointer, Line)
    Mem_Pointer + Len(Line)
  Next p
  PokeS(*Out_Buffer + Mem_Pointer, Footer)
  Mem_Pointer + Len(Footer)
  PokeB(*Out_Buffer + Mem_Pointer, 0)
  GlobalUnlock_(*Handle)
  EmptyClipboard_()
  SetClipboardData_(#CF_TEXT, *Handle)
  FreeMemory(*Buffer)
  CloseClipboard_()
  MessageRequester("O.K.", "Data is in ClipBoard and ready to rumble!")
EndIf

End


Here is an example of what it will produce:

Code: Select all

;-----------Usage-Example-----------
If CatchImage(0, ?MyImage) And OpenWindow(0, 1, 1, ImageWidth(0), ImageHeight(0), "", #PB_Window_ScreenCentered | #PB_Window_SystemMenu)
  ImageGadget(0, 1, 1, ImageWidth(0), ImageHeight(0), ImageID(0))
  Repeat
  Until WaitWindowEvent() = #WM_CLOSE
EndIf
End
;-----------------------------------

DataSection
  MyImage:
  Data.l $00010000, $20200001, $00000000, $08A80000, $00160000, $00280000, $00200000, $00400000
  Data.l $00010000, $00000008, $04800000, $00000000, $00000000, $01000000, $00000000, $00000000
  Data.l $00000000, $80000080, $80000000, $00800080, $00800000, $80800080, $C0C00000, $DCC000C0
  Data.l $CAF000C0, $FFCC00A6, $FF9900FF, $FF6600FF, $FF3300FF, $CCFF00FF, $CCCC00FF, $CC9900FF
  Data.l $CC6600FF, $CC3300FF, $CC0000FF, $99FF00FF, $99CC00FF, $999900FF, $996600FF, $993300FF
  Data.l $990000FF, $66FF00FF, $66CC00FF, $669900FF, $666600FF, $663300FF, $660000FF, $33FF00FF
  Data.l $33CC00FF, $339900FF, $336600FF, $333300FF, $330000FF, $00CC00FF, $009900FF, $006600FF
  Data.l $003300FF, $FFFF00FF, $FFCC00CC, $FF9900CC, $FF6600CC, $FF6600CC, $FF3300CC, $FF0000CC
  Data.l $CCFF00CC, $CCCC00CC, $CC9900CC, $CC6600CC, $CC3300CC, $CC0000CC, $99FF00CC, $99CC00CC
  Data.l $999900CC, $996600CC, $993300CC, $990000CC, $66FF00CC, $66CC00CC, $669900CC, $666600CC
  Data.l $663300CC, $660000CC, $33FF00CC, $33CC00CC, $339900CC, $336600CC, $333300CC, $330000CC
  Data.l $00FF00CC, $00CC00CC, $009900CC, $006600CC, $003300CC, $000000CC, $FFFF00CC, $FFCC0099
  Data.l $FF990099, $FF660099, $FF330099, $FF000099, $CCFF0099, $CCCC0099, $CC990099, $CC660099
  Data.l $CC330099, $CC000099, $99FF0099, $99CC0099, $99990099, $99660099, $99330099, $99000099
  Data.l $66FF0099, $66CC0099, $66990099, $66660099, $66330099, $66000099, $33FF0099, $33CC0099
  Data.l $33990099, $33660099, $33330099, $33000099, $00FF0099, $00CC0099, $00990099, $00660099
  Data.l $00330099, $00000099, $FFFF0099, $FFCC0066, $FF990066, $FF660066, $FF330066, $FF000066
  Data.l $CCFF0066, $CCCC0066, $CC990066, $CC660066, $CC330066, $CC000066, $99FF0066, $99CC0066
  Data.l $99990066, $99660066, $99330066, $99000066, $66FF0066, $66CC0066, $66990066, $66660066
  Data.l $66330066, $66000066, $33FF0066, $33CC0066, $33990066, $33660066, $33330066, $33000066
  Data.l $00FF0066, $00CC0066, $00990066, $00660066, $00330066, $00000066, $FFFF0066, $FFCC0033
  Data.l $FF990033, $FF660033, $FF330033, $FF000033, $CCFF0033, $CCCC0033, $CC990033, $CC660033
  Data.l $CC330033, $CC000033, $99FF0033, $99CC0033, $99990033, $99660033, $99330033, $99000033
  Data.l $66FF0033, $66CC0033, $66990033, $66660033, $66330033, $66000033, $33FF0033, $33CC0033
  Data.l $33990033, $33660033, $33330033, $33000033, $00FF0033, $00CC0033, $00990033, $00660033
  Data.l $00330033, $00000033, $FFCC0033, $FF990000, $FF660000, $FF330000, $CCFF0000, $CCCC0000
  Data.l $CC990000, $CC660000, $CC330000, $CC000000, $99FF0000, $99CC0000, $99990000, $99660000
  Data.l $99330000, $99000000, $66FF0000, $66CC0000, $66990000, $66660000, $66000000, $66330000
  Data.l $33FF0000, $33CC0000, $33990000, $33660000, $33330000, $33000000, $00CC0000, $00990000
  Data.l $00660000, $00330000, $00000000, $000000DD, $000000BB, $000000AA, $00000088, $00000077
  Data.l $00000055, $00000044, $DD000022, $BB000000, $AA000000, $88000000, $77000000, $55000000
  Data.l $44000000, $22000000, $DDDD0000, $555500DD, $77770055, $77770077, $44440077, $22220044
  Data.l $11110022, $00770011, $00550000, $00440000, $00220000, $FBF00000, $A0A400FF, $808000A0
  Data.l $00000080, $FF0000FF, $FF000000, $00FF00FF, $00FF0000, $FFFF00FF, $FFFF0000, $EFEF00FF
  Data.l $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $5DEFEFEF
  Data.l $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5DEFEF5D
  Data.l $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $5DEFEF5D
  Data.l $00000000, $0000E8E8, $00000000, $00000000, $00000000, $E8000000, $0000E8E8, $5DEFEF5D
  Data.l $E8000000, $0000FAFA, $00000000, $00000000, $00000000, $E8000000, $0000E8FA, $5DEFEF5D
  Data.l $FAE8E8E8, $0000E80C, $00000000, $00000000, $00000000, $E8E80000, $E8E80CFA, $5DEFEF5D
  Data.l $FAFAFAE8, $00E8E80C, $00000000, $00000000, $00000000, $FAE8E800, $FA0CE80C, $5DEFEF5D
  Data.l $E8E8E800, $E8E80CFA, $00000000, $00000000, $00000000, $0CFAE8E8, $000000E8, $5DEFEF5D
  Data.l $00000000, $E8FAFAE8, $E80000E8, $E800E800, $E8000000, $E8FAFAE8, $00000000, $5DEFEF5D
  Data.l $00000000, $FAFAE800, $E800E8E8, $FAE8FAE8, $E8E800E8, $E8E8FAFA, $000000E8, $5DEFEF5D
  Data.l $00000000, $FAE80000, $0000E8FA, $E8FAE8FA, $FAE80CFA, $E8E8E8FA, $000000E8, $5DEFEF5D
  Data.l $00000000, $E8000000, $E80000E8, $0CFAFAE8, $E8FA0CFA, $E8E8E8E8, $000000E8, $5DEFEF5D
  Data.l $00000000, $00000000, $E8000000, $FAE8FAFA, $E8FA0C0C, $E8E8E8E8, $000000E8, $5DEFEF5D
  Data.l $00000000, $00000000, $0000E8E8, $E8E8E8E8, $E8FAFA0C, $E8E8E8E8, $00000000, $5DEFEF5D
  Data.l $00000000, $E8000000, $E8E8FAFA, $E800E8E8, $FAFAE8FA, $E8E8E8E8, $00E8E8E8, $5DEFEF5D
  Data.l $00000000, $FAE80000, $FAFAFAFA, $FA0000E8, $FAFAFA0C, $E8E8E8FA, $00E8E8E8, $5DEFEF5D
  Data.l $00000000, $FAE80000, $E8E8E80C, $0C0000E8, $FAFAFA0C, $FAE8E8FA, $0000E8E8, $5DEFEF5D
  Data.l $00000000, $FAE80000, $0000E8E8, $000C0C00, $FAFA0000, $E8E8E8FA, $000000E8, $5DEFEF5D
  Data.l $00000000, $FAE80000, $000000E8, $000CFA00, $FA000000, $0000E8FA, $00000000, $5DEFEF5D
  Data.l $00000000, $E8E80000, $000000FA, $000CFAFA, $E8000000, $0000E8E8, $00000000, $5DEFEF5D
  Data.l $00000000, $E8E80000, $FAFAFAFA, $0C0C0C0C, $E8FAFA0C, $0000E8E8, $00000000, $5DEFEF5D
  Data.l $00000000, $E8E80000, $0CFAFAFA, $0CFFFF0C, $E8FAFA0C, $0000E8FA, $00000000, $5DEFEF5D
  Data.l $00000000, $E8E8E800, $0CFAE8E8, $0CFFFF0C, $E8FAFA0C, $00E8E8E8, $00000000, $5DEFEF5D
  Data.l $00000000, $E8E8E8E8, $FAE8E8FA, $0C0C0C0C, $FAE8E8FA, $E8E8FAE8, $00000000, $5DEFEF5D
  Data.l $E8000000, $E80CFAE8, $E8E8FAE8, $E8E8E8E8, $FAE8E8E8, $FA0CE8E8, $00E8E8E8, $5DEFEF5D
  Data.l $E8E8E8E8, $00E80CFA, $E8E8FAE8, $E8E8FAFA, $E8E8E8FA, $0CE80000, $E8FAFAFA, $5DEFEF5D
  Data.l $FAFAFAE8, $0000E80C, $E8E8E8E8, $E8E8FAE8, $E8E8E8E8, $E8000000, $E80C0CE8, $5DEFEF5D
  Data.l $FAE8E800, $000000FF, $E8E80000, $E8E8E8E8, $0000E8E8, $E8000000, $00E8FFFA, $5DEFEF5D
  Data.l $0CE80000, $0000000C, $00000000, $00000000, $00000000, $E8000000, $00000CFA, $5DEFEF5D
  Data.l $E8000000, $00000000, $00000000, $00000000, $00000000, $00000000, $000000E8, $5DEFEF5D
  Data.l $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $5D5D5D5D, $EFEFEF5D
  Data.l $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $EFEFEFEF, $0000EFEF
  Data.l $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000
  Data.l $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000
  Data.l $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000
  Data.l $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000, $00000000
EndDataSection

Re: Put Images into your Purebasic-Board-thread

Posted: Tue Mar 15, 2005 5:09 pm
by NoahPhense
Very nice.. I will find a use for this..

- np

Posted: Tue Mar 15, 2005 5:20 pm
by Tommeh
Wow HeXOR, that is very very usfull... Thanks a bunch :D

Just out of curiosity, would it be possible to store it in binary format?

Thanks for the code... will look into it more later :)

Posted: Tue Mar 15, 2005 5:24 pm
by Tommeh
I tried this but of course didnt work :p

Change:

Line + "%" + RSet(Bin(Long), 8, "0") + ", "

From:

Line + "$" + RSet(Hex(Long), 8, "0") + ", "

Posted: Tue Mar 15, 2005 5:42 pm
by El_Choni
Shouldn't it be?:

Code: Select all

 Line + "%" + RSet(Bin(Long), 32, "0") + ", " 

Posted: Tue Mar 15, 2005 5:43 pm
by Tommeh
Yeah ;)

But of course thats too big for the clipboard :(

Posted: Tue Mar 15, 2005 5:56 pm
by NoahPhense
Tommeh wrote:Yeah ;)

But of course thats too big for the clipboard :(
I blew up PB by pasting 5mbs into the IDE.. ;)

- np

Re: Put Images into your Purebasic-Board-thread

Posted: Tue Mar 15, 2005 7:52 pm
by PB
> its a little annoying for others when they try to test your code.
> Most of the time, they won't have your used image and get an error

That's why my examples always link to the example images and icons in
PureBasic's folders, so they're guaranteed to be there for the code to load.
Makes it easier for others to just copy-and-paste my code and know that
it'll compile without needing changes. See my reply here for an example:

viewtopic.php?t=14238

Posted: Tue Mar 15, 2005 9:31 pm
by ABBKlaus
and can use compression too (*.BMP) :wink:

Code: Select all

#GMEM_MOVEABLE  = $02 

UseJPEGImageDecoder() 
UsePNGImageDecoder() 
File$ = OpenFileRequester("Select Image", "", "All (*.*)|*.*", 0) 
If File$ 
  Size.l = FileSize(File$) 
  If LoadImage(0, File$) = 0 
    MessageRequester("Error", GetFilePart(File$) + " is no Image, or not supported!") 
    End 
  EndIf 
  FreeImage(0) 
  If ReadFile(0, File$) = 0 
    MessageRequester("Error", "Not able to read '" + File$ + "' !") 
    End 
  EndIf 
  *Buffer = AllocateMemory(Size) 
  If *Buffer = 0 
    MessageRequester("Error", "Could not allocate " + StrF(Size / 1024, 2) + "kb Memory!") 
    End 
  EndIf 
  ReadData(*Buffer, Size) 
  CloseFile(0)
  
  Select LCase(GetExtensionPart(File$)) 
    Case "jpg" 
      Header.s = "UseJPEGImageDecoder()" + #CRLF$ 
    Case "png" 
      Header.s = "UsePNGImageDecoder()" + #CRLF$ 
    Default 
      Header.s = "" 
  EndSelect 
  
  Header   + ";-----------Usage-Example-----------" + #CRLF$ 

  *BufferPack = AllocateMemory(Size+8)
  PackSize=PackMemory(*Buffer,*BufferPack,Size,9)
  If PackSize
    Debug "PackMemory successfull"
    FreeMemory(*Buffer)
    *Buffer=*BufferPack
    Header   + "*Buffer = AllocateMemory("+Str(Size)+")" + #CRLF$
    Header   + "UnpackMemory(?MyImage,*Buffer)" + #CRLF$
    Header   + "If CatchImage(0, *Buffer) And OpenWindow(0, 1, 1, ImageWidth(), ImageHeight(), 0, " + Chr(34) + Chr(34) + ") And CreateGadgetList(WindowID())" + #CRLF$ 
    Header   + "  ImageGadget(0, 1, 1, ImageWidth(), ImageHeight(), UseImage(0))" + #CRLF$ 
    Header   + "  Repeat" + #CRLF$ 
    Header   + "  Until WaitWindowEvent() = #WM_CLOSE" + #CRLF$ 
    Header   + "EndIf" + #CRLF$ 
    Header   + "FreeMemory(*Buffer)" + #CRLF$
    Size=PackSize
  Else
    Debug "PackMemory failed"
    Header   + "If CatchImage(0, ?MyImage) And OpenWindow(0, 1, 1, ImageWidth(), ImageHeight(), 0, " + Chr(34) + Chr(34) + ") And CreateGadgetList(WindowID())" + #CRLF$ 
    Header   + "  ImageGadget(0, 1, 1, ImageWidth(), ImageHeight(), UseImage(0))" + #CRLF$ 
    Header   + "  Repeat" + #CRLF$ 
    Header   + "  Until WaitWindowEvent() = #WM_CLOSE" + #CRLF$ 
    Header   + "EndIf" + #CRLF$ 
  EndIf
  
  Header   + "End" + #CRLF$ 
  Header   + ";-----------------------------------" + #CRLF$ 
  Header   + #CRLF$ 
  Header   + "DataSection" + #CRLF$ 
  Header   + "  MyImage:" + #CRLF$ 
  
  Footer.s = "EndDataSection" + #CRLF$ 
  
  Length_Total.l = Len(Header) + Len(Footer) 
  Length_Total + (Int(Size / 8) + 1) * 11 
  Length_Total + (Int(Size / 4) + 1) * 11 
  If Length_Total > 102400 And MessageRequester("Warning!!", "The Data in the ClipBoard will be very big (" + StrF(Length_Total / 1024, 2) + " kB)" + Chr(10) + "Will you go on anyway ?", #PB_MessageRequester_YesNo) <> 6 
    FreeMemory(*Buffer) 
    End 
  EndIf 
  OpenClipboard_(0) 
  *Handle = GlobalAlloc_(#GMEM_MOVEABLE, Length_Total + 100) 
  If *Handle = 0 
    MessageRequester("Error", "Could not allocate Global Memory!") 
    FreeMemory(*Buffer) 
    CloseClipboard_() 
    End 
  EndIf 
  *Out_Buffer = GlobalLock_(*Handle) 
  If *Out_Buffer = 0 
    MessageRequester("Error", "Could not lock Global Memory!") 
    CloseClipboard_() 
    FreeMemory(*Buffer) 
    End 
  EndIf 
  PokeS(*Out_Buffer, Header) 
  Mem_Pointer.l = Len(Header) 

  For p = 0 To Size Step 32 
    Line.s = "  Data.l " 
    For i = 0 To 7 
      If (p + i * 4) > Size 
        Break 
      EndIf 
      Long.l = PeekL(*Buffer + p + (i * 4)) 
      Line + "$" + RSet(Hex(Long), 8, "0") + ", " 
    Next i 
    Line = Left(Line, Len(Line) - 2) + #CRLF$ 
    PokeS(*Out_Buffer + Mem_Pointer, Line) 
    Mem_Pointer + Len(Line) 
  Next p 
  PokeS(*Out_Buffer + Mem_Pointer, Footer) 
  Mem_Pointer + Len(Footer) 
  PokeB(*Out_Buffer + Mem_Pointer, 0) 
  GlobalUnlock_(*Handle) 
  EmptyClipboard_() 
  SetClipboardData_(#CF_TEXT, *Handle) 
  FreeMemory(*Buffer) 
  CloseClipboard_() 
  MessageRequester("O.K.", "Data is in ClipBoard and ready to rumble!") 
EndIf 

End 
Example with 120x47 BMP file :

Code: Select all

;-----------Usage-Example-----------
*Buffer = AllocateMemory(816)
UnpackMemory(?MyImage,*Buffer)
If CatchImage(0, *Buffer) And OpenWindow(0, 1, 1, ImageWidth(), ImageHeight(), 0, "") And CreateGadgetList(WindowID())
  ImageGadget(0, 1, 1, ImageWidth(), ImageHeight(), UseImage(0))
  Repeat
  Until WaitWindowEvent() = #WM_CLOSE
EndIf
FreeMemory(*Buffer)
End
;-----------------------------------

DataSection
  MyImage:
  Data.l $0330434A, $23600000, $A9B3EE79, $146920D0, $CA120819, $2F4AF008, $2453BC25, $86040201
  Data.l $3FE8B03B, $F0011805, $FA7E3041, $C08008FF, $FF0062FF, $E18495FB, $44D3C0CF, $122A2F82
  Data.l $473F0FFF, $003189C0, $9A27C89E, $24016108, $91A4C118, $B8B00B02, $5160F8F0, $043C8270
  Data.l $1361DC61, $8D0F8008, $267803C2, $0E8E4D89, $DC811372, $01359C04, $80B0A3A6, $51C21A40
  Data.l $E3088370, $188A2DA0, $6FC16605, $DAFE44D1, $8A1C1601, $C22AC412, $C20C085F, $01633838
  Data.l $0473A487, $5913085E, $3202F088, $414F008E, $C19C47D8, $058D0237, $45CF1461, $381CA10F
  Data.l $3F080115, $E0266107, $C0D841D0, $C239B060, $0C264178, $73F8804D, $6F059E04, $11618E11
  Data.l $A007B808, $28400BE0, $12463082, $F840A020, $0000C025, $00008910
EndDataSection

Posted: Wed Mar 16, 2005 12:35 pm
by HeX0R
I guess it should be

Code: Select all

    Header   + "FreeMemory(*Buffer)" + #CRLF$
instead of

Code: Select all

    Header   + "FreeMemory(*Buffer1)" + #CRLF$ 
    Header   + "FreeMemory(*Buffer2)" + #CRLF$

Posted: Wed Mar 16, 2005 12:56 pm
by dagcrack
Whats with the character field from the RSet function? it wont work! which version of PB do I need?

Posted: Wed Mar 16, 2005 10:04 pm
by ABBKlaus
@HeXOR ,

you are right :oops: (fixed)

@dagcrack ,

what do you mean ?
Whats with the character field from the RSet function? it wont work! which version of PB do I need?

Code: Select all

  Length_Total + (Int(Size / 32) + 1) * 287 ; 287 Chars per row for BIN is needed (32 Bytes)

Code: Select all

      Line + "%" + RSet(Bin(Long),32,"0") + ", " 

Posted: Thu Mar 17, 2005 1:30 am
by NoahPhense
repost the code, and i'll make a library for ya..

- np

Posted: Thu Mar 17, 2005 8:41 am
by Rings
NoahPhense wrote:repost the code, and i'll make a library for ya..

- np
lol

Posted: Thu Mar 17, 2005 7:06 pm
by NoahPhense
Rings wrote:
NoahPhense wrote:repost the code, and i'll make a library for ya..

- np
lol
I thought it was kinda funny.. :lol: