Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Unable to create temporary image error

Engaged ,
Feb 05, 2013 Feb 05, 2013

Hi there, I recently started embedding images in my scripts...

Today for some reason, AFX doesn't like loading any scripts with embedded graphics...

"Unable to load temporary image file" is the message I am getting.

and the script crashes...  restarted, AFX, ESTK and pc ... same deal.

Any idea what is causing the conflict....?

Thanks

Alan.

TOPICS
Scripting
8.1K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Nov 15, 2013 Nov 15, 2013

Thanks Alan. A couple more questions: is the user instructed to place that folder inside the ScriptUI folder? Do you have a unique folder name for each of your scripts?

Thanks again for your time and help!

--Arie

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Nov 16, 2013 Nov 16, 2013

hey there, I just use a pre launch function before script does anything - useful for filtering AE versions and checking  the scripting security preference.

So below I am checking for the folder and the first icon, that should be good enough that the user hasn't deleted everything and we are good to launch.

Usually I have the folder corresponding to the script name.

//Check folder present.

    var thisFile = File($.fileName); //this file as an obj.

    var thisFileFolder = Folder(thisFile.parent); // parent folder object.

    var strFolder = Folder(thisFileFolder.fsName + "/AED_CornerCutters/Icons").toString();

    var testFile = new File(strFolder + "/AED_TidyUp.png");

    if (!testFile.exists) {

        alert("Please make sure the supplied folder 'AED_CornerCutters' and it's contents are in the same " +

            "folder as this script. Either the folder or some of it's contents are missing. (Check the zip file you downloaded.) Script will now exit.", "Corner Cutters");

        return true; //There are errors.

    }

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Nov 17, 2013 Nov 17, 2013

Thanks Alan, that looks like a solid way to handle it.  Much appreciated for sharing your code!

--Arie

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jan 25, 2017 Jan 25, 2017
LATEST

Hi,

I need your help, i want convert a png to a string, like this; u0089PNG..... etc

would you please help me ? I´m new in javascript

Thanks

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines