Illustrator (Desktop) Bugs
When reporting a bug, please provide a detailed description with the following:
- Details of your operating system
- The version of Adobe Illustrator (desktop)
- The steps you were taking when you experienced the issues
- Your expected result and the actual result
- Upload your Illustrator file or a video (screen recording or gif, this helps us most to reproduce the issue and resolve it)
80 results found
-
ExtendScript evaluates nested ternary operator with wrong (left) associativity
Component: ExtendScript engine (scripting). Affects Illustrator, likely all ExtendScript hosts.
Environment (confirmed):
Illustrator 30.8.2, ExtendScript 4.5.6, macOS 15.7.9
Illustrator CS6 16.0.0, ExtendScript 4.2.12, Windows
Old and new builds, both platforms.Summary:
ExtendScript evaluates a nested conditional expression a ? b : c ? d : e as if it were left-associative, i.e. (a ? b : c) ? d : e, instead of the ECMAScript-required right-associative a ? b : (c ? d : e). ECMA-262 defines ConditionalExpression as right-associative, and this has been the case since the 3rd edition that ExtendScript targets. When any condition before the last is…3 votes -
File names are broken on macOS scripts
Bug reproduction:
#target illustrator var file = File.openDialog("Select any file", "All files:*.*"); var message = 'Results\nfile.name: "' + file.name + '"\nfile.displayName: "' + file.displayName + '"\nfile.localizedName: "' + file.localizedName + '"'; alert(message);Save this as a script, run it in Illustrator on macOS and select any file.
Expected outcome: An alert is displayed with all of the name attributes are populated
Actual outcome: displayName and localizedName give empty string and undefined.Tested on macOS 15.7.1, Illustrator v29.8.2. Same script works on Windows 11.
3 votes -
Javacript locking embeded image
In Illustrator 29.1 this script worked just fine. I place an image, move it, name it, lock it and embed it. But in 29.3 this code gives an error message: It says that it cannot operate on a locked layer, BUT it still locks the placed item. If I move the lock to after the embed, the lock does not happen. So this code no longer works in 29.3.
I think its weird in 29.1 that you were allowed to lock the placeditem before you embed it, but it doesn't work if you lock it afterwards.
We are using macos…
3 votesThe issue is reported to be fixed in the latest Pre-release build 29.4.130.
The provided script should now work without any error dialog, as before.
Please also see the recommended way to achieve locking of embedded art in modified script, in a comment within.
-
app.preferences.setIntegerPreference() does not work
app.preferences.setIntegerPreference("rulerType", 0) changes the selection in the GUI but doesn't actually apply the change to the document.
I still have to go into the GUI preferences, change the units to something else, then back to inches and close for the change to actually apply to the current document.
3 votes -
[ExtendScript] Incorrect paragraph count when linefeeds are used.
MacOS 13.3.1, Adobe Illustrator 27.4.1
To see the issue, run this script:
```
(function () {var doc = app.documents.add(); var tf1 = doc.textFrames.add(); tf1.position = [100, 100]; tf1.contents = 'Paragraph one\u000DParagraph two'; var tf2 = doc.textFrames.add(); tf2.position = [200, 100]; tf2.contents = 'Paragraph one\u0003still paragraph one'; alert('Paragraph counts\n2 paragraphs: ' + tf1.paragraphs.length + '\n1 paragraphs with forced line break:\n ' + tf2.paragraphs.length);})();
```I expect the left text frame to have 2 paragraphs and the right text frame to have 1 paragraph, but the right text frame is incorrectly shown to have 2 paragraphs.
This discussion revolves around…
3 votes -
SVG Export for ExportOptionsSVG does "Save As" and not an "Export As"
There is no true option for the File -> Export -> Export As for an SVG, doing app.activeDocument.exportFile( fileSpec, 'SVG', exportOptions ) is actually running the equivalent of File -> Save As SVG... Which produces an AI compatible type SVG but not a fully compatible SVG with other programs.
It'd be nice to have a true "ExportOptionsCompatibleSVG"
3 votes -
Scripting: move selection to layer doesn't work if layer is not visible
When moving selected elements to a layer, if that layer's visibility is set to false, it reports that it cannot move elements to a locked layer. However, it's not locked, it's just not visible. I do this all the time by physically dragging to a layer that is not currently visible. I was able to work around it by setting visibility to true, moving the elements, then making it false again, but it seems like a bug.
3 votes -
ExtendscriptToolkit is 32bit-only, OSX Catalina is 64bit-only
I use a script I wrote for an important business function. For the last couple OSX upgrades, it has been warning me that ExtendscriptToolkit is not compatible with future versions of the OS. Specifically, OSX Catalina, which has been seeded to developers, will only support 64bit applications, and ExtendscriptToolkit is a 32bit application. Is that going to be addressed before the OS is released?
3 votes -
extension do not work
Illustrator 23.0.2 does not show extensions content even Adobe sample extensions like UI.
I do not have any problem with other CC apps like Photoshop. Photoshop loads a shows the same UI extension.
3 votes -
IllustratorSaveOptions in C# .NET is not working anymore as expected
For more than a decade the following Illustrator script has been applied via C# .NET in combination with all existing Illustrator versions (sourcecode):
typelib.IllustratorSaveOptions saveOptions = new typelib.IllustratorSaveOptions();
saveOptions.Compatibility = typelib.AiCompatibility.aiIllustrator8;
saveOptions.FlattenOutput = typelib.AiOutputFlattening.aiPreserveAppearance;
DestDoc.SaveAs(sPath, saveOptions);All over the internet we see a lot of people using the same code above (applying the exact same idea) also in other programming languages.
Following test has been done with Illustrator versions CS, CS2, CS3, CS5, CS6, etc. on the latest Windows 10 operating system and VS2012: draw 2 intersecting rectangles: above yellow, the other red. A transparency Difference has been set on…
3 votes -
javascript doc.close() after error
https://forums.adobe.com/message/9853322#9853322
for detailsWhen you close the file in the script
After that, an error (1346458189 ('PARM')) occurs with high probability.
Closed processing is closed up to what is not closed or can not be closed
It looks like a bug.3 votes -
Illustrator and scripting inconsistent words[] when tabs used
Can someone explain the results when the following is run on an Illustrator document with one text frame?
var myDoc = app.activeDocument;
var myTextFrame = myDoc.textFrames[0]
myTextFrame.contents = "Lorem ipsum dolor sit amet\rLorem\tipsum\tdolor\tsit\tamet";
alert(myTextFrame.words.length);
alert(myTextFrame.lines[0].words.length);
alert(myTextFrame.lines[1].words.length);
for (l=0; l<2; l++)
{
concat = "#";
for (i=0; i<myTextFrame.lines[l].words.length; i++)
{
concat += myTextFrame.lines[l].words[i].contents;
concat += "#";
}
alert(concat);
}14
5
9
"#Lorem#ipsum#dolor#sit#amet#"
"#Lorem#Lorem#ipsum#ipsum#dolor#dolor#sit#sit#amet#"
Why does separating the words by tabs seem to duplicate all but the last word in the line?
Is this a bug, and if not, what is the logic behind it?
Running on Windows 11 and I…
2 votes -
Scripts cannot read Ignore Color setting from presets
With the appearance of the Ignore Color checkbox, scripts have another big problem besides ignoreWhite.
If a user creates a custom preset with Ignore Color enabled and selects a color, and then tries to automate the use of this preset from a script, the scripts cannot load the data about the Ignore Color checkbox from the preset.
In the mentioned beta version 30.4.0.80, this issue still persists (so it should also be in the GA 30.3)
Example:
(function (){
var image = app.selection[0].trace();
var preset = app.tracingPresetsList[19]; // User index of custom preset
image.tracing.tracingOptions.loadFromPreset(preset);
app.redraw();
image.tracing.expandTracing().selected = true;
})();2 votes -
Script selection/appearance modification causes error 8702
I am using a script to change the appearance of an object (fill color of an ellipse shape). Since there is no way to access appearance properties directly (which would be lovely to get someday), I am using a known workaround with defaultFillColor on the selected document.
app.activeDocument.selection = [item.obj]; app.activeDocument.defaultFillColor = item.newCol;Unfortunately, the selection seems to leave Illustrator in a weird state, and any further script command (e.g. next iteration of the loop) fails with "Error 8702: there is no active document."
This sometimes goes away if I use CPU instead of GPU preview, though not reliably. And…
2 votes -
[ExtendScript] Cannot set some TextRange.characterAttributes after TextFrame.resize.
We cannot successfully set some TextFrame.textRange.characterAttributes after the TextFrame has been resized using TextFrame.resize.
(Tested on MacOS 15.4.1 Adobe Illustrator 29.5.1)
Steps to reproduce:
1. Create new document
2. Run the below scriptExpected Result: all tests passed and no alert message appears.
Actual result: Failed to set characterAttributes.size to 12.
Script:
(function () { var doc = app.activeDocument, textFrame = doc.textFrames.add(); textFrame.textRange.contents = 'Hello.'; textFrame.resize(200, 200); textFrame.textRange.characterAttributes.size = 12; if (textFrame.textRange.characterAttributes.size !== 12) alert('Failed to set characterAttributes.size to 12'); })();NOTE: some other character attributes are "unsettable" also, eg. leading.
2 votes -
Illustrator Version 28.7.1 - xmpfile does not have a constructor ( using Extendscript with Illustrator )
OS: macOS Sonoma 14.6.1 (23G93)
Illustrator version 28.7.1Prior to this update I have been able through extendscript to read XMP data from a file. After the update I get an error:
"XMPfile does not have a constructor".
on the line of code:
var xmpf = new XMPFile(.........Reverting to the prior version resolves the issue.
2 votesWe have fixed this issue in 29.0 and 28.7.2 releases.
-
AI 28.0 preferences corrupted by 28.1 with some 3rd party plugins
When updating from Illustrator 28.0 to 28.1, some preference files may be corrupted if AI is running certain 3rd party plugins. These include any written with Hot Door's CORE and incorporating a WebView widget to display a web page, but I have received reports of this behavior with some SDK plugins as well.
The problem it creates is that new files are not added to the File > Open Recent Files list, and any change to a different workspace is not saved.
For my macOS Ventura with AI 28.1, deleting these preference files solved the problem: Plug-in Cache and plugincache.bin.
…
2 votes -
Justification attribute to center text in Illustrator API
Why do Justification to aiCenter and Align Center produce different results?
Given myLabel string with at least one line break character in it, when I use JavaScript code like this...Set myFrame = textGroup.TextFrames.Add
myFrame.TextRange.CharacterAttributes.Size = defaultFontSize
myFrame.TextRange.CharacterAttributes.TextFont = appRef.TextFonts.Item(nameOfFont)
myFrame.Contents = myLabel
myFrame.Paragraphs(1).ParagraphAttributes.Justification = 2 ' aiCenter
myFrame.Position = Array(myXPos, myYPos)...the lines of text are not centered with respect to each other.
Is there a way, using the JavaScript API, to achieve text-centering of multiple lines in a text frame?
If not, I'd like to request a new paragraph attribute to the JavaScript API to accomplish this function.…2 votes -
[ExtendScript] RasterItem.colorize() does not accept SpotColor via script, but does via UI.
MacOS 13.3.1, Adobe Illustrator 27.4.1
The colorize() method of RasterItem doesn't accept a SpotColor via scripting, but can do via the UI, so there is no technical reason I can see why this it the case. It may be a simple bug. Also there is a workaround by using defaultFillColor which does apply a SpotColor to a RasterItem.
Steps to reproduce:
1. Start with document containing a bitmap (colourable) RasterItem and a SpotColor swatch.
2. script: (adjust the swatch index to match your SpotColor swatch index)app.activeDocument.rasterItems[0].colorize(app.activeDocument.swatches[4].color);Expected result: colorizes the RasterItem.
Actual result: does nothing.2 votes -
Cant' get character properties (AI ver26.4. ~)
AI ver 27.0.1 bug , too
2 votes
- Don't see your idea?