Is this possible? Using Illustrator Script to duplicate EPS file 35 times & changing C,M,Y,K value?
Hi everyone,
I need HELP I have a bunch of vector clip arts, which are Black (C,M,Y,K100). I need it in 35 different colors Saved as Illustrator 8 EPS and I also need those file in 72 DPI PNG Transparent files.
Thanks for any help.
Akkudo.
Good evening,
0) In your templates give a specific namme to each path or groups or items via the layers window.
The objective is to use a script like these two:
Set myLayerCercle = my_Laieur_elements.GroupItems("Laplupart").PathItems("LaplupartCercle")
myAiApp.Redraw
myLayerCercle.FillColor.Spot.Color.Cyan = 0
myLayerCercle.FillColor.Spot.Color.Magenta = 100
myLayerCercle.FillColor.Spot.Color.Yellow = 80
myLayerCercle.FillColor.Spot.Color.Black = 0
myAiApp.Redraw
or
textRef.Paragraphs.Add ("myNewText")
textRef.Paragraphs(1).ParagraphAttributes.Justification = aiRight
textRef.Paragraphs(1).CharacterAttributes.Size = 12
textRef.Paragraphs(1).CharacterAttributes.HorizontalScale = 10
textRef.TextRange.CharacterAttributes.BaselineShift = fontBaseLineShift
textRef.TextRange.CharacterAttributes.TextFont = myAiApp.TextFonts.Item("Times")
textRef.TextRange.CharacterAttributes.FillColor.Black = 0
textRef.TextRange.CharacterAttributes.FillColor.Magenta = 100
textRef.TextRange.CharacterAttributes.FillColor.Yellow = 0
textRef.TextRange.CharacterAttributes.FillColor.Cyan = 0
If you agree please send your eps file via my email. I could be than more efficient.
Have a good evening
Patrice
*) open an office sofware (Word or Excel) and go to the Visual basic editor (alt+F11) and
copy and paste these script; replace nom_docAi with your eps file name
Public nom_docAi
Sub myPrg()
call OpenAi
call openBaseFile '= open the eps file
call myRectangle(100,100,200,300)
call saveEPS(nom_docAi )
call savePNG(nom_docAi )
end sub
Sub OpenAi()
'*** le fichier excel et illustrator se trouvent dans le même répertoire
myPath = ActiveWorkbook.Path
'*** Définition de la variable "application"
Set myAiApp = CreateObject("Illustrator.Application.CS4")
End Sub
Sub openBaseFile()
'*** Définition et ouverture du fichier illustrator de base
nom_eps = "cycle.eps"
'nom_docAi = myPath & "\" & nom_eps
nom_docAi = "G:\graph" & "\" & nom_eps
Set myDocAi = myAiApp.Open(nom_docAi, 1)
End Sub
Sub saveEps(myPictureName)
'*** Sauvegarde fichier
Set myDocAi = myAiApp.ActiveDocument
Set myEpsSave = CreateObject("Illustrator.EPSSaveOptions.CS4")
myDocAi.CropBox = myDocAi.VisibleBounds
myEpsSave.EmbedAllFonts = True
myEpsSave.Preview = aiColorTIFF
myEpsSave.postscript = ailevel3
myAiApp.ActiveDocument.SaveAs myPictureName, myEpsSave
End Sub
sub myRectangle(x, y, LenghRect, HeightRect)
'*** Sélection du calque recevant les rectangles
Set Laieur = docAi.layers("data")
myAiApp.Redraw
Set myRect = docAi.PathItems.Rectangle(y, x, LenghRect, HeightRect)
myRect.FillColor.Cyan = 0
myRect.FillColor.Yellow = 100
myRect.FillColor.Magenta = 35
myRect.FillColor.Black = 0
myRect.Stroked = False
myAiApp.Redraw
'mTab = myCColor(mType)
End Function
Sub savePNG(myPictureName)
'*** Sauvegarde fichier
myPictureName = Replace(myPictureName, ".eps", ".png")
Set myAiApp = CreateObject("Illustrator.Application.CS4")
Set docAi = myAiApp.ActiveDocument
Set pngExportOptions = CreateObject("Illustrator.ExportOptionsPNG24.CS4")
pngExportOptions.AntiAliasing = True
pngExportOptions.Transparency = True
docAi.Export myPictureName, aiPNG24, pngExportOptions
End Sub
Similar Messages
-
Is it possible to store script settings with InDesign file?
Hi,
I have some crazy idea: is it possible to store script settings with InDesign file?
In that case scripters will be able to store those settings with file, and when script runs - it can check if those setting exists - if so - script can run without showing dialogue with parameters... (as all necessary parameters stored with indesign file), and of course we can force InDesign to show script parameters dialogue if we run it with alt/option key pressed while running this script. Maybe even different scripts will be able to share those settings and interact with each other.. we will be able to have settings that will be saved with file, or temp settings for current document or session (till InDesign is closed). With eventListeners and startup scripts we will be able to do scripts that would be able to check for updates, and automatically execute when we placing images and text, and so on.. this can be a whole InDesign scripting framework, that allow to write scripts that will use same libraries and ui so we don't have to write everything from scratch everytime and just included required libs..
so here is 2 main questions for now:
1) is it possible to store script settings with .indd file
2) who is intrested in creation InDesign scripting framework (because this only makes sense if many people will use it)
PS: I know that it's possible to store settings in external file, but this time I'm interested only for saving params with .inddOk, here is the labels parser I end with, actually it works extremely fast!
Thanks again, Harbs!
var labels = GetDocLabels(app.documents[0]);
function GetDocLabels(doc)
var idmlFile = File(Folder.temp + "/temp.idml");
doc.exportFile(ExportFormat.INDESIGN_MARKUP,idmlFile); // asynchronousExportFile works, but script fails as it try to execute before file fully exported
var folder = Folder(Folder.temp + "/temp_idml");
app.unpackageUCF(idmlFile,folder);
var designMap = File(folder + "/designmap.xml");
var valuePairs = GetValuePairs(designMap);
return valuePairs;
function GetValuePairs(file)
file.open("r");
var contents = file.read();
file.close();
var contXML = XML(contents);
var vals = {};
for each(var pair in contXML..KeyValuePair)
vals[[email protected]()] = [email protected]();
return vals;
//> START of DELETE FOLDER Function
function deleteFolder(path)
removeFolder = path; // path to folder that need to be removed
filesToRemove = removeFolder.getFiles();
for(i = 0; i < filesToRemove.length; i++)
try
innerFolders = filesToRemove[i].getFiles();
if(innerFolders.length >= 1)
for(f = 0; f < innerFolders.length; f++)
innerFolders[f].remove()
catch(e){}
filesToRemove[i].remove(); // remove temp files once we done
removeFolder.remove();
}//< END of DELETE FOLDER function
// remove temp files once we done
deleteFolder(Folder(Folder.temp + "/temp_idml"));
File(Folder.temp + "/temp.idml").remove();
// DUMPER FUNCTIONS
function dump(o)
out = "";
for (var p in o)
out += p + ": " + o[p] + "\n";
return(out);
function alert_scroll (title, input)
if (input instanceof Array)
input = input.join ("\r");
var w = new Window ("dialog", title);
var list = w.add ("edittext", undefined, input, {multiline: true, scrolling: true});
list.maximumSize.height = w.maximumSize.height-100;
list.minimumSize.width = 550;
w.add ("button", undefined, "Close", {name: "ok"});
w.show ();
alert_scroll ("Document Labels", dump(labels)); exit(); -
How to publish infopath form using powershell script in infopath 2010?
Is any approach for such solution.Hi,
Try below command:
Uninstall the existing solution (based on the from file name):
Uninstall-SPInfoPathFormTemplate -Identity Exampleform.xsn
Install the new solution (based on the from file name):
Install-SPInfoPathFormTemplate -Path C:\Form.xsn
Disable feature on site collection level
Disable-SPInfoPathFormTemplate -Identity "Form.xsn" -Site http://SPSite
Enable feature on site collection level
Enable-SPInfoPathFormTemplate -Identity "Form.xsn" -Site "http://SPSite"
See this blogs for your ref:
http://rgielen.blogspot.in/2010/11/deploy-infopath-2010-forms-with.html
http://mysharepointwork.blogspot.in/2010/09/deploy-infopath-forms-with-powershell.html
Hope it could help
Hemendra: "Yesterday is just a memory,Tomorrow we may never see"
Whenever you see a reply and if you think is helpful, click "Vote As Helpful"! And whenever
you see a reply being an answer to the question of the thread, click "Mark As Answer -
Illustrator can't open eps files
I've been have an issue with CS3 and now CS5. When trying to open an eps file I get an error "Can't open illustration. Could not complete the requested operation". I can see a thumbnail, but nothing in the file shows up. Any ideas?
Tranparency gets flattened in the making of the .eps, and there is a choice as to whether you want to embed links.
If you somehitng simple with no transprency, you would be able to make yourself a nice editable .ai file out of this.
Once you have transparency, the those elements get merged and embedded, and often in quite a complex splicing.
You can place the .eps in Illustrator and then embed the .eps to convert the placed into some vector shapes you may need to grab. -
Getting Page Count for a Multi-Page PDF file using Illustrator script?
Does anyone know how to get the page count of a multi page PDF file? I know you can then open each page using the PDFFileOptions (pagetoopen). But I need to know up front how many pages there are to loop thru to open each page and process each page.
Any Ideas?This script i did for photoshop:
OK so lets do it working on WIN and MAC without any shell script.
This solution is not the best but its working.
I used Try catch to solve it.
Only issue is that you should at least somehow know how many pages you expect in pdf.. this mean if you are working with books or flyers...
Then set the maxPagesCount to that number.
I am working with pdfs with max 20pages.. so i start open the 20 then 19 then 18 and when i am success i know the amount of pages.
Its not the quicker way but its usable.
var maxPagesCount = 20;
var actPagesCount = maxPagesCount;
var opts1 = new PDFOpenOptions();
opts1.usePageNumber = true;
opts1.antiAlias = true;
opts1.bitsPerChannel = BitsPerChannelType.EIGHT;
opts1.resolution = 10; //it will load faster the test page
opts1.suppressWarnings = true;
opts1.cropPage = CropToType.MEDIABOX;
myFunction = function () {
try {
app.displayDialogs = DialogModes.NO;
var fileList = openDialog();
for (i = 0; i < fileList.length; i++) {
actPagesCount = maxPagesCount;
getPagesCount(fileList[i],maxPagesCount);
alert(actPagesCount);
} catch (exception) {
alert(exception);
getPagesCount = function (checkFile, lastPageID) {
try {
for (var checkPage = lastPageID; checkPage > 0; checkPage--) {
opts1.page = checkPage;
var docRef = open(checkFile, opts1, false);
docRef.close(SaveOptions.DONOTSAVECHANGES);
actPagesCount = lastPageID;
return;
checkPage=0;
} catch (exception) {
// Look for next page
checkPage--;
getPagesCount(checkFile,checkPage); -
Is this Possible using ODI / ODQ ?
Hi ALL,
Is the below requirement possible with ODI / ODQ?
(right now I am doing it mannually, and its like a monthly/weekly process)
If we can do the same using ODQ how I need to start and proceed?
My requirement is some thing like this. I have two columns
Address1 (street address)
Address2 (additional Information)
In some cases the address is not in the proper format. So I need to do some data cleansing (data scrubbing) before loading using ODI
Use Address2 if Address1 is PO Box, building name, or any info aside from a street address. Only one address column is needed in the output (Address1)
For example :
INPUT
ADDRESS1--------------------------------------------------ADDRESS2
HIGHWAY # ------------------------------------------------5010944 MARSH RD
PO BOX 40964---------------------------------------------1100 AA CORP PARKWAY
DBA VANTAGE PP---------------------------------------11031 PERRY HIGHWAY
HOME INFUSION THERAPY SERVICES--------11031 PERRY HIGHWAY
7275 BUFFALO ROAD----------------------------------(WAS 6855 BUFFALO ROAD)
7601 N FEDERAL HWY---------------------------------#2506
MCAS ---------------------------------------------------------(MARINE CORPS AIR STATION)
212 BRADDOCK AVENUE------------------------------
212 NINTH STREET----------------------------------------
2138 JONATHON DRIVE---------------------------------
OUTPUT (Note : we don’t need the Address2 column in the output)
ADDRESS1----------------------------------ADDRESS2
10944 MARSH RD------------------------10944 MARSH RD
1100 AA CORP PARKWAY-----------1100 AA CORP PARKWAY
11031 PERRY HIGHWAY-------------11031 PERRY HIGHWAY
11031 PERRY HIGHWAY-------------11031 PERRY HIGHWAY
7275 BUFFALO ROAD------------------(WAS 6855 BUFFALO ROAD)
7601 N FEDERAL HWY----------------#2506
MCAS-----------------------------------------(MARINE CORPS AIR STATION)
212 BRADDOCK AVENUE------------
212 NINTH STREET----------------------
2138 JONATHON DRIVE---------------
I have posted a similar kind of question in DATA Quality (ODQ) forum
Forum Home » Master Data Management (MDM) » Data Quality
ADDRESS CLEANING(US) USING ODQ
Thread: ADDRESS CLEANING(US) USING ODQ
if any body is working on address cleansing using ODQ, Please guide me to start working on it.
IS there any specific documents for ADDRESS CLEANING which gives more information about the process flows such as
Transformer, Customer Data Parser, Sort for Postal Matcher, Postal Matcher, Window Key Generator,Sort for Linking, Relationship Linker, Commonizer, and Data Reconstructor.
Thanks in Advance,
RathishHi Rathish,
I was building the java code but I got other idea to make more simple.
1) load the values into a temp table with one column for each address (means 2 columns per line) plus 2 other columns to control.
Something like:
table temp_data
columns: add_1 , control_1, add_2, control_2
You can do that thru an interface. Let the fields "control" with no value when loaded
2) create a table to storage the values you sent to me (Avenue, street...)
table street_names
columns: street_name, country (to your future use)
3) Create an ODI procedure (or you can customize a KM with the same technique)
3.1) Step 1 at target Tab, technology javaScript
code:
<@String vU=" ";@>
3.2.1) step 2 - Tab Source - technology "your database" and the Logical Schema where the "street_names" table as created
select street_name
from street_names
where country = 'US'
3.2.2) step 3 - Tab Target - tecnology javaScript
<@vU+="or instr(upper(add_1),upper('#street_name'))>0 ";@>
3.3) step 3 - Target Tab - technology "your database" and the Logical Schema where the "temp_data" table as created
<@vU=vU.substring(3);@>
update temp_data
set control_1 = 'Y'
where <@=vU@>
3.4) step 4 step 3 - Target Tab - technology "your database" and the Logical Schema where the "temp_data" table as created
<@vU=vU.replaceAll("add_1","add_2")@>
update temp_data
set control_2 = 'Y'
where <@=vU@>
4) Now you have a table (temp_data) with a flag "Y" where there is a street name and "null" where doesn't exist. Just generate your file by a interface or odiSqlUnload Toll.
Put all together into a package and you will have your process.
I create in this way to minimize the access to the temp_table, just 2 updates.
can be used some alternatives to tunning the hole process if the time doesn't match what you need.
That is a fast solution. Something more elaborated can be done if necessary.
Does it help you?
Cezar Santos -
Is this possible using APEX_ITEM.RADIOGROUP
Hi,
Just wondering if this can be achieved using APEX_ITEM.RADIOGROUP, i.e using radio buttons that gives the user three options:
<br><br>
Clothing/Size S M L
===========================
T-Shirt-Red O O O
<br>
etcCan someone please provide me if possible an example of achieving this.
<br><br>
Thanks.<br>
Tony.1. Create a text item for the main heading (Clothing / Size etc). You may want to embed some HTML to change colours, underline etc.
2. Create a radiogroup for each item as follows;
Label = T-Shirt-Red , etc
ELEMENT
Form Element Options Attributes => style="padding-left:100px" (assuming spacing of 100 px)
LIST OF VALUES
Columns => 3
Display Null => No
List of values definition => STATIC2:;S,;M,;L (assuming you want to pass back S, M or L)
You may need to muck around with the heading and spacing but this should do the trick -
Gradient Fill Individual Letters of Editable Type, is this possible in Illustrator?
I have a applied a gradient fill to editable point text via the appearance pallete, but that applys the gradient to all the type as a whole. Is there any way to fill each individual letter of the type with a gradient without converting into outlines?
Any help would be appreciated.I have it working in CS3 I didn't even have to use Effect>Path>Outline Object.
Type the text.
Remove the Default fill in the tool panel.
Text should have no fill. Now use the Appearance Panel to add a fill.
Now with the fill in the Appearance Panel selected, click on a Grad Swatch. -
Is this possible: Use BI Publisher with Oracle Express?
I am a new user, trying to learn BI Publisher (stand alone).
I've installed BI Pulisher OK. I have installed Oracle Databse Express
(for Windows) on the same PC with no problem.
Where/how to I connect/relate the two?
I'd like to use BIP with the HR schema.
Thank you!Sorry, but I do not see the detail needed to connect [Windows] Oracle 10g Database Express Edition to Oracle BI Publisher (both, latest editions).
Maybe I'm missing it. If you are referring to item 3.3 Configuring Application Express to use BI Publisher,
the documentation does not match my screen options. I do not see an "Administration Services home page". I see an "Admin" tab in
BI Publisher. I do not see a "Manage Service".
Am I looking at the correct documentation?
Please keep in mind, I just want to use the HR database in Express to learn the basics of BI Publisher.
Thanks again. -
Using Bash script to edit config file
This is a really simple question, but given that I'm just learning Bash scripting and having this solved now would be really illustrative for me, I would really thank some help here.
I'm using uzbl, and running Tor+Polipo. So, as you will see below in the tail of the config file, there is a line to redirect the requests of uzbl through Polipo.
# === Post-load misc commands ================================================
sync_spawn_exec @scripts_dir/load_cookies.sh
sync_spawn_exec @scripts_dir/load_cookies.sh @data_home/uzbl/session-cookies.txt
# Set the "home" page.
#set uri = https://duckduckgo.com
# Local polipo proxy
set proxy_url = http://127.0.0.1:8123
# vim: set fdm=syntax:
What I want to accomplish is to comment in/out that line with a key shortcut on Awesome. I've thought of doing 2 scripts to do so and using 2 differente key shortcuts, but I want to "toggle" the proxy redirection with only 1 shortcut. To do so, I suppose that the script should go something like:
if
tool 'set proxy_url = http://127.0.0.1:8123' config_file
then
tool '#set proxy_url = http://127.0.0.1:8123' config_file
else
if
tool '#set proxy_url = http://127.0.0.1:8123' config_file
then
tool 'set proxy_url = http://127.0.0.1:8123' config_file
fi
fi
I know little about sed, but I think is the tool for this job. The most intriging part to me is to ask sed to print the regular expression when it finds it in the config file, and use that as an input in the conditional statement.
Well, this is a mess I have done here. Hope there is a simple answer to this.
Thanks in advance.-You can do this with a single sed command:
sed -i 's/^#set proxy_url/set proxy_url/;
t end;
s/^set proxy_url/#set proxy_url/;
: end' config_file
This edits the file in-place (-i) and first tries to replace the commented with the uncommented line. If that suceeds, sed jumps to the "end" label. If not, it tries to replace the uncommented with the commented line. Thus you don't have to include any logic about the current state: if the first substitution succeeds, the line was obviously commented, if not, it was uncommented, and the second substitution should succeed.
Note that my knowledge of sed is very limited. There might be a simpler way to do this.
EDIT: For the sake of example, here's how to do the same in bash using regular expressions. Note how this script needs to use a temporary file to simulate in-place editing, how it needs to process the file line by line manually, etc. All things that sed does out of the box...
#!/bin/bash
tmp=test.conf.tmp
echo -n "" > "$tmp"
while read line; do
if [[ "$line" =~ ^#set\ proxy ]]; then
echo "${line/\#/}" >> "$tmp"
elif [[ "$line" =~ ^set\ proxy ]]; then
echo "#$line" >> "$tmp"
else
echo "$line" >> "$tmp"
fi
done < test.conf
mv test.conf.tmp test.conf
To answer your original question, the line
if [[ "$line" =~ ^#set\ proxy ]]; then
reads: if the line begins with a "#", followed by "set proxy", then...
Last edited by hbekel (2011-03-20 10:40:16) -
Hello,
I honestly have tried reading the other answers and researching to try to solve this problem. I'm sorry for my ignorance in this area. Please help!!!
I'm trying to make a script (for Illustrator CS2) that will batch convert several files to PNG files. The source folder has several subfolders and I need the script to go into the subfolders and convert those files as well. The destination directory should be an entirely separate folder but with the same hierarchy as the original source folder.
The script I have been using (that converts just as I need) is below. The only problem is it doesn't do the subfolders.
Any help would be so amazingly appreciated!
ADOBE SYSTEMS INCORPORATED
Copyright 2005 Adobe Systems Incorporated
All Rights Reserved
NOTICE: Adobe permits you to use, modify, and
distribute this file in accordance with the terms
of the Adobe license agreement accompanying it.
If you have received this file from a source
other than Adobe, then your use, modification,
or distribution of it requires the prior
written permission of Adobe.
ExportDocsAsPNG24.jsx
DESCRIPTION
This sample gets files specified by the user from the
selected folder and batch processes them and saves them
as PNGs in the user desired destination with the same
file name.
// Main Code [Execution of script begins here]
// uncomment to suppress Illustrator warning dialogs
// app.userInteractionLevel =
UserInteractionLevel.DONTDISPLAYALERTS;
var destFolder, sourceFolder, files, fileType,
sourceDoc, targetFile, pngExportOpts;
// Select the source folder.
sourceFolder = Folder.selectDialog( 'Select the folder
with Illustrator files you want to convert to PNG', '~'
// If a valid folder is selected
if ( sourceFolder != null )
files = new Array();
fileType = prompt( 'Select type of Illustrator files
to you want to process. Eg: *.ai', ' ' );
// Get all files matching the pattern
files = sourceFolder.getFiles( fileType );
if ( files.length > 0 )
// Get the destination to save the files
destFolder = Folder.selectDialog( 'Select the
folder where you want to save the converted PNG files.',
'~' );
for ( i = 0; i < files.length; i++ )
sourceDoc = app.open(files[i]); // returns
the document object
// Call function getNewName to get the name
and file to save the pdf
targetFile = getNewName();
// Call function getPNGOptions get the
PNGExportOptions for the files
pngExportOpts = getPNGOptions();
// Export as PNG
sourceDoc.exportFile( targetFile,
ExportType.PNG24, pngExportOpts );
sourceDoc.close
(SaveOptions.DONOTSAVECHANGES);
alert( 'Files are saved as PNG in ' + destFolder
else
alert( 'No matching files found' );
getNewName: Function to get the new file name. The
primary
name is the same as the source file.
function getNewName()
var ext, docName, newName, saveInFile, docName;
docName = sourceDoc.name;
ext = '.png'; // new extension for png file
newName = "";
for ( var i = 0 ; docName[i] != "." ; i++ )
newName += docName[i];
newName += ext; // full png name of the file
// Create a file object to save the png
saveInFile = new File( destFolder + '/' + newName );
return saveInFile;
getPNGOptions: Function to set the PNG saving options of
the
files using the PDFSaveOptions object.
function getPNGOptions()
// Create the PDFSaveOptions object to set the PDF
options
var pngExportOpts = new ExportOptionsPNG24();
// Setting PNGExportOptions properties. Please see
the JavaScript Reference
// for a description of these properties.
// Add more properties here if you like
pngExportOpts.antiAliasing = true;
pngExportOpts.artBoardClipping = true;
pngExportOpts.horizontalScale = 300.0;
//pngExportOpts.matte = true;
//pngExportOpts.matteColor = 0, 0, 0;
pngExportOpts.saveAsHTML = false;
pngExportOpts.transparency = true;
pngExportOpts.verticalScale = 300.0;
return pngExportOpts;You can turn off some of the dialogs with: app.displayDialogs = DialogModes.NO;
#target photoshop
if (app.documents.length > 0) {
//Turn display dialogs off
app.displayDialogs = DialogModes.NO;
//=============Find Current Documents path================//
var CurrentPath = activeDocument.path;
//=============Establish current documents destination===============//
var folder1 = Folder(CurrentPath + '/' + 'Flats');
//=============Check if it exist, if not create it.============//
if(!folder1.exists) folder1.create();
//=============Establish current documents file name=========//
//Current filename without the extension
var CurrentFileName = app.activeDocument.name.replace(/\.[^\.]+$/, '');
//=============Modify current file name================//
var modifiedFileName = CurrentFileName +"Flat.psd";
//=============Establish save path====================//
var saveFileCurrentPath = new File(folder1 + '/' + modifiedFileName);
//=============Flatten document ====================//
activeDocument.flatten();
//=============Rotate document if in 'Landscape'====================//
var myDocument = app.activeDocument;
if (myDocument.width > myDocument.height) myDocument.rotateCanvas(90);
//============Save File=======================//
psdSaveOptions = new PhotoshopSaveOptions();
activeDocument.saveAs(saveFileCurrentPath, psdSaveOptions, true, Extension.LOWERCASE);
//Close Document
app.activeDocument.close(SaveOptions.DONOTSAVECHANGES); -
II'm new to forums so be kind and I'm also 70 years old so explain simply.
Hi rushbo. I am of the opinion that it is much better to save as much information with the files. Use Lightroom to organize and process the images, but keep the data with the images when possible. (There are tradeoffs to this approach, mostly speed and complexity, but it means that there is one place to look for information about a file, even if you have multiple catalogs).
If you agree with this, first read What Is Not Included In Lightroom XMP Files | Lightroom Fanatic to see what data is not saved.
Then I would go from the oldest to the newest catalog, and for each turn on "Catalog settings:automatically write changes into xmp" and then save the metadata for all the files in the catalog (Select All; Save Metadata). You might also want to choose "Delete Rejected Files" to get rid of them permanently.
Do this for each catalog, and at the end every image will have the settings from the latest catalog (earlier values will be overwritten).
Then create a new catalog and import the files. This will bring in every image in your directory tree (wherever you store images on your disk). It might even discover some images that aren't in your catalogs. And each image will have the latest data. Finally archive your old catalogs "just in case".
This process can be slow, so put on a movie...
A -
How to solve this problem in shell script: unexpected end of file
Hello,
I need to connect to each databases listed in /etc/oratab and check which database is shutdown(or mounted-only) and which database is opened to accept connection. However, following shell script gives me this error message:
$>./check_is_db_runing.sh
./check_is_db_runing.sh: line 39: syntax error: unexpected end of file
Could anyone please help me to solve this problem, why the code (line 29 to 32) does not work in the LOOP? It works without the LOOP.
Thanks in advance!!!
1 #!/bin/bash
2
3 LOGDIR=/data03/oracle/dbscripts
4 ORATABFILE=/etc/oratab
5
6 cat $ORATABFILE | while read LINE
7 do
8 case $LINE in
9 \#*) ;; #comment-line in oratab
10 *)
11 ORACLE_SID=`echo $LINE | awk -F: '{print $1}' -`
12 if [ "$ORACLE_SID" = '*' ] ; then
13 # NULL SID - ignore
14 ORACLE_SID=""
15 continue
16 fi
17
18 # Proceed only if last field is 'Y'
19 if [ "`echo $LINE | awk -F: '{print $NF}' -`" = "Y" ] ; then
20 if [ `echo $ORACLE_SID | cut -b 1` != '+' ]; then
21
22 ORACLE_HOME=`echo $LINE | awk -F: '{print $2}' -`
23 PATH=$ORACLE_HOME/bin:/bin:/usr/bin:/etc
24 export ORACLE_SID ORACLE_HOME PATH
25 LOGFILE=$LOGDIR/check_$ORACLE_SID.log
26 touch $LOGFILE
27 #echo $LOGFILE
28
29 $ORACLE_HOME/bin/sqlplus -s "/ as sysdba" << EOF > $LOGFILE
30 select * from global_name;
31 exit
32 EOF
33
34 fi
35 fi
36 ;;
37 esac
38 doneThis code works ie. generates logs with sql result - slightly modified to be runable:
#!/bin/bash
LOGDIR=/tmp
ORATABFILE=/etc/oratab
cat $ORATABFILE | while read LINE
do
case $LINE in
\#*) ;; #comment-line in oratab
ORACLE_SID=`echo $LINE | awk -F: '{print $1}' -`
if \[ -z $ORACLE_SID \] ; then
# NULL SID - ignore
ORACLE_SID=""
continue
# Proceed only if last field is 'Y'
else
ORACLE_HOME=`echo $LINE | awk -F: '{print $2}' -`
PATH=$ORACLE_HOME/bin:/bin:/usr/bin:/etc
export ORACLE_SID ORACLE_HOME PATH
LOGFILE=$LOGDIR/check_$ORACLE_SID.log
touch $LOGFILE
#echo $LOGFILE
$ORACLE_HOME/bin/sqlplus -s "/ as sysdba" << EOF > $LOGFILE
select * from global_name;
exit
EOF
fi
esac
done -
Using a script to rename a file from the file info cart Cut Num (ID)??
Hi,
Can any of you guys tell me if its poss to do a script to rename a wav with the file info, cart, Cut Num ID field....??? (Cart chunks)
Example file at the moment is called {C5E5F0FE-57D9-4A9A-8DA1-58D1AE7017FD}.wav and I want to grab the info out of the File info, cart section, under Cut Num (ID) which has 9558 in it and rename the file so it is now 9558.wav when it saves or just renames it.I also then want to run the script as i have 6000 plus wav,s to do this too.
Thanks for any info.
Glen>Can any of you guys tell me if its poss to do a script to rename a wav with the file info, cart, Cut Num ID field....??? (Cart chunks)
No, scripts in Audition won't let you do this at all. In fact, Audition's scripting function really isn't very file-friendly, relating pretty much just to basic Audition functionality. And there's no way that an Audition script would let you rename a file anyway - they the closest they get to handling any file-related functions is that you can open a designated noise reduction profile - but that's about it.
There's one place that I know of where you might find a utility to do what you want -
here (try WidgetPro). -
Is it possible to monitor State change of a .CSV file using powershell scripting ?
Hi All,
I just would like to know Is it possible to monitor State change of a .CSV file using powershell scripting ? We have SCOM tool which has that capability but there are some drawbacks in that for which we are not able to utilise that. So i would like
to know is this possible using powershell.
So if there is any number above 303 in the .CSV file then i need a email alert / notification for the same.
Gautam.75801Hi Jrv,
Thank you very much. I modified the above and it worked.
Import-Csv C:\SCOM_Tasks\GCC2010Capacitymanagement\CapacityMgntData.csv | ?{$_.Mailboxes -gt 303} | Export-csv -path C:\SCOM_Tasks\Mbx_Above303.csv;
Send-MailMessage -Attachments "C:\SCOM_Tasks\Mbx_Above303.csv" -To “[email protected]" -From “abc@xyz" -SMTPServer [email protected] -Subject “Mailboxex are above 303 in Exchange databases” -Body “Mailboxex are above 303 in Exchange databases"
Mailboxex - is the line which i want to monitor if the values there are above 303. And it will extract the lines with all above 303 to another CSV file and 2nd is a mail script to email me the same with the attachment of the 2nd extract.
Gautam.75801
Maybe you are looking for
-
Connecting to a cube via a linked server
Hi I want to connect to a SSAS cube via a linked server. When I ran a query against the SSAS cube from directly from the SQL server it runs fine. If however I run the query in SSMS from my PC I get OLE DB provider "MSOLAP" for linked server "SSASServ
-
Having many problems in TB 31.1.2. Selecting an email address from address book used to be very FAST; type in a couple of letters and hit enter. Now there is a distinct and long pause before the selection appears after typing in a couple of letters.
-
I am having trouble getting audio from a DVD.
Initially when I insert the DVD i get audio playing. Then, I pair my bluetooth headphones, they say they are connected but I get no audio from the laptop speakers or from my headphones. I disconnect the headphones and still get no audio from the la
-
Unable to install JDT example plugins in NetWeaver Studio
Hello, I am using the SAP Web AS (Java 6.40) Sneak Preview Edition and am having a problem installing the JDT example plugins in the NetWeaver Developer Studio WorkBench. I have followed the instructions given in the 'Java Development User Guide' of
-
How to pass some default values in all elements which are blank in xslt.
Hi, Help needed: Scenario: After .xslt transformation, there are some elements which are being mapped but left blank. I want to assign some default values to it like '0'. How to do that. Thanks.