Page 27 of 32

Re: PurePDF Version 2.0

Posted: Tue Feb 04, 2014 2:10 pm
by loulou25223
Is it possible to use Purepdf on X64 computer ? If yes how can i do ?

Re: PurePDF Version 2.0

Posted: Tue Feb 04, 2014 3:51 pm
by ABBKlaus
Just use the XIncludeFile method. Some examples already have it on top but commented out.

Code: Select all

#PurePDF_Include=1
XIncludeFile "PurePDF.pb"
http://www.purebasicpower.de/downloads/ ... Actions.pb

Re: PurePDF Version 2.0

Posted: Tue Feb 04, 2014 8:24 pm
by loulou25223
ABBKlaus wrote:Just use the XIncludeFile method. Some examples already have it on top but commented out.

Code: Select all

#PurePDF_Include=1
XIncludeFile "PurePDF.pb"
http://www.purebasicpower.de/downloads/ ... Actions.pb
On X64
on compiling
---------------------------
PureBasic
---------------------------
Polink error unresolve external symbol "_compress"

Re: PurePDF Version 2.0

Posted: Tue Feb 04, 2014 8:45 pm
by ABBKlaus
What Version are you using ?

Code: Select all

Debug #PDF_VER ; should read 2.24
[Edit]Tutorial05 Compressed.pb corrected :

Code: Select all

ImportC #ZLIB_IMPORT_PATH
  CompilerIf #PB_Compiler_Processor = #PB_Processor_x86
    _compress.l(*dest, *destlen, *source, sourcelen) As "_compress"
  CompilerElse
    _compress.l(*dest, *destlen, *source, sourcelen) As "compress"
  CompilerEndIf
EndImport
loulou25223 wrote:On X64
on this ligne
---------------------------
PureBasic
---------------------------
Procedure.l PDFCompress(*aData.MEM_DataStructure)

Ligne 16: Structure introuvable: MEM_DataStructure.
How can i solve these problem ?
The Structure is present in PurePDF_res.pb which gets XIncluded in PurePDF.pb, but only if you are using the correct Version. Otherwise i have no clue why you are getting this error :?
[/Edit]

Re: PurePDF Version 2.0

Posted: Tue Feb 04, 2014 10:06 pm
by loulou25223
Thanks that works good now
Have a nice even ing

Re: PurePDF Version 2.0

Posted: Tue Feb 18, 2014 7:55 pm
by loulou25223
I have a problem with compressed
When i use it the programm fall down on this instruction :

Code: Select all

Procedure.l PDFCompress(*aData.MEM_DataStructure)
 Protected zerr,CompMem,SourceLen,SourceMem,CompLen,lbError
  
 lbError = #False
 SourceLen = *aData\lCurSize
 SourceMem = *aData\pData 
 CompLen   = Round(1.001 * SourceLen,#PB_Round_Up) + 12
 CompMem   = AllocateMemory(CompLen)
 If CompMem
  zerr=_compress(CompMem,@CompLen,SourceMem,SourceLen)
  If zerr = 0
      *aData\pData = CompMem
      *aData\lMaxSize = CompLen
      *aData\lCurSize = CompLen
     [b]FreeMemory(Sourcemem)[/b] error L'argument memoryid spécifié n'est pas valide 
      lbError = #True 
   EndIf
  EndIf
  ProcedureReturn lbError  
EndProcedure
with PDF 2.24 32 bits on a computer with Seven and PPUREPDF lib

Re: PurePDF Version 2.0

Posted: Tue Feb 18, 2014 8:39 pm
by ABBKlaus
loulou25223 wrote:I have a problem with compressed
When i use it the programm fall down on this instruction :

Code: Select all

...[b]FreeMemory(Sourcemem)[/b] error L'argument memoryid spécifié n'est pas valide ...
with PDF 2.24 32 bits on a computer with Seven and PPUREPDF lib
I have no Problems here with PB 5.11 / 5.21 LTS x86.

What PureBasic Version are you using ?

Re: PurePDF Version 2.0

Posted: Wed Feb 19, 2014 5:12 am
by loulou25223
I comment this instruction and after i have no problem all is good and the file is compressed well.
Is-it normal ?
Thanks for your answering

Re: PurePDF Version 2.0

Posted: Wed Feb 19, 2014 9:39 am
by DoubleDutch
YOu should check to see if SourceMem is zero at the beginning:

Code: Select all

Procedure.l PDFCompress(*aData.MEM_DataStructure)
 Protected zerr,CompMem,SourceLen,SourceMem,CompLen,lbError
  ;   check sourcemem here - see if it is zero!
 lbError = #False
 SourceLen = *aData\lCurSize
If it is zero then then you have a bug before PDFCompress.

Re: PurePDF Version 2.0

Posted: Thu Feb 20, 2014 11:04 am
by ABBKlaus
Is the Purifier enabled ? If yes you should use the includefile method instead of the lib.

[Edit]Workaround:

Code: Select all

      DisableDebugger
      FreeMemory(Sourcemem)
      EnableDebugger

Re: PurePDF Version 2.0

Posted: Mon Mar 03, 2014 8:06 am
by loulou25223
With PB 5.22 BETA
Error in PDF_COMPRESS() function
Structure aData.MEM_DataStructure introuvable
ABBKlauss can you see Please ?
Thanks in advance

Re: PurePDF Version 2.0

Posted: Wed Mar 05, 2014 9:02 pm
by ABBKlaus
I get the same errormessage in 'Tutorial05 Compressed.pb' saying 'Line 36: Structur not found: MEM_DataStructure.' when in the residents Folder the file 'PurePDF_res.res' is missing ;-)
Did i already mentioned the XIncludefile method ? :twisted:

Re: PurePDF Version 2.0

Posted: Tue Mar 18, 2014 1:47 am
by normeus
ABBKlaus,

I downloaded what I figured was the latest PurePDF. ( With the rest of the world using DD/MM/YYYY and USA using MM/DD/YYYY kind of gets difficult to figure out the right date :wink: ).

Version 2.25 for P.B.51 & P.B.52

Bookmarks are not working anymore.

Version 2.24 bookmarks work fine.


Norm.

Re: PurePDF Version 2.0

Posted: Sun Mar 23, 2014 3:31 pm
by ABBKlaus
normeus wrote:ABBKlaus,

I downloaded what I figured was the latest PurePDF. ( With the rest of the world using DD/MM/YYYY and USA using MM/DD/YYYY kind of gets difficult to figure out the right date :wink: ).

Version 2.25 for P.B.51 & P.B.52

Bookmarks are not working anymore.

Version 2.24 bookmarks work fine.


Norm.
Thanks for the finding and sorry for the delay.
Can you test this Version before i TailBite a new Version ?

http://www.purebasicpower.de/downloads/PurePDF.pb
http://www.purebasicpower.de/downloads/PurePDF_res.pb

BR Klaus

Re: PurePDF Version 2.0

Posted: Sun Mar 23, 2014 6:39 pm
by normeus
ABBKlaus,

Tried this version (v2.25 file date jan-29-2014) and bookmarks worked fine.
While testing bookmarks I mistakenly created a subbookmark without a parent.

Code: Select all

pdf_BookMark("Paragraph 1",2,-1) ; oops 2 without a 1
pdf_Cell(0,6,"Paragraph 1")
pdf_Ln(10)
pdf_BookMark("Paragraph 1.1",1,-1)
I got an:
[ERROR] The list doesn't have a current element.
in
Procedure ipdf_PutBookMarks()
lparent lru()
----
I think I would just make "2" a parent in case there were any children but then again since this was an error on the programmer side you could just return a pdf error "Child bookmark no parent".


Thank you,
Norm.