Converter utility in E7

As a smart business phone, it lacks converter function...
I request nokia to pack it in next update

I believe I have seen a few converters on OVI store. Try it out it is not bad at all
http://store.ovi.com/

Similar Messages

  • Problem in converting util date format to sql date format

    im trying to convert util date to sql date...i'm getting the error msg as
    Error is : java.lang.NullPointerException
    Error Message : null
    i'm not bale to track the result...whatz the problem with this code?
    This fromDate value will be dynamically built, value will be
    fromDate="Tue Jul 15 00:00:00 IST 2003";
    java.util.Date xx=util.stringToDate(fromDate);
    java.sql.Date sqlD=null;
    sqlD.setTime(xx.getTime());
    System.out.println("sqld"+sqlD);

    I try this and it works:
    SimpleDateFormat simpledateformat = new SimpleDateFormat("EEE MMM dd HH:mm:ss z yyyy", Locale.UK);
    String s = "Tue Jul 15 00:00:00 IST 2003";
    java.util.Date date = simpledateformat.parse(s);
    java.sql.Date sqlD=new java.sql.Date(date.getTime());
    System.out.println("sqld"+sqlD);
    Hope this helps.

  • Convert util.Date to sql.Date with time being displayed!

    Hi all,
    I want to convert util.Date to sql.Date for passing the same to Database. (i donot want to use Timstamp, for some reasons)
    java.sql.Date sqldate =
    new java.sql.Date(new java.util.Date().getTime());
    This simple code truncates the Time component and the result will be only Date. But my requirement is for Data and Time, both.
    Request anyone to suggest how to go abt this problem.
    Thanx.

    You can use the class java.text.DateFormat (java.text.SimpleDateFormat) for displaying. For example like this.
    java.sql.Date sqldate = new java.sql.Date(new java.util.Date().getTime());
    java.text.SimpleDateFormat formatter = new java.text.SimpleDateFormat("yyyy.MM.dd 'at' HH:mm:ss z");
    String str = formatter.format(sqldate);
    System.out.println(str);

  • Reports Converter Utility in 10g

    can we install only reports converter utility 10g on a machine for reports complining purpose insted of complete reports and forms installation.

    not possible.

  • Exists: mxml to ActionScript converter utility?

    Is there a standalone or web utility where you paste mxml and the utility shows you the equivalent in ActionScript?

    That is exactly what the Flex compiler does (mxmlc I believe is the file name).  If you want to see the generated ActionScript code, I believe there is a -keep-generated-actionscript flag.

  • How to convert EPS(image file) file in to other image format e.g NIGMAS

    Hi friends,
    I want to make a tool which will help to convert the EPS image file into other image format BY USING JAVA TECHNOLOGY. I havent done this type of file conversion before, so any body please explain it to me from the basic how can i go for it, what r the require things, where should i get the help of it, which java API should i use etc. i ll be vry thankful.
    My actual requirement is i want to convert the EPS file into the NIGMAS(Nihon computer graphic mapping System) file format.
    Thank you in anticiption.

    The easiest, but not necesarily the best, way is to use ImageMagick's convert utility. From Java you can use Runtime.exec to invoke convert.exe ... ImageMagick is opensource and supports many different formats ( www.ImageMagick.com )
         * Converts an eps file to a graphic that is suitable for the web.
         * We use ImageMagick's 'convert' utility to convert .eps files into either gif or png format.
         * The output format is determine by the extension that you set for the output file.
         * Sample command:
         * convert -density 208x208 /export/home/kpmg/tomcattest/jsp/1.eps
         *                                    /export/home/kpmg/tomcattest/jsp/1.png
         * Although convert supports about 100 different parameters, we are only using 1:
         * -density     (sets the vertical and horizontal resolution in pixels of the image)
         * Density sets the vertical and horizontal resolution in pixels of the image.
         * It should be changed based on the resolution of the user's monitor
         * (e.g. if hi-res display settings, then density will need to be greater
         * than if running on a low-res display, which would make the same image look really big )
         * You may want to use other convert parameters, such as -sharpen
         * to make the image look better, or -compress and
         * -quality to change the kb size of the image.
         * For the full list of parameters see:     
         *      http://www.imagemagick.org/www/convert.html
         * @param inFile The absolute path to the eps file to be converted
         * @param outFile The absolute path to the desired output graphic file.
         *                         NOTE: the format of the output file is determined by the
         *                         extension that you give for this parameter (e.g. file.png will
         *                          be written as a png file )
    public void eps2www(String inFile, String outFile, String density) throws Exception
              // use ImageMagick's convert program to make the www version ( png or gif, etc)
              String call = convert +
                        " -density " + density +
                                  " " + inFile +
                                  " " + outFile;
              try
                   Process child = rt.exec( call );
                   child.waitFor();
                   log.debug("Convert process exit code is: " + child.exitValue() );
              catch (Exception e)
                   // TO DO: this could probably be more explicit
                   throw new Exception(e);     
              // log the command strings for debuggin purposes.
              log.debug( "Convert Successful: call = " + call);
         }

  • How to convert all old (pre-Office 2007) documents in portal to new (Office Open XML, Office 2007+) formats?

    Good day.
    We have create a single SharePoint 2013 farm and manually copied in it all documents from old SharePoint 2007 server portal.
    The question is how to automate covertation from old document format to new office in all librarys?
    "Word Automation Services" able to convert only Word's documents, not Excel.
    The single method what I think, is to use bulk convert utility ofc.exe from Microsoft Office Migration Planning Manager with powershell's ability to get all items from all librarys from site collection.
    Can someone has faced with it and has a ready work example?

    Hi,
    According to your description, my understanding is that you want to convert all office file to the latest 2007 format.
    We found this tool called MS Office Migration Planning Manager:
    http://www.microsoft.com/downloads/details.aspx?FamilyID=13580cd7-a8bc-40ef-8281-dd2c325a5a81&DisplayLang=en#filelist
    After extracting it, going to the Tools folder and modified the ofc.ini file to specify which folder to scan and convert etc.
    Then running  the ofc.exe and except some files didn't convert successfully, others is ok.
    https://technet.microsoft.com/en-us/library/cc179019(v=office.14).aspx
    Besides, Here is a similar post, you can use as a reference:
    https://social.technet.microsoft.com/Forums/office/en-US/8c571ca4-8ef6-496e-950a-6a608d44a070/how-to-convert-all-office-file-to-the-latest-2007-format?forum=ITCG
    Best Regards,
    Lisa Chen
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • How to convert OLM files into windows office 2010

    I have temp. a desktop PC and I would like to import my MAC outlook file (.olm) into my office windows 2010 computer. Is there a way to import my olm file inti my windows office 2010?
    Regards

    Yes, definitely there’s a way to import OLM file to Windows Outlook 2010; in addition not only 2010 although to 2013 as well however it would be by means of a third-party converter utility.
    https://plus.google.com/114420112222101751665/posts/ENEX3Q2whKa

  • Convert Word for Mac 3 documents

    Sorry for my borderline inquiry: I am sitting on some older documents written by WORD for Mac 3 (in the early nineties) that I need to open again for my work. MS Word 2004 doesn't, neither does Apple Works or even MacLinkPlus up from version 12.
    The MS site is not very helpful on this issue, but perhaps you guys can give me a hint on a suitable converter utility.
    Thanks a lot,
    W

    Gruß dich Wolfgang,
    An older version (AppleWorks 5, or ClarisWorks) has the appropriate MacLink translators for Word 3. If you don't have access to an older version (and if the file isn't huge or doesn't contain sensitive information), you can send it to me and I will see if I can resave it in a current format.
    Hans aus Wein

  • When to convert to DNG

    Is there any difference in the DNG conversion process.....
    a. Convert with LR upon import
    b. use LR to convert after import
    c. Import from card without LR, run Adobe DNG converter and then import into LR
    Does it matter which way this is done??

    > "Barry .... Whenever I convert my raws to dng a dng file is created in the same folder as the original raw file".
    Note what I said:
    > "I use "d": I import from the card or portable storage device using DNG Converter".
    I use DNG Converter as a "copy & convert" utility, with 2 different locations. ("Save in New Location"). My original files never leave the card or storage device until I delete or reformat them. There are only DNGs on my system. So this only works as long as I never want my original raw files for any reason. (I haven't needed them in the last 2 years 9 months!)

  • DNG Converter download?

    When trying to download the free DNG Converter utility, nothing happens after I click download now. What's the problem?

    I'm not sure, but I think maybe things are not going as they should. Download time remaining goes up and down and percent downloaded is not going up very fast. Currently indications are: 6% with 3 hours and 13 minutes left. I think the download has stopped at this point.

  • Converting an image as a blob content from .gif format to .jpg format

    Hi
    Does anyone know how to convert a blob content from .gif format to .jpg format?
    I've tried looking at the process-method of intermedia, but I can't figure out how it's supposed to work... I'm on a 10.2.0.2 standard edition database
    I simply have a blob containing a gif-image, and I want it to be convertet to a jpg-image for further use
    Can anyone help?
    Thank you
    /Klaus Mogensen

    Hi
    Does anyone know how to convert a blob content from
    .gif format to .jpg format?
    I've tried looking at the process-method of
    intermedia, but I can't figure out how it's supposed
    to work... I'm on a 10.2.0.2 standard edition
    database
    I simply have a blob containing a gif-image, and I
    want it to be convertet to a jpg-image for further
    useWhat OS is the database running on? If it is a *nix flavour, you can call out to image magick convert utility (it is pre-installed on most linux variants, and you can compile it from source for other unixes). So you would probably store the blob into a temp file on the database server, call out to the shell to execute convert, and then load a blob from the converted file. See http://imagemagick.org for more information.
    If that is not an option, you might be able to use Java Advanced Imaging API from a Java stored proc to convert between those image formats. See http://java.sun.com/products/java-media/jai/downloads/download-1_1_2.html
    gojko adzic
    http://gojko.net

  • Keynote 3: Transparent Animated GIF Problems

    I've been trying to get an animated GIF with a transparent background to run in Keynote, but it's giving some disastrous results.
    I produce the animation by rendering the frames as PNG (with alpha channel) in MegaPOV 1.2.1. Then I use the convert utility from ImageMagick 6.2.9 to make them into an animated GIF.
    When I drop the animated GIF into Keynote 3.0.2, the first frame shows fine (with transparency and all). But when I animate it, the background goes red (the main color in this particular movie) and some trace of the previous frames stays. It seems like:
    1. Rather than displaying the GIF frame-by-frame, each frame is getting layered onto the previous frames.
    2. Keynote doesn't like the alpha channel for some reason.
    Problem 1 is also present if I open the GIF in Preview (is that supposed to be the correct behavior of an animated GIF?). Problem 2 seems to be Keynote-specific.
    Any suggestions for a work-around on this? The animated GIFs work fine if rendered without the alpha channel, but it'd look so much better with transparency!
    iMac 2GHz Intel Core 2 Duo   Mac OS X (10.4.9)  

    MegaPOV doesn't have a GIF output option. The choices are PNG, Targa, PPM, and hdr (not familiar with that last one). I don't know if PPM even has alpha-capability.
    So in some way, I have to convert PNG to GIF. The tools I have to do this are ImageMagick and Gimp. I tried them both, then viewed the results using several programs. Results are tabulated below -- (1) means that problem 1 from above was apparent (ie, parts of the previous frames were visible under the current frame); (2) means that problem 2 was visible (ie, the transparent parts took on some background color).
    If I didn't know how to change the default white background in the program, I couldn't tell whether problem (2) occurred, since the movie made with Gimp had a white background in Keynote.
    Using ImageMagick 6.2.9 to convert PNG->GIF and animate GIF:
    * viewing with Safari 2.0.4 : (1), can't tell for (2)
    * viewing with Preview 3.0.9 : (1), can't tell for (2)
    * viewing with Firefox 2.0.0.3 : (1)
    * viewing with Keynote 3.0.2 : (1), (2) -- alpha goes red
    Using Gimp 2.2.11 to convert PNG->GIF and animate GIF:
    * viewing with Safari : (1), can't tell for (2)
    * viewing with Preview : (1), can't tell for (2)
    * viewing with Firefox : (1)
    * viewing with Keynote : (1), (2) -- alpha goes white
    I only converted the first few frames using Gimp, since I was doing it by hand.
    All of this makes me wonder whether I'm dreaming the impossible, since problem (1) is universally present. It also makes me pretty sure that problem (2) is Keynote-specific.
    If there are any other tools that will convert/animate GIFs on a modern Mac, I'd love to hear about them. My UNIX-y tools seem to be failing me here. The Mac tools I remember from "back in the day" -- GIFBuilder and GIFConverter -- seem to have been abandoned around the beginning of Mac OS X. GIFBuilder won't even load my files, and GIFConverter still lacks alpha support in PNG.

  • Can't keep extension settings different in different profiles

    I created a second profile called Shopping. I imported the extensions from my default profile into it. I wanted to run Shopping with a different set of enabled and disabled extensions from what I normally run on my Default profile. (On Shopping I enabled a number of shopping-related extensions I normally keep disabled on Default.) But I have found that I'm not able to separate the two profiles in this respect. When I brought up Default after using Shopping, the enabled/disabled configuration I had left Default with had been replaced with the enabled/disabled configuration of Shopping. This defeats my whole purpose in creating the Shopping profile. How can I keep the enabled/disabled extensions configurations of these two profiles separate?
    Firefox 34.0.5
    Computer: Dell System B3 Desktop
    CPU: Intel Pentium 4-2667 (Northwood, D1)
    2666 MHz (20.00x133.3) @ 2657 MHz (20.00x132.9)
    Motherboard: DELL 0G1548
    Chipset: Intel 845GEV (Brookdale-GEV) + ICH4
    Memory: 2048 MBytes @ 166 MHz, 2.5-3-3-7
    - 1024 MB PC3200 DDR-SDRAM - Kingston K
    Graphics: Intel 82845G/GL/GV Graphics Controller [DELL]
    Intel i845G(L) Integrated, 64 MB
    Drive: ST380011A, 78.1 GB, E-IDE (ATA-6)
    Drive: HGST HTS545050A7E380, 488.4 GB, Serial ATA 3Gb/s <-> USB
    Drive: SAMSUNG CD-R/RW SW-252S, CD-R Writer
    Sound: Creative Technology SB Live! Series Audio Processor
    Network: RealTek Semiconductor RTL8139 PCI Fast Ethernet NIC [A/B/C]
    Network: Broadcom 4401 10/100 Integrated Controller
    OS: Microsoft Windows XP Home Edition Build 2600 SP3
    Enabled Plugins in Default :
    * Google Update
    * NPRuntime Script Plug-in Library for Java(TM) Deploy
    * DRM Netscape Network Object
    * DRM Store Netscape Plugin
    * PDF-XChange Viewer Netscape Gecko Plugin
    * The QuickTime Plugin allows you to view a wide variety of multimedia content in Web pages. For more information, visit the QuickTime Web site.
    * SaveSenseLive Update
    * VLC media player Web Plugin 2.1.3
    * NPWLPG
    * Npdsplay dll
    Extensions enabled in Default:
    -Add-ons Manager Context Menu 0.4.2
    Add more items to Add-ons Manager context menu.
    3/10/2014
    -Addon List Dumper (restartless) 0.1
    This extension adds a widget on the navigation bar.
    When this widget is pushed, a panel will show the addons list
    9/13/2014
    -Advanced SystemCare Surfing Protection 1.0
    Protect your computer away from malicious website attack.
    12/18/2013
    -Amazon 1Button App for Firefox 5.25
    This is an official Amazon extension for Firefox
    10/12/2014
    -Anti-Phishing 1.0
    Anti-Phishing extension.
    3/28/2014
    -Block Sneaky Redirects 1.3
    Finds links that tracks your browsing activity and blocks redirecting via their sites. This tool will fix the redirects and take you to the intended website directly.
    5/11/2014
    -Browser Security 0.7
    This browser application is designed to secure your browser, while surfing the internet.
    + Enhances your browser performance
    + Makes surfing the internet more secure
    + Protects you from phishing attacts
    9/23/2014
    -Capture & Print 0.1.9.2
    This add-on lets you print a webpage's area easily.
    6/9/2014
    -Classic Theme Restorer 1.2.7
    'Classic Theme Restorer' brings back appmenu button, squared tabs, add-ons bar, small nav-bar buttons, a few older buttons and more to Firefox Australis UI. Use 'Customize' menu to move buttons on toolbars.
    6/16/2014
    -Default 34.0.5
    The default theme.
    2/21/2014
    -Facebook Phishing Protector 4.4.3
    Protects you from Phishing or Scams (through XSS injection attacks) while you're on Facebook™
    9/23/2014
    -FoxBleed 0.1
    Checks all websites you are visiting, whether they are affected by the Heartbleed vulnerability.
    5/1/2014
    -FromWhereToWhere 0.25.5
    List the pages from where you visit one page, and all the other pages you visited from those pages. Link suggestion based on current page title and browsing history.
    9/13/2014
    -GPU Accelerated Flash Player 1.31
    Enables GPU acceleration of flash player by injection «gpu» value to «wmode» flash object attribute.
    9/23/2014
    -Google Image Search 1.15
    Adds Google Image Search to right-click menu on images.
    3/21/2014
    -Google Update 1.3.25.11
    Google Update
    11/14/2014
    -Heartbleed-Ext 3.0
    Checks websites for Heartbleed bug
    5/1/2014
    -Image Zoom 0.6.3
    Adds zoom functionality for images
    3/18/2014
    -JSONView 0.9
    Views JSON in the browser.
    9/23/2014
    -Java Deployment Toolkit 7.0.710.14 10.71.2.14
    NPRuntime Script Plug-in Library for Java(TM) Deploy
    10/20/2014
    -LastPass 3.1.54
    Last Password you will ever need
    2/25/2014
    -Lazarus: Form Recovery 2.3
    Recover lost forms with a single click
    3/10/2014
    -LinkExtend 1.1.5
    The Ultimate Link Tool!
    3/26/2014
    -Memory Fox 7.4
    A Mozilla Firefox Memory Recovery and Retention Add-On
    3/11/2014
    -Menu Editor 1.2.7
    Customize application menus
    9/23/2014
    -Microsoft® DRM 9.0.0.4504
    DRM Netscape Network Object
    7/7/2011
    -Microsoft® DRM 9.0.0.4504
    DRM Store Netscape Plugin
    7/7/2011
    -New Tab King 6.0.5
    Forget about the blank new tab
    3/10/2014
    -No Small Text 4.1
    Easily set a minimum font size for all web content.
    9/13/2014
    -NoSquint 2.1.9
    Manage site-specific zoom levels and color settings
    4/23/2014
    -Norwell History Tools 2.0
    No orwellian history
    8/17/2014
    -Open Tab Count 1.1
    This extension displays the number of open tabs for each window and the total number of open tabs (in all windows) in the status bar.
    3/10/2014
    -OpenH264 Video Codec provided by Cisco Systems, Inc. 1.1
    Play back web video and use video chats.
    12/31/1969
    -Organize Status Bar (Revived) 0.1.0
    Organize your status bar icons.
    9/13/2014
    -PDF Viewer 1.0.277
    Uses HTML5 to display PDF files directly in Firefox.
    5/30/2014
    -Perfect Redirector 4.0.1
    Automatically prevents Malware from known malicious websites. Prevents loading of known blacklisted sites, browse the net-safer!
    9/23/2014
    -Print Edit 13.3
    Print preview with integrated edit capability.
    9/23/2014
    -Print Friendly & PDF 1.1.0
    Add printfriendly button to your browser.
    9/2/2014
    -Print Selection 1.rev39
    Add a context menu option to print the selected text keeping the source format.
    Icon credicts go to dtafalonso (http://dtafalonso.deviantart.com/)
    9/24/2014
    -Print pages to PDF 0.1.9.3
    Creates PDF from Tabs,Bookmarks, Scrapbook(Plus)
    3/9/2014
    -QuickJava 2.0.6
    Enable/Disable Javascript, Java, Flash, Silverlight, Animated Images, Cookies, Images, CSS, and Proxy from Toolbar.
    2/25/2014
    -QuickTime Plug-in 7.7.5 7.7.5.0
    The QuickTime Plugin allows you to view a wide variety of multimedia content in Web pages. For more information, visit the QuickTime Web site.
    2/28/2014
    -Resurrect Pages 2.0.6
    Resurrect dead pages, by finding their ghosts.
    11/20/2014
    -RightToClick 2.9.5
    Allows right clicks, highlighting and more where forbidden by javascript
    11/15/2014
    -Rotate Image 0.1.3.2
    Rotate images on webpages
    9/13/2014
    -Safe Preview 1.1.2
    Before to jump to any website, make sure that it is safe. Check suspicious links on Google Advisory, McAfee, Norton Safe Web, WOT, Avast, TrustWave, DrWeb.
    3/28/2014
    -Scan Url with 2.2.rev219
    Scansiona Link
    3/28/2014
    -Search Engine Security 1.2.0
    Protects against Blackhat spam Search Engine Optimization (SEO)
    4/22/2014
    -Session Manager 0.8.1.6
    Saves and restores the state of all windows.
    3/10/2014
    -Settings Guard for Firefox 0.5
    Detects and resets changes to settings that are frequently done by add-ons and application installers.
    3/28/2014
    -SiteCheck extension for Firefox 1.0.3
    Scan any website for security issues, blacklisting, and malware with Sucuri SiteCheck
    3/28/2014
    -StatusbarEx 0.3.5
    Display information on the addon-bar, such as memory usage, CPU usage, network speed, and so on.
    9/13/2014
    -Tab Mix Plus 0.4.1.5.2
    Tab browsing with an added boost.
    2/28/2014
    -Textise Add-On v3.0 3.0
    Textise is an Internet tool that can create a text only version of almost any web page.
    9/24/2014
    -Troubleshooter 1.1a
    Provides Firefox troubleshooting data to Mozilla web sites.
    10/6/2014
    -UnPlug 2.056
    Find and download media from websites
    10/23/2014
    -Web2PDF converter 1.12
    Web page to pdf convertion utility
    10/8/2014
    -Windows Live® Photo Gallery 14.0.8117.416
    NPWLPG
    4/16/2010
    -Windows Media Player Plug-in Dynamic Link Library 3.0.2.629
    Npdsplay dll
    7/7/2011
    -iWeb2x 1.0
    Convert web page to printer friendly PDF, image snapshot, or high resolution wallpaper
    9/24/2014
    -open tab count widget 0.99.1
    Adds a widget displaying the open tab count (over all windows) to the add-on bar. Can be moved to the toolbar. Very bare-bones.
    Created with addon builder (jetpack), so it should be future proof.
    3/25/2014
    -toolbarmode 0.7.5
    Context menu to customize individual toolbars.
    6/17/2014
    -urlcheck 0.1
    a basic add-on
    8/16/2014

    ''the-edmeister [[#answer-666854|said]]''
    <blockquote>
    '''''"I created a second profile called Shopping. I imported the extensions from my default profile into it."'''''
    If you used Sync to do that "import", disable Sync for at least one of those Profiles.
    </blockquote>
    Thank you for your suggestion. I have Sync enabled for all the profiles. To my surprise, however, Sync was of no use in getting Default's extension collection into Shopping. For that I had to resort to the article http://kb.mozillazine.org/Transferring_data_to_a_new_profile_-_Firefox.
    I will try disabling Sync on Shopping.

  • Saveas Scripting help request

    I am trying to piece together a maro that will initially resize an image and save it with a different suffix at different size increments. I found within the cs5 scripts folder the macro 'Fit Image.jsx' that would allow me to resize correctly but am lost on how to add in the subsequent save steps and additional resize and saves. I would like to have it save the image with 5 different file sizes and suffixes (400x400 '-2' suffix, 250x250 '-2T', 150x150 '-1', 100x100 '-0', and 50x50 '-2S'). I found some information on the saveas http://forums.adobe.com/message/2652204 but have no experience with javascript. I have some understanding of VBA and believe a loop could be used but haven't the slightest idea how to set this up. Is there anyone out there that could help walk me through this and lend me a hand?
    ---Below contains the 'Fit Image.jsx' file that I found---
    // c2008 Adobe Systems, Inc. All rights reserved.
    // Written by Ed Rose
    // based on the ADM Fit Image by Charles A. McBrian from 1997
    // edited by Mike Hale added option to avoid resize on images already smaller than target size
    @@@BUILDINFO@@@ Fit Image.jsx 1.0.0.21
    /* Special properties for a JavaScript to enable it to behave like an automation plug-in, the variable name must be exactly
       as the following example and the variables must be defined in the top 1000 characters of the file
    // BEGIN__HARVEST_EXCEPTION_ZSTRING
    <javascriptresource>
    <name>$$$/JavaScripts/FitImage/Name=Fit Image...</name>
    <menu>automate</menu>
    <enableinfo>true</enableinfo>
    <eventid>3caa3434-cb67-11d1-bc43-0060b0a13dc4</eventid>
    <terminology><![CDATA[<< /Version 1
                             /Events <<
                              /3caa3434-cb67-11d1-bc43-0060b0a13dc4 [($$$/AdobePlugin/FitImage/Name=Fit Image) /imageReference <<
                               /width [($$$/AdobePlugin/FitImage/Width=width) /pixelsUnit]
                               /height [($$$/AdobePlugin/FitImage/Height=height) /pixelsUnit]
                               /limit [($$$/AdobePlugin/FitImage/limit=Don't Enlarge) /boolean]
                              >>]
                             >>
                          >> ]]></terminology>
    </javascriptresource>
    // END__HARVEST_EXCEPTION_ZSTRING
    // enable double clicking from the Macintosh Finder or the Windows Explorer
    #target photoshop
    // debug level: 0-2 (0:disable, 1:break on error, 2:break at beginning)
    // $.level = 2;
    // debugger; // launch debugger on next line
    // on localized builds we pull the $$$/Strings from a .dat file, see documentation for more details
    $.localize = true;
    var isCancelled = true; // assume cancelled until actual resize occurs
    // the main routine
    // the FitImage object does most of the work
    try {
        // create our default params
        var sizeInfo = new SizeInfo();
        GlobalVariables();
        CheckVersion();
        var gIP = new FitImage();
        if ( DialogModes.ALL == app.playbackDisplayDialogs ) {
            gIP.CreateDialog();
            gIP.RunDialog();
        else {
            gIP.InitVariables();
            ResizeTheImage(sizeInfo.width.value, sizeInfo.height.value);
        if (!isCancelled) {
            SaveOffParameters(sizeInfo);
    // Lot's of things can go wrong
    // Give a generic alert and see if they want the details
    catch( e ) {
        if ( DialogModes.NO != app.playbackDisplayDialogs ) {
            alert( e + " : " + e.line );
    // restore the dialog modes
    app.displayDialogs = gSaveDialogMode;
    isCancelled ? 'cancel' : undefined;
    function ResizeTheImage(width, height) {
        var oldPref = app.preferences.rulerUnits;
        var docWidth;
        var docHeight;
        var docRatio;
        var newWidth;
        var newHeight;
        var resolution = app.activeDocument.resolution;
        var limit = sizeInfo.limit;
        app.preferences.rulerUnits = Units.PIXELS; // save old preferences
        // original width, height
        docWidth = (1.0 * app.activeDocument.width * resolution) / 72.0; // decimal inches assuming 72 dpi (used in docRatio)
        docHeight = (1.0 * app.activeDocument.height * resolution) / 72.0; // ditto
        if (docWidth < 1.0 || docHeight < 1.0)
            return true; // error
        if (width < 1 || height < 1)
            return true; // error
        if ( limit && ( docWidth <= width && docHeight <= height ) ){
            app.preferences.rulerUnits = oldPref; // restore old prefs
            isCancelled = false; // if get here, definitely executed
            return false; // no error
        docRatio = docWidth / docHeight; // decimal ratio of original width/height
        newWidth = width;
        newHeight = ((1.0 * width) / docRatio); // decimal calc
        if (newHeight > height) {
            newWidth = docRatio * height; // decimal calc
            newHeight = height;
        // resize the image using a good conversion method while keeping the pixel resolution
        // and the aspect ratio the same
        app.activeDocument.resizeImage(newWidth, newHeight, resolution, ResampleMethod.BICUBIC);
        app.preferences.rulerUnits = oldPref; // restore old prefs
        isCancelled = false; // if get here, definitely executed
        return false; // no error
    // created in
    function SaveOffParameters(sizeInfo) {
        // save off our last run parameters
        var d = objectToDescriptor(sizeInfo, strMessage);
        app.putCustomOptions("3caa3434-cb67-11d1-bc43-0060b0a13dc4", d);
        app.playbackDisplayDialogs = DialogModes.ALL;
        // save off another copy so Photoshop can track them corectly
        var dd = objectToDescriptor(sizeInfo, strMessage);
        app.playbackParameters = dd;
    function GlobalVariables() {
        // a version for possible expansion issues
        gVersion = 1.1;
        gMaxResize = 300000;
        // remember the dialog modes
        gSaveDialogMode = app.displayDialogs;
        app.displayDialogs = DialogModes.NO;
        gInAlert = false;
        // all the strings that need to be localized
        strTitle = localize( "$$$/JavaScript/FitImage/Title=Fit Image" );
        strConstrainWithin = localize( "$$$/JavaScript/FitImage/ConstrainWithin=Constrain Within" );
        strTextWidth = localize("$$$/JavaScripts/FitImage/Width=&Width:");
        strTextHeight = localize("$$$/JavaScripts/FitImage/Height=&Height:");
        strTextPixels = localize("$$$/JavaScripts/FitImage/Pixels=pixels");
        strButtonOK = localize("$$$/JavaScripts/FitImage/OK=OK");
        strButtonCancel = localize("$$$/JavaScripts/FitImage/Cancel=Cancel");
        strTextSorry = localize("$$$/JavaScripts/FitImage/Sorry=Sorry, Dialog failed");
        strTextInvalidType = localize("$$$/JavaScripts/FitImage/InvalidType=Invalid numeric value");
        strTextInvalidNum = localize("$$$/JavaScripts/FitImage/InvalidNum=A number between 1 and 300000 is required. Closest value inserted.");
        strTextNeedFile = localize("$$$/JavaScripts/FitImage/NeedFile=You must have a file selected before using Fit Image");
        strMessage = localize("$$$/JavaScripts/FitImage/Message=Fit Image action settings");
        strMustUse = localize( "$$$/JavaScripts/ImageProcessor/MustUse=You must use Photoshop CS 2 or later to run this script!" );
        strLimitResize = localize("$$$/JavaScripts/FitImage/Limit=Don^}t Enlarge");
    // the main class
    function FitImage() {
        this.CreateDialog = function() {
            // I will keep most of the important dialog items at the same level
            // and use auto layout
            // use overriding group so OK/Cancel buttons placed to right of panel
            var res =
                "dialog { \
                    pAndB: Group { orientation: 'row', \
                        info: Panel { orientation: 'column', borderStyle: 'sunken', \
                            text: '" + strConstrainWithin +"', \
                            w: Group { orientation: 'row', alignment: 'right',\
                                s: StaticText { text:'" + strTextWidth +"' }, \
                                e: EditText { preferredSize: [70, 20] }, \
                                p: StaticText { text:'" + strTextPixels + "'} \
                            h: Group { orientation: 'row', alignment: 'right', \
                                s: StaticText { text:'" + strTextHeight + "' }, \
                                e: EditText { preferredSize: [70, 20] }, \
                                p: StaticText { text:'" + strTextPixels + "'} \
                            l: Group { orientation: 'row', alignment: 'left', \
                                    c:Checkbox { text: '" + strLimitResize + "', value: false }, \
                        buttons: Group { orientation: 'column', alignment: 'top',  \
                            okBtn: Button { text:'" + strButtonOK +"', properties:{name:'ok'} }, \
                            cancelBtn: Button { text:'" + strButtonCancel + "', properties:{name:'cancel'} } \
            // the following, when placed after e: in w and h doesn't show up
            // this seems to be OK since px is put inside the dialog box
            //p: StaticText { text:'" + strTextPixels + "'}
            // create the main dialog window, this holds all our data
            this.dlgMain = new Window(res,strTitle);
            // create a shortcut for easier typing
            var d = this.dlgMain;
            // match our dialog background color to the host application
            d.graphics.backgroundColor = d.graphics.newBrush (d.graphics.BrushType.THEME_COLOR, "appDialogBackground");
            d.defaultElement = d.pAndB.buttons.okBtn;
            d.cancelElement = d.pAndB.buttons.cancelBtn;
        } // end of CreateDialog
        // initialize variables of dialog
        this.InitVariables = function() {
            var oldPref = app.preferences.rulerUnits;
            app.preferences.rulerUnits = Units.PIXELS;
            // look for last used params via Photoshop registry, getCustomOptions will throw if none exist
            try {
                var desc = app.getCustomOptions("3caa3434-cb67-11d1-bc43-0060b0a13dc4");
                descriptorToObject(sizeInfo, desc, strMessage);
            catch(e) {
                // it's ok if we don't have any options, continue with defaults
            // see if I am getting descriptor parameters
            var fromAction = !!app.playbackParameters.count;
            if( fromAction ){
                // reset sizeInfo to defaults
                SizeInfo = new SizeInfo();
                // set the playback options to sizeInfo
                descriptorToObject(sizeInfo, app.playbackParameters, strMessage);
            // make sure got parameters before this
            if (app.documents.length <= 0) // count of documents viewed
                if ( DialogModes.NO != app.playbackDisplayDialogs ) {
                    alert(strTextNeedFile); // only put up dialog if permitted
                app.preferences.rulerUnits = oldPref;
                return false; // if no docs, always return
            var w = app.activeDocument.width;
            var h = app.activeDocument.height;
            var l = true;
            if (sizeInfo.width.value == 0) {
                sizeInfo.width = w;
            else {
                w = sizeInfo.width;
            if (sizeInfo.height.value == 0) {
                sizeInfo.height = h;
            else {
                h = sizeInfo.height;
            app.preferences.rulerUnits = oldPref;
            if ( DialogModes.ALL == app.playbackDisplayDialogs ) {
                var d = this.dlgMain;
                d.ip = this;
                d.pAndB.info.w.e.text = Number(w);
                d.pAndB.info.h.e.text = Number(h);
                d.pAndB.info.l.c.value = sizeInfo.limit;
            return true;
        // routine for running the dialog and it's interactions
        this.RunDialog = function () {
            var d = this.dlgMain;
            // in case hit cancel button, don't close
            d.pAndB.buttons.cancelBtn.onClick = function() {
                var dToCancel = FindDialog( this );
                dToCancel.close( false );
            // nothing for now
            d.onShow = function() {
            // do not allow anything except for numbers 0-9
            d.pAndB.info.w.e.addEventListener ('keydown', NumericEditKeyboardHandler);
            // do not allow anything except for numbers 0-9
            d.pAndB.info.h.e.addEventListener ('keydown', NumericEditKeyboardHandler);
            // hit OK, do resize
            d.pAndB.buttons.okBtn.onClick = function () {
                if (gInAlert == true) {
                    gInAlert = false;
                    return;
                var wText = d.pAndB.info.w.e.text;
                var hText = d.pAndB.info.h.e.text;
                var lValue = d.pAndB.info.l.c.value;
                var w = Number(wText);
                var h = Number(hText);
                sizeInfo.limit = Boolean(lValue);
                var inputErr = false;
                if ( isNaN( w ) || isNaN( h ) ) {
                    if ( DialogModes.NO != app.playbackDisplayDialogs ) {
                        alert( strTextInvalidType );
                    if (isNaN( w )) {
                        sizeInfo.width = new UnitValue( 1, "px" );
                        d.pAndB.info.w.e.text = 1;
                    } else {
                        sizeInfo.height = new UnitValue( 1, "px" );
                        d.pAndB.info.h.e.text = 1;
                        return false;
                else if (w < 1 || w > gMaxResize || h < 1 || h > gMaxResize) {
                    if ( DialogModes.NO != app.playbackDisplayDialogs ) {
                        gInAlert = true;
                        alert( strTextInvalidNum );
                if ( w < 1) {
                    inputErr = true;
                    sizeInfo.width = new UnitValue( 1, "px" );
                    d.pAndB.info.w.e.text = 1;
                if ( w > gMaxResize) {
                    inputErr = true;
                    sizeInfo.width = new UnitValue( gMaxResize, "px" );
                    d.pAndB.info.w.e.text = gMaxResize;
                if ( h < 1) {
                    inputErr = true;
                    sizeInfo.height = new UnitValue( 1, "px" );
                    d.pAndB.info.h.e.text = 1;
                if ( h > gMaxResize) {
                    inputErr = true;
                    sizeInfo.height = new UnitValue( gMaxResize, "px" );
                    d.pAndB.info.h.e.text = gMaxResize;
                if (inputErr == false)  {
                    sizeInfo.width = new UnitValue( w, "px" );
                    sizeInfo.height = new UnitValue( h, "px" );
                    if (ResizeTheImage(w, h)) { // the whole point
                        // error, input or output size too small
                    d.close(true);
                return;
            if (!this.InitVariables())
                return true; // handled it
            // give the hosting app the focus before showing the dialog
            app.bringToFront();
            this.dlgMain.center();
            return d.show();
    function CheckVersion() {
        var numberArray = version.split(".");
        if ( numberArray[0] < 9 ) {
            if ( DialogModes.NO != app.playbackDisplayDialogs ) {
                alert( strMustUse );
            throw( strMustUse );
    function FindDialog( inItem ) {
        var w = inItem;
        while ( 'dialog' != w.type ) {
            if ( undefined == w.parent ) {
                w = null;
                break;
            w = w.parent;
        return w;
    // Function: objectToDescriptor
    // Usage: create an ActionDescriptor from a JavaScript Object
    // Input: JavaScript Object (o)
    //        object unique string (s)
    //        Pre process converter (f)
    // Return: ActionDescriptor
    // NOTE: Only boolean, string, number and UnitValue are supported, use a pre processor
    //       to convert (f) other types to one of these forms.
    // REUSE: This routine is used in other scripts. Please update those if you
    //        modify. I am not using include or eval statements as I want these
    //        scripts self contained.
    function objectToDescriptor (o, s, f) {
        if (undefined != f) {
            o = f(o);
        var d = new ActionDescriptor;
        var l = o.reflect.properties.length;
        d.putString( app.charIDToTypeID( 'Msge' ), s );
        for (var i = 0; i < l; i++ ) {
            var k = o.reflect.properties[i].toString();
            if (k == "__proto__" || k == "__count__" || k == "__class__" || k == "reflect")
                continue;
            var v = o[ k ];
            k = app.stringIDToTypeID(k);
            switch ( typeof(v) ) {
                case "boolean":
                    d.putBoolean(k, v);
                    break;
                case "string":
                    d.putString(k, v);
                    break;
                case "number":
                    d.putDouble(k, v);
                    break;
                default:
                    if ( v instanceof UnitValue ) {
                        var uc = new Object;
                        uc["px"] = charIDToTypeID("#Pxl"); // pixelsUnit
                        uc["%"] = charIDToTypeID("#Prc"); // unitPercent
                        d.putUnitDouble(k, uc[v.type], v.value);
                    } else {
                        throw( new Error("Unsupported type in objectToDescriptor " + typeof(v) ) );
        return d;
    // Function: descriptorToObject
    // Usage: update a JavaScript Object from an ActionDescriptor
    // Input: JavaScript Object (o), current object to update (output)
    //        Photoshop ActionDescriptor (d), descriptor to pull new params for object from
    //        object unique string (s)
    //        JavaScript Function (f), post process converter utility to convert
    // Return: Nothing, update is applied to passed in JavaScript Object (o)
    // NOTE: Only boolean, string, number and UnitValue are supported, use a post processor
    //       to convert (f) other types to one of these forms.
    // REUSE: This routine is used in other scripts. Please update those if you
    //        modify. I am not using include or eval statements as I want these
    //        scripts self contained.
    function descriptorToObject (o, d, s, f) {
        var l = d.count;
        if (l) {
            var keyMessage = app.charIDToTypeID( 'Msge' );
            if ( d.hasKey(keyMessage) && ( s != d.getString(keyMessage) )) return;
        for (var i = 0; i < l; i++ ) {
            var k = d.getKey(i); // i + 1 ?
            var t = d.getType(k);
            strk = app.typeIDToStringID(k);
            switch (t) {
                case DescValueType.BOOLEANTYPE:
                    o[strk] = d.getBoolean(k);
                    break;
                case DescValueType.STRINGTYPE:
                    o[strk] = d.getString(k);
                    break;
                case DescValueType.DOUBLETYPE:
                    o[strk] = d.getDouble(k);
                    break;
                case DescValueType.UNITDOUBLE:
                    var uc = new Object;
                    uc[charIDToTypeID("#Rlt")] = "px"; // unitDistance
                    uc[charIDToTypeID("#Prc")] = "%"; // unitPercent
                    uc[charIDToTypeID("#Pxl")] = "px"; // unitPixels
                    var ut = d.getUnitDoubleType(k);
                    var uv = d.getUnitDoubleValue(k);
                    o[strk] = new UnitValue( uv, uc[ut] );
                    break;
                case DescValueType.INTEGERTYPE:
                case DescValueType.ALIASTYPE:
                case DescValueType.CLASSTYPE:
                case DescValueType.ENUMERATEDTYPE:
                case DescValueType.LISTTYPE:
                case DescValueType.OBJECTTYPE:
                case DescValueType.RAWTYPE:
                case DescValueType.REFERENCETYPE:
                default:
                    throw( new Error("Unsupported type in descriptorToObject " + t ) );
        if (undefined != f) {
            o = f(o);
    // Function: SizeInfo
    // Usage: object for holding the dialog parameters
    // Input: <none>
    // Return: object holding the size info
    function SizeInfo() {
        this.height = new UnitValue( 0, "px" );
        this.width = new UnitValue( 0, "px" );
        this.limit = false;
    // Function: NumericEditKeyboardHandler
    // Usage: Do not allow anything except for numbers 0-9
    // Input: ScriptUI keydown event
    // Return: <nothing> key is rejected and beep is sounded if invalid
    function NumericEditKeyboardHandler (event) {
        try {
            var keyIsOK = KeyIsNumeric (event) ||
                          KeyIsDelete (event) ||
                          KeyIsLRArrow (event) ||
                          KeyIsTabEnterEscape (event);
            if (! keyIsOK) {
                //    Bad input: tell ScriptUI not to accept the keydown event
                event.preventDefault();
                /*    Notify user of invalid input: make sure NOT
                       to put up an alert dialog or do anything which
                             requires user interaction, because that
                             interferes with preventing the 'default'
                             action for the keydown event */
                app.beep();
        catch (e) {
            ; // alert ("Ack! bug in NumericEditKeyboardHandler: " + e);
    //    key identifier functions
    function KeyHasModifier (event) {
        return event.shiftKey || event.ctrlKey || event.altKey || event.metaKey;
    function KeyIsNumeric (event) {
        return  (event.keyName >= '0') && (event.keyName <= '9') && ! KeyHasModifier (event);
    function KeyIsDelete (event) {
        //    Shift-delete is ok
        return ((event.keyName == 'Backspace') || (event.keyName == 'Delete')) && ! (event.ctrlKey);
    function KeyIsLRArrow (event) {
        return ((event.keyName == 'Left') || (event.keyName == 'Right')) && ! (event.altKey || event.metaKey);
    function KeyIsTabEnterEscape (event) {
        return event.keyName == 'Tab' || event.keyName == 'Enter' || event.keyName == 'Escape';
    // End Fit Image.jsx

    With Photoshop CS5 you can use Image Processor Pro and this should do what you require...
    http://blogs.adobe.com/jnack/2011/05/new-image-processor-pro-script-for-cs5.html

Maybe you are looking for