{"id":5949,"date":"2013-04-18T13:51:00","date_gmt":"2013-04-18T21:51:00","guid":{"rendered":"http:\/\/www.sapien.com\/blog\/?p=5949"},"modified":"2013-04-18T13:53:17","modified_gmt":"2013-04-18T21:53:17","slug":"how-can-i-make-primalscript-execute-fill-in-script-language-here","status":"publish","type":"post","link":"https:\/\/dev.sapien.com\/blog\/2013\/04\/18\/how-can-i-make-primalscript-execute-fill-in-script-language-here\/","title":{"rendered":"How can I make PrimalScript execute &lt;fill in script language here&gt;?"},"content":{"rendered":"<p>One question keeps popping up in our support forums and inboxes: How can I make PrimalScript execute my AutoIt, HTML, PigLatin &lt;fill in any other script language here&gt; script?<\/p>\n<p>This is fairly simple as long as you know what the actual language engine is. We will use AutoIt and HTML as an example for this post.<\/p>\n<p>If you load one of the AutoIt examples and just press Ctrl+F5 to run the script you get an error message.<\/p>\n<p><a href=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/image.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-left-width: 0px; border-right-width: 0px; border-bottom-width: 0px; display: inline; border-top-width: 0px\" border=\"0\" alt=\"image\" src=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/image_thumb.png\" width=\"644\" height=\"472\"><\/a><\/p>\n<p>Since AutoIt, unlike Windows Script Host or PowerShell, changes the executable name of the engine for each major version, you\u2019ll have to go in and change the name accordingly. You do that at File \u2013 Options \u2013 Environment \u2013 Languages.<br \/>Select AutoIt3 from the list and edit the engine name to Autoit3.exe or Autoit3_x64.exe if you want to run your scripts in 64 bit mode.<\/p>\n<p>Now try and run it. Still won\u2019t work, right? We played a little trick on you to illustrate the need for a full path to a script engine versus just having to enter the executable name. If the folder where the engine resides is not in the PATH environment variable then you need to specify the fully qualified path to the executable here: C:\\Program Files (x86)\\AutoIt3\\Autoit3_x64.exe<\/p>\n<p>And there you go:<\/p>\n<p><a href=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/image1.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-left-width: 0px; border-right-width: 0px; border-bottom-width: 0px; display: inline; border-top-width: 0px\" border=\"0\" alt=\"image\" src=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/image_thumb1.png\" width=\"644\" height=\"472\"><\/a><\/p>\n<p>Simple enough. Now on to HTML. If you only want to preview your HTML files in one browser, e.g. Internet Explorer, that is pretty simple. Go to the same options page, select HTML and navigate to the iexplore folder.<\/p>\n<p><a href=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/SNAGHTMLfa4a352.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"SNAGHTMLfa4a352\" style=\"border-left-width: 0px; border-right-width: 0px; border-bottom-width: 0px; display: inline; border-top-width: 0px\" border=\"0\" alt=\"SNAGHTMLfa4a352\" src=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/SNAGHTMLfa4a352_thumb.png\" width=\"644\" height=\"406\"><\/a><\/p>\n<p>And there it is:<\/p>\n<p><a href=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/image2.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-left-width: 0px; border-right-width: 0px; border-bottom-width: 0px; display: inline; border-top-width: 0px\" border=\"0\" alt=\"image\" src=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/image_thumb2.png\" width=\"644\" height=\"375\"><\/a><\/p>\n<p>If you need to test your HTML pages with a variety of browsers, we suggest a different approach. Just use the Tools Browser to create a new group called \u201cBrowsers\u201d and add all your usual suspects.<\/p>\n<p><a href=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/SNAGHTMLfb00a8d.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"SNAGHTMLfb00a8d\" style=\"border-left-width: 0px; border-right-width: 0px; border-bottom-width: 0px; display: inline; border-top-width: 0px\" border=\"0\" alt=\"SNAGHTMLfb00a8d\" src=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/SNAGHTMLfb00a8d_thumb.png\" width=\"644\" height=\"243\"><\/a><\/p>\n<p>&nbsp;<\/p>\n<p>Now you can go and add your browsers to that group:<\/p>\n<p><a href=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/SNAGHTMLfc06b42.png\" target=\"_blank\"><img loading=\"lazy\" decoding=\"async\" title=\"SNAGHTMLfc06b42\" style=\"border-left-width: 0px; border-right-width: 0px; border-bottom-width: 0px; display: inline; border-top-width: 0px\" border=\"0\" alt=\"SNAGHTMLfc06b42\" src=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/SNAGHTMLfc06b42_thumb.png\" width=\"644\" height=\"243\"><\/a><\/p>\n<p>Make sure to enclose the $File$ parameter in quotes, otherwise you get an error if your pathname contains spaces.<\/p>\n<p>Now if you press each of these icons with your HTML file active it will show up in the corresponding browser.<\/p>\n<p><a href=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/image3.png\"><img loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"border-left-width: 0px; border-right-width: 0px; border-bottom-width: 0px; display: inline; border-top-width: 0px\" border=\"0\" alt=\"image\" src=\"http:\/\/www.sapien.com\/blog\/wp-content\/uploads\/2013\/04\/image_thumb3.png\" width=\"644\" height=\"471\"><\/a><\/p>\n<p>This blog article and screenshots apply to PrimalScript 2012 6.5.143<\/p>\n","protected":false},"excerpt":{"rendered":"<p>One question keeps popping up in our support forums and inboxes: How can I make PrimalScript execute my AutoIt, HTML, PigLatin &lt;fill in any other script language here&gt; script? This is fairly simple as long as you know what the actual language engine is. We will use AutoIt and HTML as an example for this [&hellip;]<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[27,410,21],"tags":[823,681,820,821,1000,361,37,822],"class_list":["post-5949","post","type-post","status-publish","format-standard","hentry","category-ask-the-experts","category-primalscript-software-news","category-software-news","tag-autoit","tag-browser","tag-chrome","tag-firefox","tag-howto","tag-internet-explorer","tag-primalscript","tag-safari"],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/5949","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/comments?post=5949"}],"version-history":[{"count":2,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/5949\/revisions"}],"predecessor-version":[{"id":5959,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/posts\/5949\/revisions\/5959"}],"wp:attachment":[{"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/media?parent=5949"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/categories?post=5949"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dev.sapien.com\/blog\/wp-json\/wp\/v2\/tags?post=5949"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}