Export single-page pdfs with page name
I've been looking for a script that:
- exports every page of an indesign file to a seperate single-page pdf (or other filetypes)
- names the pdf with the name of a page -> this is the hard part to find
The reason i could use it: i have a 200+ page file with productspecs. I would like to export every page with the correct productname. (extracting pdfs in acrobat is not a problem, but then i have to manually rename every file)
I'm not sure how to name the pages, as it's not a function in indesign. Ideal would be to be able to "tell" indesign: this textframe = the pagename, so it wouldn't be necessary to label the page seperately.
I'm not a scripter. I searched the forum and found some info on this already, but not a working script including automatic pagenaming.
I did found an old post where someone points to such a script, but i can't find it:
http://www.techplex.net/postsm40018_possible-to-name-pages.html#post40018
Did anyone ever made/found/used such a script?
(btw, a similar script for illustrator artboards would be very useful too!)
Any help appreciated!
scott zanelli made one years ago. does a fantastic job.
http://indesignsecrets.com/page-exporter-utility-peu-5-script-updated-for-cs3.php
Loic Aigon has written one...
http://www.loicaigon.com/blog/?p=876
as for illustrator artboards... don't know - have a look on the illustrator scripting forum.
Similar Messages
-
Export single Pages (as PDF) from a .indd file
Hi folks
i use ID CS2 and i'm trying to export single pages from an indd file (using C#).
i tried to make an example first and thats my code so far:
[CODE]
InDesign.Application App = (InDesign.Application) COMCreateObject("Indesign.Application");
InDesign.Document doc = App.ActiveDocument;
InDesign.Page page = (InDesign.Page)doc.Pages[1];
doc.Export(IdExportFormat.idPDFType, @"C:\indesignTestFile.pdf", false, "[High Quality Print]", "Some Comment", true);
[/CODE]
Now it says that the IdExportFormat command is not known.
any suggestions would be very great.
kind regardsthx for the quick answer. this piece of code is from a sample and i changed id to this one:
in the very top of the program - using InDesign (so that the idExportFormat works)
doc.Export(idExportFormat.idPDFType, "C:\\indesignTestFile.pdf", false, //object using)
now i have no idea what i should enter at object using
could you explain that to me a little bit further? do i have to make a constant var that has the value 1952403524 and then use idExportFormat.idPDFType as well or idExportFormat(1952403524)?
i haven't progged a while and i feel a little bit dumb right now =D so sorry for this newbie questions.
thanks for your help, i realy appreciate that
kind regards -
AS) export single page PDFs from multi-artboards
I'm not exactly sure where my new problem lies. I'm trying to save out single page PDFs from an Illustrator CS4 document with multiple artboards. Each artboard should become a PDF. I can get a multi page PDF, but when it saves single page files, I get white PDFs with error messages on them (I think it is saving .ai files with a .pdf extension).
this is where I am now (simplified, of course):
tell application "Adobe Illustrator"
set docName to name of current document
set itemNumber to 1
tell application "Finder" to set fileLoc to path to desktop as string
set pageCount to (count artboards in document docName)
tell current document
set allPlacedItems to placed items
repeat with h from 1 to (count of allPlacedItems)
set thisPlacedItem to item h of allPlacedItems
tell thisPlacedItem to embed
end repeat
set allTextItems to text frames
repeat with j from 1 to (count of allTextItems)
set thisTextItem to item j of allTextItems
tell thisTextItem to convert to paths
end repeat
end tell
repeat with i from 1 to pageCount
set pdfSaveOptions to {class:PDF save options, pdfXstandard:PDFX None, compatibility:Acrobat 6, preserve editability:false, generate thumbnails:false, optimization:false, acrobat layers:false, artboard range:i, view pdf:false, color downsampling:0, color resample:nodownsample, color compression:none, grayscale downsampling:0, grayscale resample:nodownsample, grayscale compression:none, monochrome downsampling:0, monochrome resample:nodownsample, monochrome compression:none, compress art:false, trim marks:false, registration marks:false, color bars:false, page info:false, page marks style:Roman, trim mark weight:trimmarkweight025, offset:6.0, bleed link:true, bleed offset:{0, 0, 0, 0}, color conversion id:none, color destination id:none, color profile id:include all profiles, trapped:false, font subset threshold:50.0}
set pdfName to docName & "TEST" & itemNumber & ".pdf"
set destFile to (fileLoc & pdfName) as string
save document 1 in file destFile as pdf with options pdfSaveOptions
set itemNumber to (itemNumber + 1)
end repeat
close current document without saving
end tell// Save the artboards to PDF.
var myDoc = app.activeDocument;
var original_filename = myDoc.name.toString();
// alert (myDoc.name.toString() )
// Get the folder location
var destFolder = Folder.selectDialog('Select the folder to save the PDF files to:');
// Get the number of artboards to export from a dialogue
var total = myDoc.artboards.length
// Number.selectDialogue('Total Number of Files to be made')
if (destFolder) {
for (i=0; i<total; i++)
var destFile = new File(destFolder+original_filename+"_"+i); // Assign incrementing filenames
var pdfSaveOptions = new PDFSaveOptions();
pdfSaveOptions.viewAfterSaving = false; // Don't want to see these fles in Reader
pdfSaveOptions.SaveMultipleArtboards = true;
var range = new String();
range = (i+1).toString();
pdfSaveOptions.artboardRange= range; // not Assign incrementing page range
myDoc.saveAs (destFile, pdfSaveOptions);
I've run this script on the 3 art board document the Adobe sample scripts create. It's a just different coloured star on each artboard.
This script appears to work in as far as I get 3 files with just one artboard showing when I open the files in Adobe Reader. Problem is when I open them in AI, I can see all the artwork is still there and even more stranger is the fact that the numbers are still 1,2,3 whereas in Reader it's just page i showing as page 1 each time.
This could be a problem when the application I'm writing generates an image structure from the files if it sticks the excess data onto the GPU (not sure if it will or not). If it includes all the data, also it just makes the Application footprint bigger by a 8 MB or so of unnecessary baggage. An issue for a 'light weight' app.
I noticed the export ExportArtboardsPhotoshop.jsx script has this line:
psdExportOptions.saveMultipleArtboards = true;
It works in that context but in PDF context it only works in terms of what Reader shows not what exists in the files. Good one Adobe… Makes me wonder what the Multiple art boards method did before AI had multiple art boards. How was AI dividing the objects?!
Also I really need a SaveAsCopy (non-existent I think) method or I'll have to keep reopening the original file and then doing SaveAs.
Back to manual duplicating files in finder, batch renaming, opening them all and deleting excess. Or export to PSD and get my dimensions right or just oversized (I can always down sample in the app)…
This is truly a painful exercise! -
How do I make two page spreads export correctly to pdf with a book file?
I have a book I am working on in the book pallet. I have several documents in the book and have it set to auto update page numbers and keep it all organized, which is all good. However, when I export to pdf, though the page numbers and order is correct, for some reason, if it is an odd number of pages I get spread, spread, single page, spread.
Just how the first page is always single, any last pages of a document that has an odd number of pages always gets singled out and the next document resumes in spread format. This is all in one pdf file, which I exported from the book pallet with none of the documents selected or open. I have the box for spreads checked, and it is doing spreads, but just not linking documents as spreads.You can use a multipage importer to import a single Page PDF into InDesign.
Create a single page PDF
Create a facing pages document the same size as your original file
Multi-page place the entire pdf into facing pages (automatically done by script)
Export entire book to PDF as spreads.
http://indesignsecrets.com/zanelli-releases-multipageimporter-for-importing-both-pdf-and-i ndd-files.php
I say to do this with a singe pages PDF - because I don't think it will import multiple InDesign files, you'd have to place them individually - and with my experience it takes longer to import multiple indesign files - so I just use a single pages PDF. -
Exporting to a PDF with facing pages
Please help, I have encounter a problem with InDesign CS4, which I didn't have with CS3 version.
When I export an InDesign document with facing pages into a PDF, it turns it into a PDF document with consecutive pages (spreads are broken into individual pages). I want to keep the facing pages format in PDF as well.
My document is an online newsletter, which can be printed on an office printer. Pages are letter size for convenience
Now, I tried to check "Spreads" in the export to PDF dialogue box and what happened is that Acrobat resized spreads containing 2 facing letter-size pages onto a single letter size page. The cover appears and prints fine, but all the spreads are downsized.
What am I doing wrong????Thank you very much, I went into Acorbat's file-properties and set it up there and it worked!
but for some reason I never had to change settings in Acrobat with InDesign CS3 documents -
Export or Rename PDFs with title based on content
I haven't done any scripting in Indesign before but it was suggested I pose this question to the scripting forum.
I created a template document using the Data Merge feature of Indesign. I used the template and Data Merge to create a file that has 700+ pages and each page really needs to be a stand alone document.
I know if I just use the export feature I can export each page as its own eps file. The problem is that when I do that they all have the same file name with a sequential number to differentiate them.
Is their a way to use one of the line items that is derived from the data merge file to name the files.
Basically, each of these pages is a different production part and rather than having 700+ files that are named prodpart_xxx.eps I would like to have each be named after its part number that can be found in the original excel file.var doc=app.activeDocument;<br />var pg = doc.pages;<br />for(i=0; i<pg.length; i++)<br />{<br /> app.epsExportPreferences.pageRange = String(pg[i].name);<br /> //maybe String is not useful, try without String() if you get a error<br /> var myName = pg[i].textFrames.item("AON").parentStory.contents;<br /> //i or 0, don't know, you know ;-)<br /> var myDirectory = "/Users/admin/Desktop/test/";<br /> var myFile = new File(myDirectory + myName + ".eps");<br /> doc.exportFile(ExportFormat.epsType, myFile, false);<br />}
-
Exporting Single Audio Track with Panning
Hi all,
Is there a way of exporting a single audio track with all the panning included?
All the FX seems to have been exported onto the track and it is also definatly stereo, its just there is no panning even though I have drawn the panning out in the automation!
Any help would be much appreciated!!!!Either use Solo and bounce or use a gain plug. Export is prefader.
-
Export schema and import with different name
Hi ,
I need your assistance guys,
I need to export a schema from a database and then import it with different name to another database. How can I do that?
I export it with the following command:
exp userid=system/PW file=May_02_Export.dmp log=May_02_Export.log owner=schema_name statistics="none"
Now I want to import it but with different name (schma_name).
RegardsDid you try FROMUSER and TOUSER option ?
E:\oracle\product\10.2.0\db_1\install>sqlplus / as sysdba
SQL*Plus: Release 10.2.0.1.0 - Production on Sat May 2 20:01:09 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to an idle instance.
SQL> startup
ORACLE instance started.
Total System Global Area 167772160 bytes
Fixed Size 1247900 bytes
Variable Size 71304548 bytes
Database Buffers 92274688 bytes
Redo Buffers 2945024 bytes
Database mounted.
Database opened.
SQL> create user fromuser identified by fromuser;
User created.
SQL> grant resource, create table, create session to fromuser;
Grant succeeded.
SQL> create user touser identified by touser;
User created.
SQL> grant resource, create table, create session to touser;
Grant succeeded.
SQL> conn fromuser/fromuser
Connected.
SQL> create table export_table(a char);
Table created.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
E:\oracle\product\10.2.0\db_1\install>exp fromuser/fromuser file=e:\a.dmp
Export: Release 10.2.0.1.0 - Production on Sat May 2 20:03:06 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
Export done in WE8MSWIN1252 character set and AL16UTF16 NCHAR character set
. exporting pre-schema procedural objects and actions
. exporting foreign function library names for user FROMUSER
. exporting PUBLIC type synonyms
. exporting private type synonyms
. exporting object type definitions for user FROMUSER
About to export FROMUSER's objects ...
. exporting database links
. exporting sequence numbers
. exporting cluster definitions
. about to export FROMUSER's tables via Conventional Path ...
. . exporting table EXPORT_TABLE 0 rows exported
. exporting synonyms
. exporting views
. exporting stored procedures
. exporting operators
. exporting referential integrity constraints
. exporting triggers
. exporting indextypes
. exporting bitmap, functional and extensible indexes
. exporting posttables actions
. exporting materialized views
. exporting snapshot logs
. exporting job queues
. exporting refresh groups and children
. exporting dimensions
. exporting post-schema procedural objects and actions
. exporting statistics
Export terminated successfully without warnings.
E:\oracle\product\10.2.0\db_1\install>imp help=y
Import: Release 10.2.0.1.0 - Production on Sat May 2 20:03:47 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
You can let Import prompt you for parameters by entering the IMP
command followed by your username/password:
Example: IMP SCOTT/TIGER
Or, you can control how Import runs by entering the IMP command followed
by various arguments. To specify parameters, you use keywords:
Format: IMP KEYWORD=value or KEYWORD=(value1,value2,...,valueN)
Example: IMP SCOTT/TIGER IGNORE=Y TABLES=(EMP,DEPT) FULL=N
or TABLES=(T1:P1,T1:P2), if T1 is partitioned table
USERID must be the first parameter on the command line.
Keyword Description (Default) Keyword Description (Default)
USERID username/password FULL import entire file (N)
BUFFER size of data buffer FROMUSER list of owner usernames
FILE input files (EXPDAT.DMP) TOUSER list of usernames
SHOW just list file contents (N) TABLES list of table names
IGNORE ignore create errors (N) RECORDLENGTH length of IO record
GRANTS import grants (Y) INCTYPE incremental import type
INDEXES import indexes (Y) COMMIT commit array insert (N)
ROWS import data rows (Y) PARFILE parameter filename
LOG log file of screen output CONSTRAINTS import constraints (Y)
DESTROY overwrite tablespace data file (N)
INDEXFILE write table/index info to specified file
SKIP_UNUSABLE_INDEXES skip maintenance of unusable indexes (N)
FEEDBACK display progress every x rows(0)
TOID_NOVALIDATE skip validation of specified type ids
FILESIZE maximum size of each dump file
STATISTICS import precomputed statistics (always)
RESUMABLE suspend when a space related error is encountered(N)
RESUMABLE_NAME text string used to identify resumable statement
RESUMABLE_TIMEOUT wait time for RESUMABLE
COMPILE compile procedures, packages, and functions (Y)
STREAMS_CONFIGURATION import streams general metadata (Y)
STREAMS_INSTANTIATION import streams instantiation metadata (N)
The following keywords only apply to transportable tablespaces
TRANSPORT_TABLESPACE import transportable tablespace metadata (N)
TABLESPACES tablespaces to be transported into database
DATAFILES datafiles to be transported into database
TTS_OWNERS users that own data in the transportable tablespace set
Import terminated successfully without warnings.
E:\oracle\product\10.2.0\db_1\install>imp system/oracle fromuser=fromuser touser=touser file=e:\a.d
Import: Release 10.2.0.1.0 - Production on Sat May 2 20:04:20 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
Export file created by EXPORT:V10.02.01 via conventional path
Warning: the objects were exported by FROMUSER, not by you
import done in WE8MSWIN1252 character set and AL16UTF16 NCHAR character set
. importing FROMUSER's objects into TOUSER
. . importing table "EXPORT_TABLE" 0 rows imported
Import terminated successfully without warnings.
E:\oracle\product\10.2.0\db_1\install>sqlplus touser/touser
SQL*Plus: Release 10.2.0.1.0 - Production on Sat May 2 20:04:36 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> desc export_table
Name Null? Type
A CHAR(1)
SQL>HTH
Aman.... -
Crazy can't export PDF with same name problems
I am experiencing a a very odd problem using:
ID CS4 6.0.6
Acrobat Pro 9.4.3
After running numerous tests, I've found that if I export a PDF from ID and select it in Finder...not open it...just highlight the darn file, ID will refuse to re-export that file with the same name saying I don't have perms or the file is in use. Since when does selecting a file in Finder constitute "in use?"
I can export every other format while the file is selected in Finder.
Is this normal? I have to deselect a PDF in Finder before saving a file of the same name?
Neglected to mention:
MacBookPro running OSX 10.6.7If running OSX 10.6.7
I think it is due to your Finder settings.
Using column view the .pdf file is generating a preview in the right column, thus it is in use and cannot be overwritten.
Try changing to list view and it is no longer in use.
Yes it is annoying when you prefer column view.
Nina Storm -
Export reports as pdf with a dynamic name
Hi all,
I am fairly new at APEX and this sums my situation and questions.
I created a small app that shows invoice information. I created a 'report query' and a 'rtf query layout' and was able to create a export button to save it as pdf.
2 questions arise:
- Can I assign the pdf name dynamically based on a row value (in my case the invoice number), and if possible , how do I go about to do that?
- can I create a "batch" to spawn these pdf files ? How would i do that?
Kind regards and thanks for your input.
JorgeHi all,
I am fairly new at APEX and this sums my situation and questions.
I created a small app that shows invoice information. I created a 'report query' and a 'rtf query layout' and was able to create a export button to save it as pdf.
2 questions arise:
- Can I assign the pdf name dynamically based on a row value (in my case the invoice number), and if possible , how do I go about to do that?
- can I create a "batch" to spawn these pdf files ? How would i do that?
Kind regards and thanks for your input.
Jorge -
Export report to PDF with RDC, ASP
<p>I use asp on windows 2003 server and Crystal reports XI, service pack 3.</p><p>When I export a report to a PDF file, it creates a 0kb file. No error messages are received. The directory allows for writing files. I can manually export a file via the viewer. When I try to open this file I get an error that another application is using the file (Crystal?)</p><p>Code I use:</p><p><%<br /> reportname = "Radar.rpt"<br /> ExportFileName = "Radar.PDF"<br /></p><p>If Not IsObject (session("oApp")) Then <br /> Set session("oApp") = Server.CreateObject("CrystalRuntime.Application.11")<br />End If </p><p>Path = MID(request.ServerVariables("PATH_TRANSLATED"), 1, (LEN(request.ServerVariables("PATH_TRANSLATED"))-22)) & "Reports\" </p><p>If IsObject(session("oRpt")) then<br /> Set session("oRpt") = nothing<br />End if</p><p>On error resume next</p><p>Set session("oRpt") = session("oApp").OpenReport(Path & reportname, 1)</p><p>session("oRpt").MorePrintEngineErrorMessages = False<br />session("oRpt").EnableParameterPrompting = False<br />'session("oRpt").DiscardSavedData</p><p>With session("oRpt").Database.Tables(1).ConnectionProperties <br />' .Item("DSN") = "test"<br /> .Item("User ID") = "test" <br /> .Item("Password") = "test" <br />End With <br /> session("oRpt").ParameterFields(1).AddCurrentValue(Cint(request.Querystring("CustomerID")))<br />End Select</p><p>If Err.Number <> 0 Then<br /> Response.Write "An Error has occured. Please check the ASP page.<BR>"<br /> Response.Write "Error " & Err.number & " " & Err.description & "<br>"<br /> Response.Write "Report: " & ReportName<br />End If</p><p>session("oRpt").ReadRecords<br />If Err.Number <> 0 Then <br /> Response.Write "Error Occurred Reading Records: " & Err.Description<br /> Set Session("oRpt") = nothing<br /> Set Session("oApp") = nothing<br /> Session.Abandon<br /> Response.End<br />Else<br /> If IsObject(session("oPageEngine")) Then <br /> set session("oPageEngine") = nothing<br /> End If<br /> set session("oPageEngine") = session("oRpt").PageEngine<br />End If</p><p>Set CrystalExportOptions = session("oRpt").ExportOptions<br />ExportDirectory = MID(request.ServerVariables("PATH_TRANSLATED"), 1, (LEN(request.ServerVariables("PATH_TRANSLATED"))-22)) & "Docs\"<br />ExportType = "31"<br />CrystalExportOptions.DiskFileName = ExportDirectory & ExportFileName<br />CrystalExportOptions.FormatType = CInt(ExportType)<br />CrystalExportOptions.DestinationType = CInt(1)<br />session("oRpt").Export False<br />%><br /></p><p> </p>
Hi Ludek,
I trid the SP, but doesn't work. I can send the font to you, it is only 50K. If you would like to try I can send it to you, but i am not sure how i can upload the font file. I guess any none Windows standard font will have same issue, i guess.
For now, i am going to give up and use image file instead.
Thanks,
Lan
Do you know if it is well-known issue in CR?
- No I do not.
where i can get any SP of CR for VS2008?
https://smpdl.sap-ag.de/~sapidp/012002523100009351512008E/crbasic2008sp1.exe
Runtimes for SP1:
CRRedist2008_ia64.msi
https://smpdl.sap-ag.de/~sapidp/012002523100006255262008E/CRRedist2008_ia64.zip
CRRedist2008_x64.msi
https://smpdl.sap-ag.de/~sapidp/012002523100006255272008E/CRRedist2008_x64.zip
CRRedist2008_x86.msi
https://smpdl.sap-ag.de/~sapidp/012002523100006255282008E/CRRedist2008_x86.zip
I would not mind testing this, but I need to know if there is a free download of this font available. I Googled the font name, but a quick search did not come up with anything.
Alternatively, you could try CR 2008 (12.x) and see if that will do the trick for you. An Eval of CR 2008 is available here:
http://www.sap.com/solutions/sapbusinessobjects/sme/freetrials/index.epx -
Bad files when exporting reports to PDF with CR4E
<p>Hello,</p><p>Have any of you successfully used CR4E to create a report and report viewer that produces a valid PDF export? I attempted this and the report looks fine, but when I export it to a PDF and attempt to open it, I get an Adobe Reader error message stating "There was an error opening this document. The file is damaged and could not be repaired." I am using Adobe Reader 7.0.8.</p><p>Thanks,</p><p>Matt</p>
<p>Thank you Sean! I am using WAS 6.0.2, but I can't verify the fix you mention as I am not sure which JSP I need to remove the whitespace from. Can you give me some more info on this? </p><p>I am experimenting with CR4E as I am in the architectural design stage for a new project, so I don't really understand the CR4E object model yet.  I created my report viewer JSP from the report, and the following JSP code was generated. I need to remove the white space from this JSP?</p><p>Thank you again.</p><p>Matt</p><font size="2" color="#bf5f3f"><%@</font><font size="2" color="#3f7f7f">page </font><font size="2" color="#7f007f">import</font><font size="2">=</font><font size="2" color="#2a00ff">"com.businessobjects.samples.JRCHelperSample,</font><font size="2" color="#2a00ff"> <p align="left">com.crystaldecisions.report.web.viewer.CrystalReportViewer,</p><p align="left">com.crystaldecisions.reports.sdk.ReportClientDocument,</p><p align="left">com.crystaldecisions.sdk.occa.report.application.OpenReportOptions,</p><p align="left">com.crystaldecisions.sdk.occa.report.lib.ReportSDKExceptionBase,</p><p align="left">com.crystaldecisions.sdk.occa.report.reportsource.IReportSource,</p><p align="left">com.faweb.Company,</p><p align="left">java.util.ArrayList,</p><p align="left">java.util.List"<font size="2" color="#bf5f3f">%><%</font></p></font><font size="2"><p align="left"><font size="2" color="#3f7f5f">// This sample code calls methods from the JRCHelperSample class, which </font></p></font><font size="2"><p align="left"><font size="2" color="#3f7f5f">// contains examples of how to use the BusinessObjects APIs. You are free to </font></p></font><font size="2"><p align="left"><font size="2" color="#3f7f5f">// modify and distribute the source code contained in the JRCHelperSample class. </font></p></font><font size="2" color="#7f0055">try</font>{ String reportName = "Report2.rpt";
ReportClientDocument clientDoc = (ReportClientDocument) session.getAttribute(reportName);
<font size="2" color="#7f0055">if</font>(clientDoc ==<font size="2" color="#7f0055">null</font>) {
// Report can be opened from the relative location specified in the CRConfig.xml, or the report location
// tag can be removed to open the reports as Java resources or using an absolute path
// (absolute path not recommended for Web applications).
clientDoc =<font size="2" color="#7f0055">new</font>ReportClientDocument();
// Open report
clientDoc.open(reportName, OpenReportOptions._openAsReadOnly);
// ****** BEGIN LOGON DATASOURCE SNIPPET ****************
// Database username and password
String userName = "db2inst1"; // TODO: Fill in database user
String password = "######"; // TODO: FIll in password
// logon to database
JRCHelperSample.logonDataSource(clientDoc, userName, password);
// ****** END LOGON DATASOURCE SNIPPET ****************
// ****** BEGIN POPULATE WITH POJO SNIPPET ****************
// **** POPULATE MAIN REPORT ***</font></p></font><font size="2"><p align="left">{</p><p align="left"><font size="2" color="#3f7f5f">// Populate POJO data source</font></p></font><font size="2">String className = </font><font size="2" color="#2a00ff">"com.faweb.Company"</font><font size="2">;</font><font size="2"> <p align="left"><font size="2" color="#3f7f5f">// Look up existing table in the report to set the datasource for and obtain its alias. This table must</font></p></font><font size="2"><p align="left"><font size="2" color="#3f7f5f">// have the same schema as the Resultset that is being pushed in at runtime. The table could be created</font></p></font><font size="2"><p align="left"><font size="2" color="#3f7f5f">// from a Field Definition File, a Command Object, or regular database table. As long the Resultset</font></p></font><font size="2"><p align="left"><font size="2" color="#3f7f5f">// schema has the same field names and types, then the Resultset can be used as the datasource for the table.</font></p></font><font size="2">String tableAlias = </font><font size="2" color="#2a00ff">"Company"</font><font size="2">;</font><font size="2"> <p align="left"><font size="2" color="#3f7f5f">//Create a dataset based on the class com.faweb.Company</font></p></font><font size="2"><p align="left"><font size="2" color="#3f7f5f">//If the class does not have a basic constructor with no parameters, make sure to adjust that manually</font></p></font><font size="2">List dataSet = </font>new<font size="2"> ArrayList();</font><font size="2"> <p align="left">dataSet.add(new* Company(0, "Dummy"));
// dataSet.add(new Company());
// dataSet.add(new Company());
// dataSet.add(new Company());
// dataSet.add(new Company());
//Push the resultset into the report (the POJO resultset will then be
the runtime datasource of the report)
JRCHelperSample.passPOJO(clientDoc, dataSet, className, tableAlias, "");
// ****** END POPULATE WITH POJO SNIPPET ****************
// Store the report document in session
session.setAttribute(reportName, clientDoc);
// ****** BEGIN CONNECT CRYSTALREPORTPAGEVIEWER SNIPPET ****************
// Create the CrystalReportViewer object
CrystalReportViewer crystalReportPageViewer =<font size="2" color="#7f0055">new</font>CrystalReportViewer();
// set the reportsource property of the viewer
IReportSource reportSource = clientDoc.getReportSource();
crystalReportPageViewer.setReportSource(reportSource);
// set viewer attributes
crystalReportPageViewer.setOwnPage(<font size="2" color="#7f0055">true</font>);crystalReportPageViewer.setOwnForm(<font size="2" color="#7f0055">true</font>);
// Apply the viewer preference attributes
// Process the report
crystalReportPageViewer.processHttpRequest(request, response, application,<font size="2" color="#7f0055">null</font>);
// ****** END CONNECT CRYSTALREPORTPAGEVIEWER SNIPPET ****************
// ****** BEGIN EXPORT PDF SNIPPET ***************</font></p></font><font size="2"><p align="left">{</p><p align="left">IReportSource reportSource = clientDoc.getReportSource();</p>JRCHelperSample.exportPDF(reportSource, request, response, config.getServletContext(), </font>true*);
// ****** END EXPORT PDF SNIPPET ***************</font></p></font><font size="2">} </font>catch* (ReportSDKExceptionBase e) {
out.println(e); -
Error when export report to PDF with a none standard Windows font
Hi,
I got this error when trying to export PDF under VS2008 with an special true type font in the code behind. The error says:
...temp_9550ab94-02fc-4362-b259-cc6de8d6c04b {32E546F5-C6A3-44FC-B8EF-D5E37A1118FA}.rpt:\nOperation not yet implemented.
In the crystal reort under VS2008, I use a special font which is true type and it is already installed in the system, I can see the font in many other software like Word, Notepad, etc... without any problem.
Is anyone know how to fix it? please help.
Many thanks!!!
LanHi Ludek,
I trid the SP, but doesn't work. I can send the font to you, it is only 50K. If you would like to try I can send it to you, but i am not sure how i can upload the font file. I guess any none Windows standard font will have same issue, i guess.
For now, i am going to give up and use image file instead.
Thanks,
Lan
Do you know if it is well-known issue in CR?
- No I do not.
where i can get any SP of CR for VS2008?
https://smpdl.sap-ag.de/~sapidp/012002523100009351512008E/crbasic2008sp1.exe
Runtimes for SP1:
CRRedist2008_ia64.msi
https://smpdl.sap-ag.de/~sapidp/012002523100006255262008E/CRRedist2008_ia64.zip
CRRedist2008_x64.msi
https://smpdl.sap-ag.de/~sapidp/012002523100006255272008E/CRRedist2008_x64.zip
CRRedist2008_x86.msi
https://smpdl.sap-ag.de/~sapidp/012002523100006255282008E/CRRedist2008_x86.zip
I would not mind testing this, but I need to know if there is a free download of this font available. I Googled the font name, but a quick search did not come up with anything.
Alternatively, you could try CR 2008 (12.x) and see if that will do the trick for you. An Eval of CR 2008 is available here:
http://www.sap.com/solutions/sapbusinessobjects/sme/freetrials/index.epx -
CRVS2010 Beta - Cannot export report to PDF with unicode characters
My report has some unicode data (Chinese), it can be previewed properly in the windows form report viewer. However, if I export the report document to PDF file, the unicode characters in exported file are all displayed as a square.
In the version of Crystal Report 2008 R2, it can export the Chinese characters to PDF when I select a Chinese font in report. But VS2010 beta cannot export the Chinese characters even a Chinese font is selected.Barry, what is the specific font you are using?
The below is a reformatted response from Program Management:
Using non-Chinese font with Unicode characters (Chinese) the issue is reproducible when using Arial font in Unicode characters field. After changing the Unicode character to Simsun (A Chinese font named 宋体 in report), the problem is solved in Cortez and CR both.
Ludek -
Printing my PDF with File name and Tags Stamped on
To Forum,
Possibly not a completely Apple related query, but if anyone know it would be great.
id like to print a PDF on my MBP with the File name and Tags applied to it stamped on the paper copy... or come to think of it, stamped on the PDF copy which i then print out with those stamps on. Either way will do. Any ideas? Its not immediately obvious when i look at the Printing Prefs box.This is an option built into various apps - Safari, Firefox, Microsoft Office.
There are "PDF Utils" that do this on PDFs one at a time. Can't find a specific one for Macs, but found 2 for Windows.
Maybe you are looking for
-
What's wrong with my printer? "Out of paper" error message is incorrect.(HP officejet 4215)
-
Need Help Getting A Context Free Grammar Generator Working
Hello, This is my first real programming excercise in a college programming class. I am trying to make a context free grammar generator. I keep getting this error: Exception in thread "main" java.lang.StringIndexOutOfBoundsException: String ind ex ou
-
I am a current user of XC 5.1.1.0 and I have a new PC. Can someone point me to the right procedure to uninstall XC from the old PC and install it on the new one? Thanks, Stan
-
Latest Material for ABAP certification.
Hi Gurus, I want the latest material for ABAP certification. The exam code is C_TAW12_04 Can anyone provide me the link?? Thanks in advance, Supriya
-
Hi, Could someone please advise on this issue: I have rendered off a set of PNG files with Alpha from 3DS Max with a view to creating a transparent background video. When I import into AE the background is transparent (toggle transparency grid works