Distribute eps objects with file list and quantity

Hello everyone,
Here's a script i wrote so I share it for the contribution.
Here's my purpose. Every year, for a customer of our company, we have to print several description plates for their products. They give us about 30 or more texts, traduced in about 7 languages, and an excel file with quantities that each retail seller of each country do want to receive.
We print these aluminium plates on a uv cured ink printing machine which have a table dimension of about 60x40cm. Preparing manually every files of 60x42cm to print was way too much time devouring, so i wrote that script.
Before running this script you have to create a folder with your text files in eps, and create a new document with the dimension you want.
Don't hesitate if you want more precisions with the process.
#target illustrator
#targetengine session
This script allows you to import EPS files as linked files. It distributes them and centers the all according to the dimension of the artboard of your document, then it saves the file.
You can define everything in the start list : target folder, basename of the destination files, how much objects per sheet you want, the roation if necessary, spacing between each objects, number of culumn for the distribution.
If you want to distribute a number of objects that is bigger thant the limit of objects per sheet, the script reports the remaining in a new sheet after saving the previous one.
The first 2 arrays contains the filenames to use in the source folder and their respective quantity.
var doc = app.activeDocument;
doc.rulerOrigin = [0,0];
var xtimes = 0;
var countName;
var folder;
var folder2;
//var folder = 'C:\\Documents and Settings\\Administrateur\\Bureau\\BBB\\';
// array for filenames
var listEx=new Array (
"File1.eps",
"File2.eps",
"File3.eps",
// array for quantity for each filenames
var listqte=new Array (
15,
8,
19,
//-------------UI CODE------------
var win = new Window ("dialog");
win.alignChildren = "left";
// ------Folders selection panel
var foldPanel = win.add("panel");
foldPanel.alignChildren = "right";
// source folder for files
var panelGrp1 = foldPanel.add("group");
var btnSource = panelGrp1.add("button",undefined,"Source Folder :");
var txtSource = panelGrp1.add("edittext",undefined);
txtSource.characters = 40;
btnSource.onClick = function()
    folder2 = Folder.selectDialog ("Select Source folder..."); // get the source folder
    txtSource.text = folder2.fsName; // show the file Path here
// destination folder
var panelGrp2 = foldPanel.add("group");
var btnSave = panelGrp2.add("button",undefined,"Save Folder :");
var txtSave = panelGrp2.add("edittext",undefined);
txtSave.characters = 40;
btnSave.onClick = function()
    folder = Folder.selectDialog ("Select Destination folder..."); // get the source folder
    txtSave.text = folder.fsName; // show the file Path here
// Base name for destination files
var panelGrp3 = foldPanel.add("group");
panelGrp3.alignment = "left";
var bfn = panelGrp3.add("statictext",undefined,"Basename of target file :");
var txtbfn = panelGrp3.add("edittext",undefined,"Description plates - UK");
txtbfn.characters = 20;
        // other parameters
        var grp = win.add("group");
        grp.alignChildren = "left";
        grp.orientation = "column";
        // counter
        var wincount = grp.add("group");
        var textcount = wincount.add("edittext",undefined,0);
        textcount.characters=2;
        wincount.add("statictext",undefined,"Start count");
        //Limit number of placeditems to distribute in one file
        var winlimit = grp.add("group");
        var textlimit = winlimit.add("edittext",undefined,0);
        textlimit.characters=2;
        winlimit.add("statictext",undefined,"Limit");
        //number of Columns for the distribution
        var wincolon = grp.add("group");
        var textcolon = wincolon.add("edittext",undefined,0);
        textcolon.characters=2;
        wincolon.add("statictext",undefined,"Nb of columns");
        // Spacing values between each objects in mm
        var winspace = grp.add("panel",undefined,"Spacing in mm");
        winspace.orientation = "row";
        winspace.add("statictext",undefined,"X");
        var Xspace=winspace.add("edittext",undefined,0);
        Xspace.characters=7;
        winspace.add("statictext",undefined,"Y",undefined,0);
        var Yspace=winspace.add("edittext");
        Yspace.characters=7;
        // rotation angle
        var winrotate = grp.add("group");
        var textangle = winrotate.add("edittext",undefined,0);
        textangle.characters=3;
        winrotate.add("statictext",undefined,"Rotation in °");
// Dropdownlist of presets   
var winPreset =grp.add ("dropdownlist", undefined, [ "Description plates","Trapezes plates","-","Perso"]);
winPreset.onChange = function ()
    switch (winPreset.selection.text)
                case "Description plates":
                        textlimit.text=8;
                        textcolon.text=4;
                        Xspace.text=6.4;
                        Yspace.text=27;
                        textangle.text=0;
                        break;
                case "Trapezes plates":
                        textlimit.text=18;
                        textcolon.text=6;
                        Xspace.text=9;
                        Yspace.text=9;
                        textangle.text=0;
                        break;
                case "Perso":
                        textlimit.text=0;
                        textcolon.text=0;
                        Xspace.text=0;
                        Yspace.text=0;
                        textangle.text=0;
                        break;
//winPreset.selection=1;
var runBT=grp.add("button",undefined,"Run !");
runBT.onClick = function()
    win.close();
    moteur();
win.show();
//--------------------End of UI CODE----------------
//---------------------------------fonction  Placement of objects
function place()
    var paddingx = parseFloat(Xspace.text)*2.834;        //spacing in mm between each column (for a value in points just suppress the *2.834)
    var paddingy = parseFloat(Yspace.text)*2.834;        //spacing in mm between each line
    var gridCols = textcolon.text;                            // number of columns
    var newGroup = doc.groupItems.add();
    var sel = doc.placedItems;
    // set the position of the first element, assuming that the group of all elements are centered  in X and Y  in the artboard
    var originX = (doc.width - ((doc.width - ((sel[0].width * gridCols) + (paddingx) * (gridCols-1)))/2))-sel[0].width
    var originY =((doc.height - (( sel[0].height * (textlimit.text/gridCols) ) +  (  paddingy*( (textlimit.text/gridCols)-1 )  )))/2)+sel[0].height
    var currentX= originX
    var currentY = originY
    for(var e=0, slen=sel.length;e<slen;e++)       
            //   :::SET POSITIONS:::
            sel[e].top = currentY;
            sel[e].left = currentX;
            //  :::DEFINE X POSITION:::
            currentX += -(sel[e].width + paddingx);
            if((e % gridCols) == (gridCols - 1))
                    currentX =  originX
                    //  :::DEFINE Y POSITION:::
                    currentY  += sel[e].height+paddingy;
            // ::Add to group
            sel[e].moveToBeginning (newGroup );
            redraw()
//----------------------function Save
function sauve()
    var fich =  txtbfn.text;    //Basename of the destination file
    // embed elements (for my case these are eps placeditem files)   
    for (var i = doc.placedItems.length-1; i >= 0; i-- )
            app.activeDocument.placedItems[i].embed();
    // draw a rectangle with the dimensions of the artboard and centered to it, with no fill color neither stroke color
    doc.rulerOrigin = [0,0];  // rulers to the origin
    var artboardRef = doc.artboards[0];
    // read dimensions oh the artboard to position therectangle
    var top=artboardRef.artboardRect[1] ;
    var left=artboardRef.artboardRect[0];
    var width=artboardRef.artboardRect[2]-artboardRef.artboardRect[0];
    var height=artboardRef.artboardRect[1]-artboardRef.artboardRect[3];
    var rect = doc.pathItems.rectangle (top, left, width, height);   
    rect.stroked = false;
    rect.filled = false;
    countName ++;
    // when several files are saved, the ten first files are numbered like this : 01, 02, 03... instead of 1,2,3
    var countName2 = countName;
    if (countName<=9) { countName2 = ("0" + countName)};
    if (xtimes != 0) // saves in eps, basename of file + number of times to repeat if necessary (it's to avoid to save several but identical files. For ex. if i have an object to print 100 times and i place 50 objects per file, the mention "2 times" will be mentionned in the name of the destination file )
            var dest= new File(folder + '/' + fich + ' ' + countName2 + ' - ' + xtimes + ' times' + '.eps');
    else
            var dest= new File(folder+ '/' + fich + ' ' + countName2 + '.eps') ;
    var options = new EPSSaveOptions();
    options.preview  = EPSPreview.None;
    //options.compatibility = Compatibility.ILLUSTRATOR14;
    //options.overprint = PDFOverprint.DISCARDPDFOVERPRINT
    //options.embedAllFonts = false;
    //options.includeDocumentThumbnails = false
    doc.saveAs(dest, options);
//-------------------- function moteur
function moteur()
    var limite = textlimit.text;            // max number of objects to distribute in one sheet
    var couchangl = textangle.text;    // rotation angle of the element
    //--------------Searches and signals if there is missing files in the source folder. If so, the script stops and displays which files are missing
    var miss=new Array();
    for (var i=0,len1=listEx.length;i<len1;i++)
        var myfile = new File(folder2+'/'+listEx[i]);
        if (myfile.exists==false)
                miss.push(listEx[i]);
    if (miss.length != 0)
            alert (miss.length+" missing files : "+"\r"+miss.join(", "+"\r")+"\r"+"\r"+" Please correct and try again");
            return;
    //--------------end of  verification
var start = new Date();        // starts chrono
countName = textcount.text;    // start of the counter to number the name of the file to save
    //-------------disctribution of the object on the sheet
    for (var i=0,howmuch = 0,len1=listEx.length;i<len1;i++)
        for (var j =0; j<listqte[i];j++)
                if (howmuch==0)
                        if ((listqte[i]-j)/limite>=2) //activate "xtimes" if quantity is twice or more bigger than "limit"
                                xtimes = parseInt ((listqte[i]-j)/limite);
                                j += limite*(xtimes-1);
                myfile = new File(folder2+'/'+listEx[i]);
                var  thisPlacedItem = doc.placedItems.add();
                thisPlacedItem.file = myfile;
                // rotate if necessary
                if (couchangl !=0) thisPlacedItem.rotate(couchangl);
                howmuch ++;
                if (howmuch == limite)
                        place();
                        sauve();
                        doc.pageItems.removeAll();
                        howmuch = 0;
                        xtimes = 0;
place();
sauve();
redraw();
alert("time spent : "+((new Date() - start)/1000)+" secondes");

Hello,
The Windows Desktop Perfmon and Diagnostic tools forum is to discuss performance monitor (perfmon), resource monitor (resmon), and task manager, focusing on HOW-TO, Errors/Problems, and usage scenarios.
As the question is off topic here, I am moving it to the
Where is the Forum... forum.
Karl
When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer.
My Blog: Unlock PowerShell
My Book:
Windows PowerShell 2.0 Bible
My E-mail: -join ('6F6C646B61726C406F75746C6F6F6B2E636F6D'-split'(?<=\G.{2})'|%{if($_){[char][int]"0x$_"}})

Similar Messages

  • MapBuilder Error:Can not find a GeoRaster object with specified rdt and rid

    Hello,
    I can't GeoRaster data in the preview of the MapBuilder and MapViewer. The GeoRasterViewer shows the Raster images without problems.
    MapBuilders error message:
    19.11.2008 13:07:11 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    SCHWERWIEGEND: GeoRaster load Exception:
    oracle.spatial.georaster.GeoRasterException: Can not find a GeoRaster object with specified rdt and rid.
         at oracle.spatial.georaster.JGeoRaster.validateConn(JGeoRaster.java:608)
         at oracle.sdovis.theme.GeoRasterThemeProducer$JGeoRasterGTP.<init>(GeoRasterThemeProducer.java:2037)
         at oracle.sdovis.theme.GeoRasterThemeProducer.prepareData(GeoRasterThemeProducer.java:694)
         at oracle.sdovis.GeoRasterTheme.prepareData(GeoRasterTheme.java:95)
         at oracle.sdovis.LoadThemeData.run(LoadThemeData.java:75)
    19.11.2008 13:07:11 oracle.sdovis.LoadThemeData run
    SCHWERWIEGEND: Exception fetching data for theme RAS_DGK.
    Message:GeoRaster load Exception: Can not find a GeoRaster object with specified rdt and rid.
    Description:
         at oracle.sdovis.theme.GeoRasterThemeProducer.prepareData(GeoRasterThemeProducer.java:1109)
         at oracle.sdovis.GeoRasterTheme.prepareData(GeoRasterTheme.java:95)
         at oracle.sdovis.LoadThemeData.run(LoadThemeData.java:75)
    19.11.2008 13:07:11 oracle.sdovis.MapMaker buildDataMBR
    WARNUNG: null MBR resulted from buildDataMBR.
    The errror message of MapViewer is nearly the same with some more informations about the spatial query and the coordintes of the query window. If I run that spatial query in the sqldeveloper it returns a result!
    I did following stebs:
    - saved a tiff-Image in a GeoRaster table with pyramid an tiled images.
    - checked the sdo_geom_metadata --> they are correct
    - checked the sdo_georaster object for the rdt table name and rasterid --> they are correct
    - checked the rdt table --> objects with that rid are saved
    - checked the mdsys.sdo_geor_sysdata table --> entry is correct
    - validate the geraster with the sdo_geor.validategeoraster function --> object is valid
    - updated the spatial extend of the image and try again the preview functio--> the same error
    The databse server is a virtual Linux server with Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bit.
    The web server is a Window 2003 R2 Server with a weblogic server and mapviewer patch 5 (Ver1033p5_B081010).
    For a test I did the same (the same table script, the same raster data, the same import method) on a developer pc (WinXP Pro SP2) with Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 (32bit) the same mapbuilder version but with the MapViewer QuickStartKid and it works fine!!!
    Has anyone an idea?
    Greeting,
    Cord
    Edited by: Corti on Nov 19, 2008 2:14 PM

    Hi Joao,
    Thanks so far.
    I'm previewing a GeoRaster theme. I created it with the MapBuilder GeoRaster wizard. The theme difinition is (out of the export file):
    RAS_DGK|
    null|
    RAS_DGK|
    GEORASTER|
    <?xml version="1.0" standalone="yes"?>
    <styling_rules theme_type="georaster">
    </styling_rules>|
    (GeoRaster table name is "RAS_DGK", theme name is also "RAS_DGK")
    I get following log information:
    preview without a coordinate or scale:
    MapBuilder Error (as pop up): MAPVIEWER 01005: no spatial data to render
    log file:
    20.11.2008 10:17:27 oracle.sdovis.LoadThemeData run
    FEINER: LoadThemeData running thread: Thread-43
    20.11.2008 10:17:27 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: Original query window: -Infinity,-Infinity,NaN,NaN
    20.11.2008 10:17:27 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: [Query] select grt.GEORASTER, grt.GEORASTER.metadata.getClobVal() from RAS_DGK grt
    20.11.2008 10:17:27 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: Fetch size: 100
    20.11.2008 10:17:27 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    SCHWERWIEGEND: GeoRaster load Exception:
    oracle.spatial.georaster.GeoRasterException: Can not find a GeoRaster object with specified rdt and rid.
         at oracle.spatial.georaster.JGeoRaster.validateConn(JGeoRaster.java:608)
         at oracle.sdovis.theme.GeoRasterThemeProducer$JGeoRasterGTP.<init>(GeoRasterThemeProducer.java:2037)
         at oracle.sdovis.theme.GeoRasterThemeProducer.prepareData(GeoRasterThemeProducer.java:694)
         at oracle.sdovis.GeoRasterTheme.prepareData(GeoRasterTheme.java:95)
         at oracle.sdovis.LoadThemeData.run(LoadThemeData.java:75)
    20.11.2008 10:17:27 oracle.sdovis.LoadThemeData run
    SCHWERWIEGEND: Exception fetching data for theme RAS_DGK.
    Message:GeoRaster load Exception: Can not find a GeoRaster object with specified rdt and rid.
    Description:
         at oracle.sdovis.theme.GeoRasterThemeProducer.prepareData(GeoRasterThemeProducer.java:1109)
         at oracle.sdovis.GeoRasterTheme.prepareData(GeoRasterTheme.java:95)
         at oracle.sdovis.LoadThemeData.run(LoadThemeData.java:75)
    20.11.2008 10:17:27 oracle.sdovis.MapMaker buildDataMBR
    WARNUNG: null MBR resulted from buildDataMBR.
    preview with a center coordinate of the image and a scale:
    20.11.2008 10:18:43 oracle.sdovis.SRS getOptimalQueryWindow
    AM FEINSTEN: *** isGeodetic=false, unit=METER
    20.11.2008 10:18:43 oracle.sdovis.LoadThemeData run
    FEINER: LoadThemeData running thread: Thread-45
    20.11.2008 10:18:43 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: Original query window: 2550045.7746478873,5608500.0,2551954.2253521127,5609500.0
    20.11.2008 10:18:43 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: [Query] select grt.GEORASTER, grt.GEORASTER.metadata.getClobVal() from RAS_DGK grt WHERE MDSYS.SDO_FILTER(grt.GEORASTER.spatialextent, MDSYS.SDO_GEOMETRY(2003, 31466, NULL, MDSYS.SDO_ELEM_INFO_ARRAY(1, 1003, 3), MDSYS.SDO_ORDINATE_ARRAY(?,?,?,?)), 'querytype=WINDOW') = 'TRUE'
    20.11.2008 10:18:43 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: Fetch size: 100
    20.11.2008 10:18:43 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    SCHWERWIEGEND: GeoRaster load Exception:
    oracle.spatial.georaster.GeoRasterException: Can not find a GeoRaster object with specified rdt and rid.
         at oracle.spatial.georaster.JGeoRaster.validateConn(JGeoRaster.java:608)
         at oracle.sdovis.theme.GeoRasterThemeProducer$JGeoRasterGTP.<init>(GeoRasterThemeProducer.java:2037)
         at oracle.sdovis.theme.GeoRasterThemeProducer.prepareData(GeoRasterThemeProducer.java:694)
         at oracle.sdovis.GeoRasterTheme.prepareData(GeoRasterTheme.java:95)
         at oracle.sdovis.LoadThemeData.run(LoadThemeData.java:75)
    20.11.2008 10:18:43 oracle.sdovis.LoadThemeData run
    SCHWERWIEGEND: Exception fetching data for theme RAS_DGK.
    Message:GeoRaster load Exception: Can not find a GeoRaster object with specified rdt and rid.
    Description:
         at oracle.sdovis.theme.GeoRasterThemeProducer.prepareData(GeoRasterThemeProducer.java:1109)
         at oracle.sdovis.GeoRasterTheme.prepareData(GeoRasterTheme.java:95)
         at oracle.sdovis.LoadThemeData.run(LoadThemeData.java:75)
    20.11.2008 10:18:43 oracle.sdovis.DBMapMaker renderEm
    INFO: **** time spent on loading features: 234ms.
    20.11.2008 10:18:43 oracle.sdovis.RenderingEngine prepareForRendering
    AM FEINSTEN: xfm: 0.284 0.0 0.0 -0.284 -724212.9999999999 1593097.9999999998
    20.11.2008 10:18:43 oracle.sdovis.ImageRenderer renderGeoRasterTheme
    WARNUNG: GeoRaster theme RAS_DGK has no rendered images.
    20.11.2008 10:18:43 oracle.sdovis.VectorRenderer render
    FEINER: time to render theme RAS_DGK with 0 styled features: 0ms
    20.11.2008 10:18:43 oracle.sdovis.DBMapMaker renderEm
    INFO: **** time spent on rendering: 16ms
    If I run the sql statement in the log file, it returns a result.
    select grt.georid, grt.GEORASTER, grt.GEORASTER.metadata.getClobVal()
    from ras_dgk grt
    WHERE MDSYS.SDO_FILTER(grt.GEORASTER.spatialextent,
    MDSYS.SDO_GEOMETRY(2003, 31466, NULL,
    MDSYS.SDO_ELEM_INFO_ARRAY(1, 1003, 3),
    MDSYS.SDO_ORDINATE_ARRAY(2550045.7746478873,5608500.0,2551954.2253521127,5609500.0)), 'querytype=WINDOW') = 'TRUE';
    GEORID
    2
    GEORASTER
    MDSYS.SDO_GEORASTER(20001,MDSYS.SDO_GEOMETRY(2003,31466,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,3),MDSYS.SDO_ORDINATE_ARRAY(2550000,5608000,2552000,5610000)),RDT_RAS_DGK,522,oracle.xdb.XMLType@194a7ec)
    GEORASTER.metadata.getClobVal()
    <georasterMetadata xmlns="http://xmlns.oracle.com/spatial/georaster">
    <objectInfo>
    <rasterType>20001</rasterType>
    <isBlank>false</isBlank>
    <defaultRed>1</defaultRed>
    <defaultGreen>1</defaultGreen>
    <defaultBlue>1</defaultBlue>
    </objectInfo>
    <rasterInfo>
    <cellRepresentation>UNDEFINED</cellRepresentation>
    <cellDepth>8BIT_U</cellDepth>
    <totalDimensions>2</totalDimensions>
    <dimensionSize type="ROW">
    <size>6299</size>
    </dimensionSize>
    <dimensionSize type="COLUMN">
    <size>6299</size>
    </dimensionSize>
    <ULTCoordinate>
    <row>0</row>
    <column>0</column>
    </ULTCoordinate>
    <blocking>
    <type>REGULAR</type>
    <totalRowBlocks>4</totalRowBlocks>
    <totalColumnBlocks>4</totalColumnBlocks>
    <rowBlockSize>2048</rowBlockSize>
    <columnBlockSize>2048</columnBlockSize>
    </blocking>
    <interleaving>BSQ</interleaving>
    <pyramid>
    <type>DECREASE</type>
    <resampling>NN</resampling>
    <maxLevel>6</maxLevel>
    </pyramid>
    <compression>
    <type>NONE</type>
    </compression>
    </rasterInfo>
    <spatialReferenceInfo>
    <isReferenced>true</isReferenced>
    <SRID>31466</SRID>
    <modelCoordinateLocation>UPPERLEFT</modelCoordinateLocation>
    <modelType>FunctionalFitting</modelType>
    <polynomialModel rowOff="0" columnOff="0" xOff="0" yOff="0" zOff="0" rowScale="1" columnScale="1" xScale="1" yScale="1" zScale="1">
    <pPolynomial pType="1" nVars="2" order="1" nCoefficients="3">
    <polynomialCoefficients>17668678.695368 0 -3.14949718277477</polynomialCoefficients>
    </pPolynomial>
    <qPolynomial pType="1" nVars="0" order="0" nCoefficients="1">
    <polynomialCoefficients>1</polynomialCoefficients>
    </qPolynomial>
    <rPolynomial pType="1" nVars="2" order="1" nCoefficients="3">
    <polynomialCoefficients>-8031218.31607409 3.14949718277477 0</polynomialCoefficients>
    </rPolynomial>
    <sPolynomial pType="1" nVars="0" order="0" nCoefficients="1">
    <polynomialCoefficients>1</polynomialCoefficients>
    </sPolynomial>
    </polynomialModel>
    </spatialReferenceInfo>
    <layerInfo>
    <layerDimension>BAND</layerDimension>
    <subLayer>
    <layerNumber>1</layerNumber>
    <layerDimensionOrdinate>0</layerDimensionOrdinate>
    <layerID>1</layerID>
    <colorMap>
    <colors>
    <cell value="0" blue="255" red="255" green="255" alpha="255"/>
    <cell value="1" blue="0" red="0" green="0" alpha="255"/>
    </colors>
    </colorMap>
    </subLayer>
    </layerInfo>
    </georasterMetadata>
    I checked also the content of rdt table and it contains entries with that raster id (= 522).
    Finally the log file when I use the preview directly on the GeoRaster table without a theme:
    20.11.2008 10:23:46 oracle.sdovis.LoadThemeData run
    FEINER: LoadThemeData running thread: Thread-55
    20.11.2008 10:23:46 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: Original query window: -Infinity,-Infinity,NaN,NaN
    20.11.2008 10:23:46 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: [Query] select grt.GEORASTER from RAS_DGK grt where grt.GEORASTER.rasterid = ? and grt.GEORASTER.rasterdatatable = ?
    20.11.2008 10:23:46 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    FEINER: Fetch size: 100
    20.11.2008 10:23:46 oracle.sdovis.theme.GeoRasterThemeProducer prepareData
    SCHWERWIEGEND: GeoRaster load Exception:
    oracle.spatial.georaster.GeoRasterException: Can not find a GeoRaster object with specified rdt and rid.
         at oracle.spatial.georaster.JGeoRaster.validateConn(JGeoRaster.java:608)
         at oracle.sdovis.theme.GeoRasterThemeProducer$JGeoRasterGTP.<init>(GeoRasterThemeProducer.java:2037)
         at oracle.sdovis.theme.GeoRasterThemeProducer.prepareData(GeoRasterThemeProducer.java:694)
         at oracle.sdovis.GeoRasterTheme.prepareData(GeoRasterTheme.java:95)
         at oracle.sdovis.LoadThemeData.run(LoadThemeData.java:75)
    20.11.2008 10:23:46 oracle.sdovis.LoadThemeData run
    SCHWERWIEGEND: Exception fetching data for theme RAS_DGK.
    Message:GeoRaster load Exception: Can not find a GeoRaster object with specified rdt and rid.
    Description:
         at oracle.sdovis.theme.GeoRasterThemeProducer.prepareData(GeoRasterThemeProducer.java:1109)
         at oracle.sdovis.GeoRasterTheme.prepareData(GeoRasterTheme.java:95)
         at oracle.sdovis.LoadThemeData.run(LoadThemeData.java:75)
    20.11.2008 10:23:46 oracle.sdovis.MapMaker buildDataMBR
    WARNUNG: null MBR resulted from buildDataMBR.
    If you need more information - please ask for it.
    Cord

  • Hello. I need to define a mesure in a picture: I took a picture of an object with a ruler and I want to signify to photoshop "this segment = 1 cm". How to do? Thank you!

    Hello. I need to define a mesure in a picture: I took a picture of an object with a ruler and I want to signify to photoshop "this segment = 1 cm". How to do? Thank you!

    That's a good precaution, norm.  It should be no problem is you have an object on a flat surface next to a ruler. It gets trickier in security camera frames.
    Anyway that is one example. Anne can look further into the measuring tools of  Photoshop Extended to see if it helps.
    A note on the screen resolution thing. When I calculate the screen resolution, I go into Photoshop > Preferences > Units and Rulers
    and enter it here in place of the default 72 ppi.  Then when I use View > Print Size, the on-screen rulers will match a physical ruler.
    That's if you wanted to look at the actual printed document size onscreen.
    Gene

  • How to spin an object with both x and z-rotation in M3G?

    I want to spin an object with both x and z-rotation in M3G. I get a good result when I implement this in OpenGL, but the combined rotation doesn't get right when I try to do this in M3G. The x rotation and the z rotation looks like they should when I only use one of them. This is achieved by adding only spinAnimationTrack or rotationAnimationTrack. The problem is that the rotation gets messed up when I add both spinAnimationTrack and rotationAnimationTrack. What am I doing wrong? This is my code:
    KeyframeSequence spinKeyframes =
    new KeyframeSequence(3, 4, KeyframeSequence.SLERP);
    spinKeyframes.setRepeatMode(KeyframeSequence.LOOP);
    spinKeyframes.setDuration(4000);
    spinKeyframes.setKeyframe(0, 0,
    getRotationQuaternion(-50.0f, new float[]{1.0f, 0.0f, 0.0f}));
    spinKeyframes.setKeyframe(1, 2000,
    getRotationQuaternion(50.0f, new float[]{1.0f, 0.0f, 0.0f}));
    spinKeyframes.setKeyframe(2, 4000,
    getRotationQuaternion(-50.0f, new float[]{1.0f, 0.0f, 0.0f}));
    AnimationTrack spinAnimationTrack =
    new AnimationTrack(spinKeyframes,
    AnimationTrack.ORIENTATION);
    AnimationController animatorS = new AnimationController();
    spinAnimationTrack.setController(animatorS);
    animatorS.setSpeed(0.4f * speed, 0);
    KeyframeSequence rotationKeyframes =
    new KeyframeSequence(2, 4, KeyframeSequence.SLERP);
    rotationKeyframes.setRepeatMode(KeyframeSequence.LOOP);
    rotationKeyframes.setDuration(4000);
    rotationKeyframes.setKeyframe(0, 0,
    getRotationQuaternion(359.0f, new float[]{0.0f, 0.0f, 1.0f}));
    rotationKeyframes.setKeyframe(1, 4000,
    getRotationQuaternion(0.0f, new float[]{0.0f, 0.0f, 1.0f}));
    AnimationTrack rotationAnimationTrack1 =
    new AnimationTrack(rotationKeyframes,
    AnimationTrack.ORIENTATION);
    rotationAnimationTrack1.setController(animatorR1);
    animatorR1.setSpeed(0.4f * speed, 0);
    mesh1.addAnimationTrack(spinAnimationTrack);
    mesh1.addAnimationTrack(rotationAnimationTrack1);

    People often make this harder than it is. It's usually not necessary to using clipping paths or to make cuts confined to the areas of overlap to make objects appear to intertwine. Usually, you can simply cut where objects do not overlap. There are no masks, clipping paths, pathfinders, etc., involved in this knot:
    Your specific situation may be somewhat complicated by the use of drop shadows, depending on the specific parameters.
    JET

  • Tag files, Lists, and object typing

    I'm passing a list of objects to a custom tag, created via a tag file.
    I can access object properties in the jsp page like this -
    <c:out value="${listOfItems[0].property}" />
    but inside the tag it doesn't work. It understands that its being passed a list and the number of items in the list but not the type of objects in the list. I think I need to declare the type of object that the list is returning but I'm unsure of th jstl way of doing this.
    advice?
    thanks

    JSTL uses introspection/reflection to call methods/access properties.
    It doesn't have to know the type of object in the list.
    How are you accessing this object in your tag file? Using EL again? That should work fine. If you use java/scriptlet code then you will need to cast the object.
    Have you declared the attribute that is being passed in? What type are you expecting? Default is String unless you specify otherwise.

  • Report with select list and link to call another report

    Hi,
    I am trying to do 2 reports (REPORT1 and REPORT2).
    The first is a summary report (REPORT1).
    This report will display sales figures for the year. Now, I need to have a select list in the result set that will have 2 options, depending on which option is chosen, I want to call REPORT2 with the select list as a parameter. How can I do this ?
    Let me try to explain what I did.
    I created REPORT1 on Page 100
    SELECT YEAR, sum(YTD_SALES), APEX_ITEM.SELECT_LIST(1,'DEPARTMENT','Department;DEPARTMENT,Division;DIVISION') Drilldown FROM SALES_ANALYSIS WHERE YEAR > 2000
    GROUP BY YEAR ORDER BY YEAR
    I created 2 hidden items namely P100_YEAR and P100_DRILLDOWN
    I also made the column YEAR as a link and specified both P100_YEAR and P100_DRILLDOWN as parameters to be passed.
    Next, I created REPORT2
    SELECT YEAR, DECODE(:P100_DRILLDOWN, 'Department', department, 'Division', Division) dept_div, sum(YTD_SALES) ytd_sales
    FROM SALES_ANALYSIS
    WHERE YEAR = :P100_YEAR
    When I run Report 1, it's fine, when I choose either Department or Division from the Select List and click on the link to call Report 2, report 2 is displayed, but the value being passed for P100_DRILLDOWN is not correct and as a result, I am unable to get correct results for Report 2
    Am I missing something ? Are there any alternate ways to do what I'm doing ?
    Thanks,
    Ashok

    Hi Ashok,
    The link definition will not know the value selected in the list as it is constructed only when the page is being rendered. You would need to create some javascript to handle this. I've done that here: [http://apex.oracle.com/pls/otn/f?p=267:182]
    The link on the EMPNO column has been defined in the HTML Expression setting for the column instead of the Link section. The HTML Expression that I have used is:
    &lt;a href="#" onclick="javascript:doDrilldown('#EMPNO#',this);"&gt;#EMPNO#&lt;/a&gt;And, in the page's HTML Header setting, I have added in:
    &lt;script type="text/javascript"&gt;
    function doDrilldown(empno,group)
    var g;
    var p = group.parentNode;
    while (p.tagName != "TR")
      p = p.parentNode;
    var x = p.getElementsByTagName("SELECT");
    if (x.length &gt; 0)
      g = x[0].value;
    var url = "f?p=&APP_ID.:183:&SESSION.::::P183_EMPNO,P183_GROUP:" + empno + "," + g;
    document.location.href = url;
    &lt;/script&gt;When a link is clicked, the doDrilldown function is called passing in the EMPNO value and the "this" object (which identifies the object triggering the call). The function starts from that object and goes up in the HTML tag tree to the nearest TR tag (the row tag that the link is on) and then finds the first SELECT list item on the row and gets its value. It then constructs a URL using this and the EMPNO value and performs a redirect to the second page (page 183 in this example).
    Andy

  • Help with linked lists and searching

    Hi guys I'm very new to java. I'm having a problem with linked lists. the program's driver needs to create game objects, store them, be able to search the linked list etc. etc. I've read the API but I am really having trouble understanding it.
    First problem is that when I make a new game object through the menu when running the program, and then print the entire schedule all the objects print out the same as the latest game object created
    Second problem is searching it. I just really have no idea.
    Here is the driver:
    import java.util.*;
    public class teamSchedule
         public static void main (String[]args)
              //variables
              boolean start;
              game game1;
              int selector;
              Scanner scanner1;
              String date = new String();
              String venue = new String();
              String time = new String();
              String dateSearch = new String();
              double price;
              String opponent = new String();
              int addindex;
              List teamSchedLL = new LinkedList();
              String dateIndex = new String();
              String removeYN = new String();
              String venueIndex = new String();
              String opponentIndex = new String();
              start = true; //start makes the menu run in a while loop.
              while (start == true)
                   System.out.println("Welcome to the Team Scheduling Program.");
                   System.out.println("To add a game to the schedule enter 1");
                   System.out.println("To search for a game by date enter 2");
                   System.out.println("To search for a game by venue enter 3");
                   System.out.println("To search for a game by opponent enter 4");
                   System.out.println("To display all tour information enter 5");
                   System.out.println("");
                   System.out.println("To remove a game from the schedule enter search for the game, then"
                                            + " remove it.");
                   System.out.println("");
                   System.out.println("Enter choice now:");
                   scanner1 = new Scanner (System.in);
                   selector = scanner1.nextInt();
                   System.out.println("");
                   if (selector == 1)
                        //add a game
                        scanner1.nextLine();
                        System.out.println("Adding a game...");
                        System.out.println("Enter game date:");
                        date = scanner1.nextLine();
                        System.out.println("Enter game venue:");
                        venue = scanner1.nextLine();
                        System.out.println("Enter game time:");
                        time = scanner1.nextLine();
                        System.out.println("Enter ticket price:");
                        price = scanner1.nextDouble();
                        scanner1.nextLine();
                        System.out.println("Enter opponent:");
                        opponent = scanner1.nextLine();
                        game1 = new game(date, venue, time, price, opponent);
                        teamSchedLL.add(game1);
                        System.out.println(teamSchedLL);
                        System.out.println("Game created, returning to main menu. \n");
                        start = true;
                   else if (selector == 2)
                        //search using date
                        scanner1.nextLine();
                        System.out.println("Enter the date to search for in the format that it was entered:");
                        dateIndex = scanner1.nextLine();
                        if (teamSchedLL.indexOf(dateIndex) == -1)
                             System.out.println("No matching date found.  Returning to main menu.");
                             start = true;
                        else
                             //give user option to remove game if they wish.
                             System.out.println(teamSchedLL.get(teamSchedLL.indexOf(dateIndex)));
                             System.out.println("Would you like to remove this game? Y/N");
                             removeYN = scanner1.nextLine();
                             if (removeYN == "Y" || removeYN == "y")
                                  teamSchedLL.remove(teamSchedLL.indexOf(dateIndex));
                                  System.out.println("Scheduled game removed.");
                        System.out.println("\n Returning to main menu. \n");
                        start = true;
                   else if (selector == 3)
                        //search using venue name
                        scanner1.nextLine();
                        System.out.println("Enter the venue to search for in the format that it was entered:");
                        venueIndex = scanner1.nextLine();
                        if (teamSchedLL.indexOf(venueIndex) == -1)
                             System.out.println("No matching venue found.  Returning to main menu.");
                             start = true;
                        else
                             //give user option to remove game
                             System.out.println(teamSchedLL.get(teamSchedLL.indexOf(venueIndex)));
                             System.out.println("Would you like to remove this game? Y/N");
                             removeYN = scanner1.nextLine();
                             if (removeYN == "Y" || removeYN == "y")
                                  teamSchedLL.remove(teamSchedLL.indexOf(venueIndex));
                                  System.out.println("Scheduled game removed.");
                        System.out.println("\n Returning to main menu. \n");
                        start = true;
                   else if (selector == 4)
                        //search using opponent name
                        scanner1.nextLine();
                        System.out.println("Enter the opponent to search for in the format that it was entered:");
                        opponentIndex = scanner1.nextLine();
                        if (teamSchedLL.indexOf(opponentIndex) == -1)
                             System.out.println("No matching opponent found.  Returning to main menu.");
                             start = true;
                        else
                             //give user option to remove game
                             System.out.println(teamSchedLL.get(teamSchedLL.indexOf(opponentIndex)));
                             System.out.println("Would you like to remove this game? Y/N");
                             removeYN = scanner1.nextLine();
                             if (removeYN == "Y" || removeYN == "y")
                                  teamSchedLL.remove(teamSchedLL.indexOf(opponentIndex));
                                  System.out.println("Scheduled game removed.");
                        System.out.println("\n Returning to main menu. \n");
                        start = true;
                   else if (selector == 5)
                        //display tour info
                        System.out.println("Tour Schedule:");
                        System.out.println(teamSchedLL + "\n");
                   else
                        System.out.println("Incorrect choice entered. Returning to menu");
                        System.out.println("");
                        System.out.println("");
                        System.out.println("");
    and here is the game class:
    public class game
         private static String gameDate;
         private static String gameVenue;
         private static String gameTime;
         private static double gamePrice;
         private static String gameOpponent;
         public static String gameString;
         //set local variables equal to parameters
         public game(String date, String venue, String time, double price, String opponent)
              gameDate = date;
              gameVenue = venue;
              gameTime = time;
              gamePrice = price;
              gameOpponent = opponent;
         //prints out info about the particular game
         public String toString()
              gameString = "\n --------------------------------------------------------";
              gameString += "\n Date: " + gameDate + " | ";
              gameString += "Venue: " + gameVenue + " | ";
              gameString += "Time: " + gameTime + " | ";
              gameString += "Price: " + gamePrice + " | ";
              gameString += "Opponent: " + gameOpponent + "\n";
              gameString += " --------------------------------------------------------";
              return gameString;
    }I'm sure the formatting/style and stuff is horrible but if I could just get it to work that would be amazing. Thanks in advance.
    Message was edited by:
    wdewind

    I don't understand your first problem.
    Your second problem:
    for (Iterator it=teamSchedLL.iterator(); it.hasNext(); ) {
    game game = (game)it.next();
    // do the comparation here, if this is the game want to be searched, then break;
    }

  • Object with multiple states and slider in folio are rasterized, settings seem correct.

    I am having trouble keeping An object with multiple text states from being rasterized, as well as a slider that is also rastering.
    I have read that you are supposed to set the folio and article up to be .pdf and that the slider should have the vector option chosen.
    I haven't found anything for the multi state object to for these settings.
    What happens is when I output the folio to Adobe Content Viewer, only the text in those items is rasterized. All other text is crisp. Tested on both iPad Mini and iPad Retina and the both are blurry.
    Is there a way to force the vector option? It seems even with the correct options selected it is still rastering the test in interactive elements.
    Thanks!

    Here is the MSO with the folio.
    Here is the Slider with folio overlays panel.

  • Unable to download from AppStore, updates,etc.Messages 'the installer is damaged' to 'there might be a problem with file ownership and permissions.' I am the owner and only user of a new MBP. What could be going on?

    Is anyone having the same type of problems I'm having with Lion. I have a new MacBook Pro, received 7 weeks ago, preinstalled with Leopard 10.6.7. I didn't migrate anything from my old iMac, wanted a clean install from the Apple Store. While there, I asked for the upgrade to Lion 10.7, however their system was down.
    I  installed it myself, wirelessly about a week later, and Apple emailed me a receipt. Now, I've had to call support directly last week when I lost Mail, Address Book, was unable to open Preview or iTunes, among other problems. Seemed fixed after a session that baffled even the store tech.  Now I am unable to download or install the recent Mac updates for Lion, from the App Store, could not install Adobe Reader, etc. Messages range from 'A network error has occured - Check your Internet connection and try again' to 'The Installer is damaged and cannot open the package. There may be a problem with file ownership or permissions.'  All fail and I'll probably have to call Apple again. I am frustrated beyond words.  Logs 'Install's runner tool is not properly configured as a setuid tool', domain errors, 'attempt to write a readonly database, and on and on. I have barely done a thing on this computer except search online for help with these problems. Safari gives me a 'You are not connected to the internet' too often. Diagnostics disagrees. I do see wi-fi problems in the forum. Disk and permissions were fine at the beginning of the earlier problems, checked first by support tech. I'm not sure if support tech even knew. I was just happy they were fixed. Anyone have these download and/or install problems after a 'clean bill of health' so to speak, only a week ago?

    Let's try the following user tip with that one:
    "There is a problem with this Windows Installer package ..." error messages when installing iTunes for Windows

  • 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.

  • Inspection lot not updated with Task list and sample

    Hi,
    I have created a quality plant and assigned the MICs. When I am trying to Process the quality lot which is created automatically through QA32, I got an error, ,No inspection plan could be found'
    When i create an inspection lot system is picking up the Task list and picking up the Sample size.
    Please provide some light on this.

    Hello Kumar,
    Check each and every point given in below document and come up with your observations.
    I presume Inspection lot status consists CRTD.
    Inspection lots with CRTD status- Causes and Remedies - Product Lifecycle Management - SCN Wiki
    Amol.

  • White screen with file icon and Question mark after a kernel panic???

    I'm using my girlfriends 20" iMac and her computer keeps having kernel panics. And then at times when we restart the computer, we get a white screen with a file icon and a question mark inside. Any ideas on what to do???? Her graduation project is on that computer and she is stressed like you wouldn't believe. Safe to say, I'm taking the brunt of it. Please help!!!

    It sounds like you might be having a hard drive problem. The folder icon with question mark means the computer can't find a startup drive/system folder. I suggest that you back up all important data, especially her project. Before bringing it in for service, run the Apple Hardware Test - put in your original system restore DVD and restart the computer, holdng down the "D" key. Run the extended diagnositics (it will take over an hour (depending on how much RAM you have) and will tell you if there is anything wrong with your hardware. If it dinds a problem then you can take it to the nearest Apple authorized service provider to check it out.

  • Performance problems with File Adapter and XI freeze

    Hi NetWeaver XI geeks,
    We are deploying a XI based product and encounter some huge performance problems. Here after the scenario and the issues:
    - NetWeaver XI 2004
    - SAP 4.6c
    - Outbound Channel
    - No mapping used and only the iDocs Adapter is involved in the pipeline processing
    - File Adapter
    - message file size < 2Ko
    We have zeroed down the problem to Idoc adapter’s performance.
    We are using a file channel and  every 15 seconds a file in a valid Idoc format is placed in a folder, Idoc adapter picks up the file from this folder and sends it  to the SAP R/3 instance.
    For few minutes (approx 5 mins) it works (the CPU usage is less then 20% even if processing time seems huge : <b>5sec/msg</b>) but after this time the application gets blocked and the CPU gets overloaded at 100% (2 processes disp_worker.exe at 50% each).
    If we inject several files in the source folder at the same time or if we decrease the time gap (from 15 seconds to 10 seconds) between creation of 2 Idoc files , the process blocks after posting  2-3 docs to SAP R/3.
    Could you point us some reasons that could provoke that behavior?
    Basically looking for some help in improving performance of the Idoc adapter.
    Thanks in advance for your help and regards,
    Adalbert

    Hi Bhavesh,
    Thanks for your suggestions. We will test...
    We wonder if the hardware is not the problem of this extremely poor performance.
    Our XI server is:
    •     Windows 2003 Server
    •     Processors: 2x3GHZ
    •     RAM: 4GB (the memory do not soak)
    The messages are well formed iDocs = single line INVOICES.
    Some posts are talking 2000 messages processed in some seconds... whereas we got 5 sec per message.
    Tnanks for your help.
    Adalbert

  • How to make a original frame same with Comment List and Attachment?

    How can I make original frame looking like Comment List?
    I'm using Windows XP and Adobe Acrobat 9 Pro and Acrobat 9 SDK.
    I want to make a new plug-in that use a new frame.
    The new frame is looking like Comment List and Attachment.
    I want to show my original list and input form to the frame.
    It is close to Comment List frame, but I want to show original list.
    Additionally, I want to add new button upper of Comments Button on Navigation Button Panel.
    Can I have any help?

    There is no support in the SDK for adding your own panels.
    There is no support for modifying the existing panels.

  • Problem with File Input and Output

    I'm using a class named Output which takes 2 arrays as input and is simply supposed to output them to a file named myfile.txt. However, every time I call it it catches an exception and just prints out Error Writing to File. Here is the source:
    import java.io.*;
    public class Output
         public Output(int[][] orig, int[][] orig2)
              int[][] first = orig;
              int[][] second = orig2;
              try
                   FileOutputStream out = new FileOutputStream("myfile.txt");
                   PrintStream p = new PrintStream( out );
                   p.print("{");
                   for(int i = 0; i < 50; i++)
                        for(int j = 0; j < 30; j++)
                             p.print(" " + first[i][j]);
                   p.print("}");
                   p.println("\n\n\n");
                   p.print("{");
                   for(int i = 0; i < 50; i++)
                        for(int j = 0; j < 30; j++)
                             p.print(" " + second[i][j]);
                   p.print("}");
                   p.close();
              catch (Exception e)
                   System.err.println ("Error writing to file");
    }

    Equis.Scry wrote:
    So basically is my computer not letting this APPLET create a txt file? For security reasons, applets by default cannot access the local file system (on the client) and cannot open any network connections except back to the server that served them up. You can sign your applet, and set up permissions in the JRE that your browser runs to allow the signed applet to do things that applets normally can't. However, before starting down that path, I suggest you examine whether your applet really needs to access the local file system, and if it does, if it should really be an applet, or would be more appropriate as an application.

Maybe you are looking for

  • Aperture Red Eye Adjustments do not show up in preview

    I generally use the zoom viewer to make my red eye adjustments; however, when I'm done adjusting and I zoom out, the viewer doesn't reflect the red-eye adjustments. Sometimes the adjustment on one eye will look correct but the other eye is still part

  • How can I view the number of messages in each folder

    I have just installed TB 24.4.0 on a new Windows 8 desktop. On my older Windows 7 desktop also running TB 24.4.0, the folder pane is configured to display the number of messages and space usage of each folder. Both machines are set to the same "class

  • MS Assess and Netbeans issue

    I am trying to create a app that will use a database I created with MS Access. My problem is when i do to create the database. I have the DSN set up for the database. When I go to create a connection i get this error: Unable to obtain schema. There i

  • HiRes photos

    I have created photo pages using the conventional iPhoto / iWeb functionality. But my photos only load in low / med resolution when accessing the site. Can I provide an option for HiRes - large size - access to the photos?

  • IPod Touch 2G Update?

    Hi, will the ipod touch 2g's ever have home screen wallpaper and multitasking? And if not, why???????????? I really want to know please!!! Thanks, Calpol55