i am a newbie flash designer. a client has asked me to make modifications in a flash file used on his website. it is flash 8 actionscript. i am currently working on the same and would appreciate your help. the client has given me 'divisions.swf' file which i decompiled using sothink decompiler 4.5 build 90120 to '~divisions original.fla'. the xml folder resides in the same folder as ~divisions original.fla. it contains divisions.xml. you can download these files at

i discovered a problem - if you view 'divisions.swf' - when you click on 'retail visual solutions'and scroll to the bottom, you can see that there is no space after the text. the end of the text aligns with the end of the scrollbar. but when you click on eyesite, and scroll to the bottom, you can see that there is space after the text. the end of the text does not align with the end of the scrollbar.

please help me to resolve this problem.

my additional questions are:
has the creator of the swf file used some unique scrollbar code or is this scrollbar provided in flash itself. in this case, i can read a tutorial to understand it better.

i have given 'is correct - no space at bottom of text.jpg' and 'is incorrect - space at bottom of text.jpg' to further explain my query.

please tell me if i have explained my problem properly or further clarifications are needed.

Dani AI

Generated

Small, inconsistent gaps when you scroll to the bottom usually come from one of two places: the source text (hidden characters, extra line breaks, encoding) or the way the text field/scroll is measured and positioned. ’s diagnostic path (checking source data first) is a good start — here are practical, low-risk steps to reproduce, find, and fix the issue reliably.

First, inspect the raw XML for invisible characters and encoding problems. Open it in an editor that can show "invisibles" or a hex/UTF-8 view and look for stray bytes (BOMs, extra CR/LF, zero-width spaces). If unsure, dump the last few characters and their character codes at runtime to see exactly what is being assigned to the text field. Example ActionScript 2 snippet to inspect and trim content:

var s:String = myXMLNode.firstChild.nodeValue;
var tail:String = s.substr(Math.max(0, s.length-5));
for (var i:Number = 0; i < tail.length; i++) {
  trace("idx", i, "code", tail.charCodeAt(i), "char '" + tail.charAt(i) + "'");
}

function rtrim(str:String):String {
  var i:Number = str.length - 1;
  while (i >= 0 && str.charCodeAt(i) <= 32) { i--; }
  return str.slice(0, i + 1);
}
myTF.text = rtrim(s);
myTF.scroll = myTF.maxscroll;

Second, verify text-field metrics and settings. Use textHeight and autoSize for measurement checks; if the field is masked, compute the content height from textHeight (add a small pixel offset to account for internal padding) and set the mask/clip size accordingly. Be aware that htmlText, embedded fonts, and differing line-leading can change the final layout — test entries with the same font/formatting to compare.

Finally, when working from a decompiled FLA, keep backups and test fixes in small, isolated test files first. Decompiled assets and scripts can be altered or incomplete; recreating the scrolling component in a tiny test FLA often identifies whether the problem is the data or the implementation. — these steps let you find hidden chars, normalize the XML, and make the text field behave consistently regardless of which entry is loaded.

Recommended Answers

All 2 Replies

This one was pretty straightforward...

Take a look at divisions.xml

If you look at the entry for "Eyesite" you can see that the "[CDATA[" tag at the start of the line hasn't been closed properly at the end.
The line currently ends with:

in an effective manner.</Option>

The end of this line of xml should read:

in an effective manner.]]></Option>

That will solve your extra space issue for this file....

In answer to your scrollbar question, the scrollbar appears to have been created by the original author of this .swf, created entirely from scratch. So it's not a standard flash UI scrollbar component.

Cheers for now,
Jas.

commented: completely solved my problem +1

many thanks, jasonhippy. you are a real life saver. i would like to clarify that i have spent many long hours trying to solve all the changes/problems with the flash and am only posting here as a last resort because of looming deadlines.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.