<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Running Photo Viewer from lisp in Visual LISP, AutoLISP and General Customization Forum</title>
    <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694955#M140574</link>
    <description>&lt;P&gt;Henrique,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;OK, I will have another play.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;</description>
    <pubDate>Fri, 26 Jun 2015 13:29:59 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-06-26T13:29:59Z</dc:date>
    <item>
      <title>Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5692875#M140568</link>
      <description>&lt;P&gt;I have a lisp routine which enables me to pick a text entity on a drawing upon which the routine then finds a corresponding record, which is either a pdf or tiff file, then opens the file in an appropriate programme. The actual purpose is to open manhole card iinformation when I click on a manhole number within a sewer network.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This used to work fine with pdf's opening in Adobe Reader and tiffs opening in MS &amp;nbsp;Picture Manager but since installing Office 2013 Picture Manager is no more. I am trying to open the tiffs in Photo Viewer but I realise this is run using rundll. I have copied a section of the routine below where you can see the pdf example line (which works OK) but I am struggling with the tiff line. I cant get this bit to run.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help would be greatly appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;mh_path and mh_path1 are the text entities returned from picking on a text item in ACAD.)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;;;;;;;__________sub to look for pdf and displays file_________________________________&lt;BR /&gt;(defun do_pdf ()&lt;BR /&gt;(findfile mh_path1) (startapp "C:\\Program Files\\Adobe\\Reader 11.0\\Reader\\AcroRd32.exe" mh_path1)&lt;BR /&gt;);defun do_pdf&lt;/P&gt;&lt;P&gt;;______sub to look for tif and displays file__________________________________&lt;BR /&gt;(defun do_tif ()&lt;BR /&gt;(findfile mh_path)(startapp "C:\\Windows\\System32\\rundll32.exe C:\\ProgramFiles\\Windows Photo Viewer\\PhotoViewer.dll", ImageView_Fullscreen mh_path)&lt;BR /&gt;);defun do_tif&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2015 10:23:23 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5692875#M140568</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-25T10:23:23Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694173#M140569</link>
      <description>&lt;P&gt;This solution seems to work directly from the Run command in Windows.&amp;nbsp; You'll have to test it to see if it works from Lisp:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A target="_blank" href="http://stackoverflow.com/questions/6190271/how-to-run-photoviewer-dll-in-command-line"&gt;http://stackoverflow.com/questions/6190271/how-to-run-photoviewer-dll-in-command-line&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="MsoNormal"&gt;&lt;A target="_blank" href="http://apps.exchange.autodesk.com/ACD/en/Detail/Index?id=appstore.exchange.autodesk.com%3aareaobjectlink_windows32and64%3aen"&gt;Area Object Link&lt;/A&gt; | &lt;A target="_blank" href="https://apps.exchange.autodesk.com/ACD/en/Detail/Index?id=appstore.exchange.autodesk.com%3addattmod_windows32and64%3aen"&gt;Attribute Modifier&lt;/A&gt; | &lt;A target="_blank" href="http://apps.exchange.autodesk.com/ACD/en/Detail/Index?id=appstore.exchange.autodesk.com%3addsetup_windows32and64%3aen"&gt;Dwg Setup&lt;/A&gt; | &lt;A target="_blank" href="https://apps.exchange.autodesk.com/ACD/en/Detail/Index?id=appstore.exchange.autodesk.com%3addcalc_windows32and64%3aen"&gt;Feet-Inch Calculator&lt;/A&gt;&lt;SPAN style="font-family: Arial,sans-serif; text-shadow: auto;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;A target="_blank" href="https://apps.exchange.autodesk.com/ACD/en/Detail/Index?id=appstore.exchange.autodesk.com%3alayerapps_windows32and64%3aen"&gt;Layer Apps&lt;/A&gt; | &lt;A target="_blank" href="https://apps.exchange.autodesk.com/ACD/en/Detail/Index?id=appstore.exchange.autodesk.com%3addlist_windows32and64%3aen"&gt;List on Steroids&lt;/A&gt; | &lt;A target="_blank" href="https://apps.exchange.autodesk.com/ACD/en/Detail/Index?id=appstore.exchange.autodesk.com%3addzmscl_windows32and64%3aen"&gt;VP Zoom Scales&lt;/A&gt; |&lt;A target="_blank" href="https://apps.exchange.autodesk.com/ACD/en/Home/Index"&gt;Exchange App Store&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jun 2015 21:31:12 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694173#M140569</guid>
      <dc:creator>paullimapa</dc:creator>
      <dc:date>2015-06-25T21:31:12Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694559#M140570</link>
      <description>&lt;P&gt;Hi Paul,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your reply and the link.&lt;/P&gt;&lt;P&gt;The solution does indeed run successfully from the command line so I modified the code to :-&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;;______sub to look for tif and displays file__________________________________&lt;BR /&gt;(defun do_tif ()&lt;BR /&gt;(findfile mh_path) (startapp "rundll32 "%ProgramFiles%\\Windows Photo Viewer\\PhotoViewer.dll", ImageView_Fullscreen" mh_path)&lt;BR /&gt;);defun do_tif&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;but unfortunately it does not work. I will continue to have a play sometinme but frankly I don't know what else to try unless there are shell commands available within lisp, but then I think I&amp;nbsp;may be getting out of my depth.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 07:26:53 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694559#M140570</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T07:26:53Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694615#M140571</link>
      <description>&lt;P&gt;Hi Peter,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If the Photo Viewer is the default program to open .tif files, perhaps something like this will do the trick&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;;; usage
;; (do_tif "g:\\test\\test123.tif")
(defun do_tif (path)
  (if (setq file (findfile path))
    (command "_.start" file)
    (princ (strcat "\n \"" path "\" was not found..."))
  )
  (princ)
)&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps, &lt;BR /&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 09:35:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694615#M140571</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2015-06-26T09:35:59Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694870#M140572</link>
      <description>&lt;P&gt;Hi Henrique,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have posted the routine in its entirity below so you can see the lines I am having trouble with in context. I think I have incorporated your suggestion as intended. When I run it and click on a manhole number it opens a windows command line above CAD with a title showing the manhole card number :-&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;IMG title="Capture.JPG" alt="Capture.JPG" src="https://forums.autodesk.com/t5/image/serverpage/image-id/175609iB5FB5C9B39FA80D5/image-size/original?v=mpbl-1&amp;amp;px=-1" border="0" /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;;to pick a manhole tag and have Autocad return existence of card 

(defun c:mhcard ()
(setq pdf_exists nil)
(setq tif_exists nil)  
  
(setq ed (entget (car (entsel))))
(setq ent1 (assoc 1 ed))
(setq mh_1 (cdr ent1))	;;the text value of the entity
(setq 	ent10 (assoc 10 ed )				;; insertion point list of the entity
	mh_10 (cdr ent10   )				;; insertion point
	mh_x  (substr (rtos (car mh_10  ))  2 2 )	;; the x value
	mh_y  (substr (rtos (cadr mh_10 ))  2 2 )	;; the y value
	mh_gr (strcat "SC" mh_x mh_y)			;; the 1k grid number
	mh_no (strcat mh_gr "-" mh_1) ;;manhole number	;; the manhole number
	mh_path (strcat "\"" "K:\\NE70000 Sewer Network Info\\Manhole_cards\\" mh_gr "\\" mh_no 

".tif" "\"");the spec for finding a .tif file
	mh_path1 (strcat "\"" "K:\\NE70000 Sewer Network Info\\Manhole_cards\\" mh_gr "\\" mh_no 

".pdf" "\"");the spec for finding a .pdf file
;;;note for above line: Startapp needs the file to open in quotes when a space is used in the 

path.
;;;So the backslash quote attaches a literal quote at the back and the front of the path
;;;note that this path is to be used for the startapp fuction. A new path variable is needed for 

other process that do
;;;not require the quotes.
;;;Delete this:	mh_path1 (strcat "K:\\NE70000 Sewer Network Info\\Manhole_cards\\" mh_gr "\\" 

mh_no ".tif")
)	
;;;;;;_______sub to look for pdf and displays file_________________________________
(defun do_pdf () 
(findfile mh_path1) (startapp "C:\\Program Files\\Adobe\\Reader 11.0\\Reader\\AcroRd32.exe" 

mh_path1)
);defun do_pdf

;;;;;;_______sub to look for tif and displays file__________________________________
(defun do_tif ()
  (findfile mh_path) (command "_.start" mh_path)
);defun do_tif

;_______________Sub for only pdf found___________________
(defun pdf_only ()
(do_pdf)
);defun pdf_only

;_______________Sub for only tif found___________________
(defun tif_only ()  
(do_tif)
);defun tif_only

;_______________Sub for no cards found_________________  
(defun no_cards ()
(setq no_card (strcat "There are no cards found for Manhole Number :   " mh_no)) 
(princ no_card)
(princ)  
);defun no_cards

;_______________Sub for both cards found_________________  
(defun both_cards ()
(do_pdf)
(setq both_cards (strcat " ......There is also a tif file found for Manhole Number : " mh_no)) 
(princ both_cards)
(setq a (getstring "  hit enter to display tif"))
(princ) 
(do_tif)  
);defun both_cards
  
;check for exstence of files
(if (findfile mh_path1)(setq pdf_exists T)) ;check if pdf file exists
(if (findfile mh_path)(setq tif_exists  T)) ;check if tif file exists
(if (and pdf_exists tif_exists) (both_cards)) ;if both exist do both_cards
(if (and pdf_exists (not tif_exists)) (pdf_only));if only pdf exists do pdf_only
(if (and (not pdf_exists) tif_exists) (tif_only));if only tif exists do tif only
(if (and (not pdf_exists) (not tif_exists)) (no_cards));if nether exists do no_cards

  
;;;;(getfiled "Open Image File" mh_path "tif" 0);this was to be an option to search the directory - superfluous. . ?
 
(princ)
);overall defun


&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 12:48:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694870#M140572</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T12:48:51Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694939#M140573</link>
      <description>&lt;P&gt;Peter,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;testing the&lt;/P&gt;
&lt;PRE&gt;;; usage
;; (do_tif "g:\\test\\test123.tif")
(defun do_tif (path)
  (if (setq file (findfile path))
    (command "_.start" file)
    (princ (strcat "\n \"" path "\" was not found..."))
  )
  (princ)
)&lt;/PRE&gt;
&lt;P&gt;with a valid .tif path, &lt;SPAN&gt;It works as expected?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Or don't open the &lt;SPAN class="hps"&gt;viewer?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class="hps"&gt;Sorry but I don't have AutoCAD in this laptop... &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class="hps"&gt;Henrique&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 13:19:48 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694939#M140573</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2015-06-26T13:19:48Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694955#M140574</link>
      <description>&lt;P&gt;Henrique,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;OK, I will have another play.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 13:29:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694955#M140574</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T13:29:59Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694967#M140575</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous wrote:&lt;BR /&gt;
&lt;P&gt;Henrique,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;OK, I will have another play.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Peter,&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="hps"&gt;you&lt;/SPAN&gt; &lt;SPAN class="hps"&gt;have not answered&lt;/SPAN&gt; &lt;SPAN class="hps"&gt;my questions&lt;/SPAN&gt;...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="hps"&gt;Only for &lt;/SPAN&gt;&lt;SPAN class="hps"&gt;testing purpose&lt;/SPAN&gt;, with a valid .tif path, &lt;SPAN class="hps"&gt;the code&lt;/SPAN&gt; &lt;SPAN class="hps alt-edited"&gt;I have posted&lt;/SPAN&gt;&amp;nbsp;&lt;SPAN&gt;works as expected, or not?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Opens the viewer or not?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Henrique&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class="hps"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 13:35:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694967#M140575</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2015-06-26T13:35:49Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694992#M140576</link>
      <description>&lt;P&gt;Sorry Henrique, I realised that I had not ansewerd your question as soon as I posted my last reply.&lt;/P&gt;&lt;P&gt;Just trying now...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am just getting&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;Command: do_tif
Unknown command "DO_TIF".  Press F1 for help.&lt;/PRE&gt;&lt;P&gt;I must be doing something wrong here.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 13:43:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5694992#M140576</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T13:43:11Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695003#M140577</link>
      <description>&lt;P&gt;...or did you intend for this to be posted into the original routine? If so, do_tif is already defined elsewhere.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 13:46:52 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695003#M140577</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T13:46:52Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695018#M140578</link>
      <description>&lt;P&gt;I am having a bad day... do_tif is NOT defined elsewhere.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 13:51:06 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695018#M140578</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T13:51:06Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695019#M140579</link>
      <description>&lt;P&gt;Peter&lt;/P&gt;
&lt;P&gt;change the mh_gr and mh_no to a valid ones, and test&lt;/P&gt;
&lt;P&gt;(if (setq file (findfile (strcat "\"" "K:\\NE70000 Sewer Network Info\\Manhole_cards\\" mh_gr "\\" mh_no ".tif" "\"")))&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; (command "_.start" file))&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 13:52:22 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695019#M140579</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2015-06-26T13:52:22Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695062#M140580</link>
      <description>&lt;P&gt;Henrique,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;;; usage
;; (do_tif "c:\\test\\test123.tif")
(defun do_tif (path)
  (if (setq file (findfile (strcat "\"" "K:\\NE70000 Sewer Network Info\\Manhole_cards\\SC3876\\SC3876-4508.tif" "\"")))
    (command "_.start" file))
  )
  (princ)
)&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Results with&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;Command: do_tif
; error: too few arguments&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 14:09:12 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695062#M140580</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T14:09:12Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695082#M140581</link>
      <description>&lt;P&gt;Peter,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;just copy/paste this code in the command line, and press enter&lt;/P&gt;
&lt;PRE&gt;(if (setq file (findfile (strcat "\"" "K:\\NE70000 Sewer Network Info\\Manhole_cards\\SC3876\\SC3876-4508.tif" "\"")))(command "_.start" file))&lt;/PRE&gt;
&lt;P&gt;Did work?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 14:14:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695082#M140581</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2015-06-26T14:14:38Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695144#M140582</link>
      <description>&lt;P&gt;Henrique,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Pasting the code in gives :-&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;IMG title="Capture2.JPG" alt="Capture2.JPG" src="https://forums.autodesk.com/t5/image/serverpage/image-id/175646iC16775E5FC818410/image-size/original?v=mpbl-1&amp;amp;px=-1" border="0" /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 14:40:11 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695144#M140582</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-26T14:40:11Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695180#M140583</link>
      <description>&lt;P&gt;And with&lt;/P&gt;
&lt;PRE&gt;(if (findfile (strcat "\"" "K:\\NE70000 Sewer Network Info\\Manhole_cards\\SC3876\\SC3876-4508.tif" "\""))
  (command "_.start" (strcat "\"" "K:\\NE70000 Sewer Network Info\\Manhole_cards\\SC3876\\SC3876-4508.tif" "\"")))&lt;/PRE&gt;
&lt;P&gt;Open the viewer?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Fri, 26 Jun 2015 15:01:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5695180#M140583</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2015-06-26T15:01:47Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5697228#M140584</link>
      <description>&lt;P&gt;Unfortunately no. I get a 'nil' reponse at the command line.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I thought your last suggestion had a good chance of working.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jun 2015 07:24:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5697228#M140584</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-29T07:24:25Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5697322#M140585</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;@Anonymous wrote:&lt;BR /&gt;
&lt;P&gt;Unfortunately no. I get a 'nil' reponse at the command line.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I thought your last suggestion had a good chance of working.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Peter,&lt;/P&gt;
&lt;P&gt;the 'start' command, &lt;SPAN class="hps"&gt;does not deal&lt;/SPAN&gt; &lt;SPAN class="hps"&gt;well with&lt;/SPAN&gt; spaces in file name, if the file don't have spaces, i&lt;SPAN&gt;t works as expected...&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class="hps alt-edited"&gt;Something like this&lt;/SPAN&gt; &lt;SPAN class="hps"&gt;should work&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;(defun do_tif (file / sh)
 (cond ((setq f (findfile file))
        (setq sh (vlax-create-object "Shell.Application"))
        (vlax-invoke sh 'Open file)
        (vlax-release-object sh)
        )
       )
  )

;; usage
(do_tif "K:\\NE70000 Sewer Network Info\\Manhole_cards\\SC3876\\SC3876-4508.tif")&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class="hps"&gt;Hope this helps, &lt;BR /&gt;Henrique&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jun 2015 09:21:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5697322#M140585</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2015-06-29T09:21:08Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5697524#M140586</link>
      <description>&lt;P&gt;Hi Henrique,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes, that works exactly as it should. Thank you very much.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Al I have to do now is to put your code snippet back into the original lisp routine.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks again,&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jun 2015 12:25:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5697524#M140586</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-06-29T12:25:36Z</dc:date>
    </item>
    <item>
      <title>Re: Running Photo Viewer from lisp</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5697577#M140587</link>
      <description>&lt;P&gt;You're welcome, Peter!&lt;BR /&gt;Glad I could help&lt;BR /&gt;&lt;BR /&gt;Henrique&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jun 2015 13:02:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/running-photo-viewer-from-lisp/m-p/5697577#M140587</guid>
      <dc:creator>hmsilva</dc:creator>
      <dc:date>2015-06-29T13:02:10Z</dc:date>
    </item>
  </channel>
</rss>

