Graphics Viewer

I'm looking for a free graphics viewer with a command line option that will open up the first graphic file in a directory eg

viewer   c:\me\dropbox

and the first graphic appears on the screen and the user then has buttons such as Next and Previous to advance through the directory.

Now there's a large number of free viewers out there that offer this functionality except the ability to specify the directory concerned on the command line.  You have to use the viewer's File menu to find the directory and that I don't want.  I have a user for whom the File menu is too confusing, I just want the user to click on the icon and the specified directory appears for them (batch file hiding under the icon does the work).
LVL 50
dbruntonAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Joe Winograd, Fellow&MVEDeveloperCommented:
IrfanView is excellent (free!) imaging software that I've been using for many years:
http://www.irfanview.com/

I recommend the Brothersoft link to download IrfanView:
http://www.brothersoft.com/download-irfanview-6224.html

This will download a single install file called <iview438_setup.exe> with no adware and no junk!

And the Brothersoft link for the PlugIns, which are required for PDF support:
http://www.brothersoft.com/download-irfanview-all-plugins-164981.html

This will download a single install file called <irfanview_plugins_438_setup.exe> with no adware and no junk!

Install IrfanView first, then install the PlugIns. Although I recommend adding the PlugIns to get PDF support, that's for general, future usage. For this situation, you don't need it.

IrfanView has a command line interface. The syntax for it is in a file called <i_options.txt> in the installation directory, which I have attached to this post for the latest release (4.38). But the quick solution for you is that it does exactly what you want — here's the command line:

i_view32.exe c:\me\dropbox

That will open up the first file in the directory and the Left/Right arrow buttons or the PgUp/PgDn buttons will advance through the directory. Of course, you should qualify the install directory in the icon/shortcut you make for the user, something like:

c:\Program Files (x86)\IrfanView\i_view32.exe c:\me\dropbox

or

c:\Program Files\IrfanView\i_view32.exe c:\me\dropbox

Regards, Joe
IrfanView-4.38-i-options.txt
0
dbruntonAuthor Commented:
Thanks Joe.

Ignore the swearing which might occur in the next few words.

I tried that on a Windows 7 machine, yesterday, with no joy, hence my posting here.  I'll be going back to that Windows 7 machine in a couple of days and try again.  Unsure what went wrong.  Irfan is my favourite graphics viewer.

Just tested on my XP box and it works OK.  **@!**&^%((*
0
Joe Winograd, Fellow&MVEDeveloperCommented:
Works perfectly here in W7/64-bit — I just tested it to be absolutely certain. If you're using an old version, give the new one a try (4.38). It's a very recent release — 23-June.
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

BillDLCommented:
Now now, db, I've never seen you swearing before.

Try it with as many permutations as you can, for example:

1. Full path to i_view32.exe enclosed in double quotes.
2. Full path of target folder enclosed in double quotes.
3. Path to exe AND target folder enclosed in double quotes.
4. Use Environment Variable %ProgramFiles% instead of C:\Program Files.
5. Path to target folder with and without a trailing backslash.

Normally on a modern OS you shouldn't need to double-quote paths with spaces between the folder or file names, but IrfanView can be quirky when run from the command line.

Just for your info, what I have done in the past with IrfanView when I run it from the command line is to create custom "i_view32.ini" configuration files in suitably named sub-folders that suit how I want it to behave for particular uses, and I specify the path to one of those custom INI files within the command, eg:
i_view32.exe "c:\image_folder_path" /ini="C:\Program Files\IrfanView\FullScreen\"

To configure a new INI file I just temporarily rename the existing INI file as a backup, open IrfanView and set all the options I want, then close it to update the INI file.  That is my custom one which I move to the sub-folder and I rename the backup back to i_view32.ini again.

If you want a new Right-Click option for folders that allows you to open the affected folder to the first image in full-screen view, then that is pretty easy to achieve with a simple registry addition.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Joe Winograd, Fellow&MVEDeveloperCommented:
To follow-up on Bill's excellent point, keep in mind that on XP, the default is to store the actual <i_view32.ini> in the install directory (probably <c:\Program Files\IrfanView>). By "actual", I mean it contains all of the configuration settings (sections like [Language], [MRUD], [Resize], etc.). On W7, there is an <i_view32.ini> file in the install directory (probably <c:\Program Files\IrfanView> or <c:\Program Files\IrfanView (x86)>), but it doesn't contain the configuration settings — the default behavior is simply to have an [Others] section with a pointer to the real location of the config file, such as:

INI_Folder=%APPDATA%\IrfanView

That's where you'll find the actual <i_view32.ini> file. Regards, Joe
0
dbruntonAuthor Commented:
So I tried again and it worked.

"Path to Irfanview"  "Path to folder"

and yet I am sure I tried that on the weekend without joy.  All I got then was a black blank screen but today it  **@!**&^%((*  worked.  

Either I typed something wrong or not enough coffee or too much coffee or I didn't sacrifice a white rooster at midnight outside Microsoft's HQ.

Much appreciation to both of you.
0
Joe Winograd, Fellow&MVEDeveloperCommented:
Probably due to the recent super moon.
0
BillDLCommented:
Thank you DB.

Speaking of full moons, there was an older "village idiot" kind of guy who lived a couple of streets along from me when I was a kid.  There was a pond at the end of his street in a wooded area.  He had warts all over his hands and elbows and his mother had tried all the usual topical meds without success.  There was a full moon coming up that had some kind of significance, hence me knowing about it when ordinarily I wouldn't have bothered about yet another moon phase.  A friend and I bumped into him the day before the full moon and he started moaning about the warts.  We made up a crazy on the spot hocus-pocus suggestion for the treatment of warts while stifling the sniggering.  We told him that if he went out next to water (for example a river or lake) on the eve of the full moon between three hours after sunset and midnight, while the moon was visible, stripped naked and rubbed half a sprouting potato on the affected area, the warts would disappear.

Of course we followed him on the night in question and laughed our heads off at his antics next to the pond, but he had the last laugh when his warts did disappear within a few weeks.  Coincidence or something to do with the poisonous glycoalkaloid Solanine?  Who knows, but I can recommend this as a viable alternative medicine if you are willing to suffer ridicule when you find yourself on YouTube chanting incantations at the water's edge and rubbing tuberous vegetables into your naked body.
0
Joe Winograd, Fellow&MVEDeveloperCommented:
Hey, Bill, thanks for the laugh — great story!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Photos / Graphics Software

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.