Am 11.08.2011 um 18:49 schrieb Greg Olson-Hyde:

> in your cards example where 'pfCurrentFile' is the PDF, I don't understand 
> the syntax to get pfCurrentFile saved, can you help please?

For Button2, write something like this in the Action event:

Sub Action()
  dim pdf as new MyDynapdfMBS
  
  create pdf
  
  dim pdfdata as string = pdf.GetBuffer
  
  dim file as FolderItem = GetFolderItem("test.pdf")
  dim bin as BinaryStream = BinaryStream.Create(file, true)
  bin.Write pdfdata
  bin.Close
  
  CurrentFile = new WebFile
  CurrentFile.Filename = "test.pdf"
  CurrentFile.MIMEType = "application/pdf"
  CurrentFile.Data = pdfdata
  CurrentFile.ForceDownload = true
  
  info.Text = Format(lenb(CurrentFile.Data)/1024, "0")+" KB"
  
  showurl(CurrentFile.url)
End Sub

So I put pdf data into a string variable and write to a file with a 
binarystream and later put it into the webfile object.

Greetings
Christian

-- 
See you in Frankfurt, Germany at the Real Studio Database Days

More details and registration here:
http://www.monkeybreadsoftware.de/realbasic/events/frankfurt-2011-event.shtml


_______________________________________________
Mbsplugins_monkeybreadsoftware.info mailing list
[email protected]
https://ml01.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info

Reply via email to