Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




Flash MX: ReplaceSel(str) Bug?



Hey all,

Has anyone succesfullly used the Textfield.replaceSel(textString) function in an input or dynamic text field?

I wanted to use it on a project, but it just inserts the text variable at the beginining of the field rather than where the text is selected.

Any help would be appreciated.

Thanks

Novova



FlashKit > Flash Help > Flash ActionScript
Posted on: 12-16-2002, 11:48 AM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

ReplaceSel() HELP
Basically I have a dynamically created text box which consists of a word and when the user types in wrong letter I want to replace the current letter with the one they typed I've tried to use the replaceSel()

typedText is my textbox

onClipEvent (keyDown) {
_root.wrongWord = String.fromCharCode(Key.getAscii());
Selection.getFocus("_root.typedText");
Selection.setSelection(/:letterCounter, /:letterCounter);
_root.typedtext.replaceSel(_root.wrongWord);
_root.typedtext.getNewTextFormat(); // dont know if need
/utput += _root.typedtext.getNewTextFormat();

/:letterCounter++;
}


Thought this would replace the letter but it doesnt it puts what I've types before the text already in field also causes the textfield to shift to the left of the screen too.

This is the Flash MX help

Method; replaces the current selection with the contents of the text parameter. The text is inserted at the position of the current selection, using the current default character format and default paragraph format. The text is not treated as HTML, even if the text field is an HTML text field.

You can use the replaceSel method to insert and delete text without disrupting the character and paragraph formatting of the rest of the text.



The text is inserted at the position of the current selection, using the current default character format and default paragraph format. - My default is center


Any help appreciated I only want to overwrite but I can't get it too!

ReplaceSel... I'm Not Getting It...
I can't get replaceSel to work the way I understand that it's supposed to, even when I construct what seems to be to be a very basic example:

I've got a dynamic textfield named 'sampleText'. I've got a button that has the actionscript:
on (release) {
sampleText.replaceSel("!!!")
}

So I highlight a word in the text field, and when I click the buttton, I would expect that it replaces the word with '!!!'. But it doesn't. Instead, it puts '!!!' at the beginning of the text field. Any suggestions as to what I'm doing wrong?

#

TextField.replaceSel() HELP
Basically I have a dynamically created text box which consists of a word and when the user types in wrong letter I want to replace the current letter with the one they typed I've tried to use the replaceSel

typedText is my textbox

onClipEvent (keyDown) {
_root.wrongWord = String.fromCharCode(Key.getAscii());
Selection.getFocus("_root.typedText");
Selection.setSelection(/:noteCounter, /:noteCounter+1);
_root.typedtext.replaceSel(_root.wrongWord);
_root.typedtext.getNewTextFormat(); // dont know if need
/utput += _root.typedtext.getNewTextFormat();

/:noteCounter++;
}


Thought this would replace the letter but it doesnt it puts what I've types before the text already in field also causes the textfield to shift to the left of the screen too.

This is the Flash MX help

Method; replaces the current selection with the contents of the text parameter. The text is inserted at the position of the current selection, using the current default character format and default paragraph format. The text is not treated as HTML, even if the text field is an HTML text field.

You can use the replaceSel method to insert and delete text without disrupting the character and paragraph formatting of the rest of the text.



The text is inserted at the position of the current selection, using the current default character format and default paragraph format. - My default is center


Any help appreciated I only want to overwrite

Text.replaceSel Help
Basically using dunamic text object howver ehat I want to know is how to you specify the index tostart replacing the text?


heres what flash help says

TextField.replaceSel(text)

Method; replaces the current selection with the contents of the text parameter. The text is inserted at the position of the current selection, using the current default character format and default paragraph format. The text is not treated as HTML, even if the text field is an HTML text field.

You can use the replaceSel method to insert and delete text without disrupting the character and paragraph formatting of the rest of the text.


Basiaclly how to you specify where you want replacing or is this command only to replace the whole text object can you not specify a point to overwrite and leave the rest unchanged?

ReplaceSel Can't Get It To Work
Hi,

After a lot of searching I'm still unable to replace text that is selected. I want to use this for a sort of word-processor. With HTML formatted text I hope then to be able to make buttons for bold, italic and underlined text. (select; press button > bold)

What I have found is this:

(input textfield has the var name 'TextBox')
button:
code:
on(rollOver){
startSel = Selection.getBeginIndex();
endSel = Selection.getEndIndex();
oldSelection = Selection.getFocus();
if (endSel - startSel > 1){
selected = "true";
}else{
selected = "false";
}
}
on (release) {

if (selected eq "true"){
Selection.setFocus(oldSelection);
Selection.setSelection(startSel,endSel);
TextBox.replaceSel("new text");
}
}


With this code the selected text stays selected after pressing the button (that's good) but nothing will be replaced

Any-one out there able to help me?
I would be most greatfull

ReplaceSel Problem...
Hi,

Ik have made a script where you can input text, and specify where to cut the text ( into a new file ). This works fine, you type your text, every now and then you click the button that says "new file" which places "<newfile>" at where ever the cursor is at that point.

But... This script wil be used corporately, and there is a little bug:
Ik you PASTE text from wordpad or word or any other source, and add the <newfile> tags afterwards, the tags do not register. This is because the line where you generate the <newtag> string, has (usually) nog been typed on.

if you go to the line, press spacebar and backspace ( i.e. typing ) the tag registers. It must have something to do with the fact that generating text is not the same as actually typing it.

the code I use to generate the <newfile> tag:

Code:
Selection.setFocus(theInput);

theInput.replaceSel(" <newfile> ");
is there any other way to do it, so the tag will register?

Help With ReplaceSel/replaceText
I'm currently using replaceSel to insert HTML tags in a block of text, and i've got it working fine with a standard textbox. My issue is that it doesn't seem to work with a textArea component. Is this a bug or am I missing something. Here's the code (adapted from the flash help file):

var my_cm:ContextMenu = new ContextMenu();
my_cm.customItems.push(new ContextMenuItem("Enter current date", enterDate));
function enterDate(obj:Object, menuItem:ContextMenuItem) {
textBox.replaceSel("<br>");
}
textBox.menu = my_cm;

Where "textBox" is the instance name of either a textBox or textArea component.

Thanks for any help you can provide.

Help With AS Function ReplaceSel()
Hi - whoh.. first post here, ever

Need some help with the function replaceSel, it doesnt work the way I want to work it... the documentation didnt helped me that much.

Actually the function only adds the text at the beginning of the textfield. Seems its not really important if the cursor, or the marked text is somewhere else... maybe the doc. means another "marked" but.. what else? I really cannot guess..

Finally I want to do something similar to this handy javascript tool, below this posteditingbox
(ultracode; helping tool for bold, italic, etc. text)

A perfect version should come with the possibility to edit text in an input box, you can mark some parts of the text, click a button somewhere else, a kind of popup should now appears where another textedit line offers the user to edit the marked text separately - and of course - edit the orginal text as like in the popup by clicking ok (or s.t. like this).

(im)possible?

thx,
SonicFlash

[AS1] Using ReplaceSel() To Delete Text
hello, everyone.

i'm having a rather peculiar problem. i've been working on a script to format text brought in from an xml file, and because it's an xml file, i've been using tags much like the ultracode used in these forums, using brackets instead of carets to designate formatting tags.

because the client will later be editing this text in flash and regenerating the xml used to display the text (i guess this is just a kind of kludged text editor), i'm staying away from using html formatting for the text and instead going with straight actionscropt formatting for the text.

okay, now that i've got the "why are you making it so hard on yourself" out of the way, here's my dilemma: i'm using the bold, italic, etc., tags to designate where text formatting begins and ends, formatting the text between tags using TextField.setTextFormat(), and then i want to strip the tags from the text after the formatting is complete. to do this, and keep the formatting, my only option is using TextField.replaceSel().

this is all fine and good, except that i can't replace the text with a goddamned null character! it seems to me that TextField.replaceSel() requires a non-empty string to replace the current selection, so i can't use myText_txt.replaceSel(""); or myText_txt.replaceSel("u0000");. it always requires a space (" ") or some other character that messes up the formatting of the field (not to mention makes it look like all style changes require spacing typos for them to work).

anyone have any ideas on how to make this bend to my will?

thanks in advance

Please Give Me A Hand With ReplaceSel And SetSelection
on (keyPress "<Backspace>") {
if (_root.minChar < Selection.getCaretIndex()) {
Selection.setSelection(Selection.getCaretIndex() - 1,Selection.getCaretIndex());
_root.text_field.replaceSel();
}
}

This is so the user can only backspace to the minChar allowed. Unfortunately it will not replace the selection. I have tried inserting a string in there too and it just won't do anything. The Selection works okay, but it just won't be replaced. It seems very simple and somehow this is completely evading me.

Also:

When I use:

Selection.setSelection(_root.text_field.length, _root.text_field.length);

to get to the end of my text field, it only goes a maximum of eighteen characters in. Also very odd. Pelase help if you can. Thank you.

I Cannot Get ReplaceSel To Work In A TextArea Component HELP
I can get replaceSel to work with a dynamic text field to work, but not with a textArea. I need it to work in a textArea. Any ideas? Is this just anouther bug ... ??

this does not work:

Code:
textArea_txt.text = "Hello World! This is original!!";
Selection.setFocus(textArea_txt);
Selection.setSelection(6, 11);
textArea_txt.replaceSel("Vincent");
this does

Code:
dynamicText_txt.text = "Hello World! This is original!!";
Selection.setFocus(dynamicText_txt);
Selection.setSelection(6, 11);
dynamicText_txt.replaceSel("Vincent");

any help would be great,

ty

--mm

ReplaceSel: I Need To Replace Linebreaks With <br> Tags
Hi, I need to replace linebreaks in text fields with <br> fields to POST the copy to PHP so it can be rendered as HTML...
How do I detect linebreaks in Flash?
If I publish the text as is PHP receives it without any linebreaks (I already tried replacing in php: eregi_replace("
|
|
","<br>"...)

Any help will be greatly appreciated!!

Text Editor ReplaceSel - An Expert Needed
I have created a basic text editor in FlashMX that will format text (Bold, Italic, Align, Font, Color) within an input textfield. I have also added some buttons that will replace selected text with unicode characters.

example:

on (release) {
_root.userinput.replaceSel("u0100");
}

This inserts a macron over a capital A (no problems there). But, if nothing is selected in the textfield the button will insert the character at the beginning of the textfield. My question is: How can I get the character to be inserted at the end of any text that has been typed into the textfield?

ReplaceSel Fails On Stylesheet Formatted Text
I'm building a text editor for a back-end project. The editable text field is formatted by a stylesheet. When I try to use myTextfield.replaceSel on it, it doesn't work ( though if I don't apply a stylesheet it works fine).

I've read somewhere that using a stylesheet on an input textfield locks it, preventing editing?
Can anybody suggest a fix?


Code:
Selection.setFocus(targetText);
Selection.setSelection(startPoint, endPoint);
targetText.replaceSel(insertTags);
Thanks

ReplaceSel Results In Extra Space Preceding Text Replaced
Hi all - I'm working on a little app that allows the user to select a text segment in a dynamic/input field, and upon key press the selected text will change based on built-in parameters.

PROBLEM: Everything is working EXCEPT that when the text segment is replaced, an extra space is inserted before the new text segment.

Here's my code, which lives on Frame 1 and corresponds w/an input text field w/instance name 'myText':

____________________________
myText.addListener(myText);

//note to self: load textContent dynamically in next version
textContent = "This is the text I want to change. This is some other text. Leave this line alone. In this sentence, only select the following word: word."

myText.text=textContent
s = textContent;

_root.onMouseUp = function() {
x = Selection.getBeginIndex();
y = Selection.getEndIndex();
correctText = _level0.s.slice(_level0.x,_level0.y);
}

myText.onChanged = function() {
if ((correctText == "This is the text I want to change") || (correctText == "word")) {
newText = "text is changed";
myText.replaceSel( newText );
z = newText.length;
myTextFormat = new TextFormat();
myTextFormat.color = "0xff0000";
myText.setTextFormat(x, x+z+1, myTextFormat);
s = myText.text;
} else {
newText = correctText
myText.replaceSel( newText );
s = myText.text;
}
};
____________________________

Thanks in advance for any inspirations.

-Sarah

ReplaceSel("HELP")
I am trying to replace selected text using replaceSel() but with no luck.. it seems to do nothing!! Where am I going wrong?!?

on (release) {
myField.replaceSel("new text");
}
Cheers
Ol

Flash Script? Is Writing Flash Code Possible? Without A Flash Builder Like Flash MX
I want to get into flash programming on my website, but i do not have thecash to buy flash MX 2004, it is 499 US thats a lot of money.

Basically what i want to know is, can flash be written as code, like HTML or do i need to buy a flash builder. And if so, what can i do about learning this code

Thanx from Fenton Multimedia Designs

Flash Script? Is Writing Flash Code Possible? Without A Flash Builder Like Flash MX
I want to get into flash programming on my website, but i do not have thecash to buy flash MX 2004, it is 499 US thats a lot of money.

Basically what i want to know is, can flash be written as code, like HTML or do i need to buy a flash builder. And if so, what can i do about learning this code

Thanx from Fenton Multimedia Designs

Flash Versions Order Of Sequence : Flash 5, Flash MX, FlashMX 2004?
some questions on FLash versions

After Flash 5 was FlashMX then followed by FLashMX 2004 ???

which means Flash MX is version 6??

thanks for answering.

Can You Open A Flash File Made With Flash Mx, Using Flash Mx 2004?
Hi,

I have recently purchased flash mx 2004. However when I go to open my old flash mx flies in flash mx 2004 all I get is unexpected file format! Why is this? Also when I open flash mx 2004 and try to open one of the sample files it comes up with the same message!

Also when you download and install an extension from macromedia exchange, how do you then use the extension feature in flash? Were do you find it?

Any help on these matters would be appreciated?

Thank you

How Do You Update A Flash Object Without Flash? Selling A Flash Site.
I am wondering what may be a large wonder. If I create a website with flash etc for somebody else, how can they update their own site? For example, if they have an 'updates' page, I don't want to have to keep on redoing it for them in Flash. I heard words like 'strings' and 'XML' kicking about, but don't really understand it. Thanks,

Alex

Making A Flash Website (flash In A Flash In A Flash Etc...)
I am working on a flash "database" as it's called and to make this possible I will need to have multiple flash documents that load within a flash to keep the loading time down, otherwise the filesize would be astronomical!

To see what I am working on go to http://www.axeldesigns.com/h2/helpdatabase then click "menu button" to open the project. Hopefully then you can get a good sense of what I am trying to accomplish...So when you click on the individual links, I want a flash within the main flash to load completely on top with it's own load bar and everything.

I'm not very experienced with action scripting, but I am quite experienced with the animation side of flash and drawing tools etc...

So, if anyone knows of any tutorials or examples that I could work off of, please help me out.

Alex

Will An Swf Made In Flash MX That Is Exported As Flash 4- Play On Flash 4 Cpu's?
Will an swf made in Flash MX that is exported as Flash 4- play on Flash 4 cpu's? How do I get my mx movies compatible with people who only have Flash 4???? I ask this because I exported a movie made in Mx to Flash 4, so I am just wondering if it will play on all Flash computers that have Flash 4, eventhough they may not have flash 5 or mx. Thanks...

Updating Flash 4 Code To Flash MX 2004 Or Flash 8
Can Flash MX or Flash 8 automatically update old flash code or update depreciated code? I have a flash 4 project that when resaved as Flash MX 2004, obviously starts to throw errors.

Flash 8: Button For Flash Paper In A Flash Presentation
I am new to Flash. I have a presentation I am putting together.  I need a button to open a Flash Paper (Flash Papers 2) .  

How do I do this?
Does anyone sell premade buttons?

Thanks!
 

Flash Over Html, Hide Flash Access Html After Flash Movie Ends
We've got a green screened video playing in a flash movie over top of our html content.

when the movie ends, flash uses external interface .api to call a javascript function which swaps the flash movie out with a 5 x 5 pixel flash movie (rewrites the <div>).

this works and you can interact with the html content after the flash movie in all browsers except firefox...!

anyone know of any work-arounds or is there a better way of handling flash over html in this fashion?

any input would be greatly appreciated!

HOW DO YOU CHANGE THE BG OF THE FLASH THING ON FLASH KIT W/OUT USING FLASH?
Plz tell me because I am making a little kid's website and they'll b sad if doesn't match the flash.

Yikes, Can I Go From Flash MX To Flash MX 2004 To Flash MX?
I have flash MX on my computer here at home, I went on campus to edit a file in a class in Flash MX 2004, now I am trying to reopen the file in Flash MX here at home again and it won't allow me to open it, saything there is an unexpected format error.

Is this caused from opening it in Flash MX 2004? Is there a way to revert the file back to Flash MX? Yikes!

Flash/CSS Question: Can Flash In A <div> Overlay Another <div> Containing Flash?
I'm guessing this answer is no but thought I'd ask anyway.

With the "wmode" set to transparent I can get my top div to overlay text/background images no problems but not on top of another flash movie.

Can it be done?

Flash 8 Function Not Working In Flash 8 But In Flash 9
I use this piece of Code from Senoculars Matrix Tutorial:


Code:
import flash.geom.Matrix;
function duplicateMovieClipImage(from, target){
var pics= new flash.display.BitmapData(from._width, from._height);
pics.draw(from);
target.attachBitmap(pics, 1);
}
duplicateMovieClipImage(this.viewer.picHolder, doubleSize.bigpic);
var my_matrix2 = doubleSize.bigpic.transform.matrix;
my_matrix2.scale(1, 1);
my_matrix2.tx = -2;
my_matrix2.ty = -2;
doubleSize.bigpic.transform.matrix = my_matrix2;

duplicateMovieClipImage(viewer.picHolder, normalSize.bigpic);
var my_matrix = normalSize.bigpic.transform.matrix;
my_matrix.scale(0.25, 0.25);
my_matrix.tx = 0;
my_matrix.ty = 0;
normalSize.bigpic.transform.matrix = my_matrix;
When I play this in a Flash 9 Player everything is made correct (A Pic generated in its Original Form and one in its 0.25/0.25 Size.

But when I watch this in a Flash 8 Player (8.0.22.0 that is)

the Script is ignored

any1 know why???

Firefox Recognizes Quicktime As Flash Player Instead Of Flash As Flash Player
I don't know why when I go to websites and all those old Flash sites don't work anymore, but I get the "Quicktime Question Mark" logo. I've tried reinstalling Flash Player so many times but the quicktime logo keeps coming up. I've tried this both with Firefox and Safari and it just doesn't work.

Nested Function Locks Flash On 2nd Frame. Cold Fusion Problem Or Flash MX ? Or Me?
It's been three days I don't sleep. Anybody,please,.....

// Flash MX code 2nd frame

stop();
validatePackage = new LoadVars();
validatePackage.onLoad = function() {
if (validatePackage.success == "0") {
setPackageCheck = new LoadVars();
setPackageCheck.onLoad = function() {
_root.packageCheck.text = setPackageCheck.packageCheck;
_root.unlockCheck.text = setPackageCheck.unlockCheck;
_root.gotoAndStop("exPrep");/* without this line
everything works perfectly !!!!!. WHY ! I mean I have other functions sending time line somewhere else accordint to if statments and it works fine!*/
};
setPackageCheck.accountID = _root.accountID.text;
setPackageCheck.sendAndLoad("setPackageCheck.cfm", setPackageCheck, "POST");
} else {
_root.packageCheck.text = validatePackage.packageCheck;
_root.unlockCheck.text = validatePackage.unlockCheck;
_root.vdDays1.text = validatePackage.vdDays;
_root.vdHours1.text = validatePackage.vdHours;
_root.vdMinutes1.text = validatePackage.vdMinutes;
_root.gotoAndStop("exPrep");/* without this line
everything works perfectly !!!!!. WHY !*/
}
};
validatePackage.accountID = _root.accountID.text;
validatePackage.sendAndLoad("validatePackage.cfm", validatePackage, "POST");


<--- "validatePackage.cfm"--->

<cfquery name="validatePackage" datasource="dsn">
SELECT packageCheck, unlockCheck
FROM accounts
WHERE accountID=#form.accountID#
</cfquery>
<cfif validatePackage.packageCheck lt 1>
<cfoutput query="validatePackage">
&success=0&
&unlockCheck=#urlencodedformat(validatePackage.unl ockCheck)#&
</cfoutput>
<cfelse>
<cfset vdDays=#DateDiff("d",#validatePackage.packageCheck #, now())#>
<cfset vdHours=#DateDiff("h",#validatePackage.packageChec k#, now())#>
<cfset vdMinutes=#DateDiff("n",#validatePackage.packageCh eck#, now())#>
<cfoutput query="validatePackage">
&packageCheck=#urlencodedformat(validatePackage.pa ckageCheck)#&
&unlockCheck=#urlencodedformat(validatePackage.unl ockCheck)#&
&vdDays=#vdDays#&
&vdHours=#vdHours#&
&vdMinutes=#vdMinutes#&
</cfoutput>
</cfif>

<--- "setPackageCheck.cfm"--->

<cfquery name="setValues" datasource = "dsn">
UPDATE accounts
SET packageCheck= #now()#
WHERE accountID=#form.accountID#
</cfquery>
<cfquery name="setPackageCheck" datasource = "dsn">
SELECT packageCheck, unlockCheck
FROM accounts
WHERE accountID=#form.accountID#
</cfquery>
<cfoutput query="setPackageCheck">
&packageCheck=#urlencodedformat(setPackageCheck.pa ckageCheck)#&
&unlockCheck=#urlencodedformat(setPackageCheck.unl ockCheck)#&
</cfoutput>

[MX04] Open A New Link In Html By Clicking Button In Flash (no Code In Flash).
Hi,

I'm facing problem while opening a new html window by clicking button created in flash.

For this i don't want to write single code in flash but want to handle this through the html only.

For this I have used <embed> tag to add swf file in html. but could not add click code in HTML on that button.

Could any one help me out?

Get Variables Inside Flash 9 Movie With Action Script 3 Using Flash Selenium And Sele
Dear All,


I use Selenium RC and I want to do automated flash testing. I am using Flash Selenium.


Web Application has Flash content (SWF file) and is Version 9.0 and uses Action Script 3.0.


I cant use the functions like flashApp.Getvariable(varName) or flashapp.TotalFrames() as mentioned http://code.google.com/p/flash-selenium/


I see documentation and functions listed at ( http://www.adobe.com/support/flash/p...h/scriptingwit hflash_03.html functions for Flash 5 ), i cant use them . I get exception all the time.


I am trying to access the varibales in the flash movie which is loaded using GetVariable but Selenium throws an exception but no information message.


I want to ask can I use functions listed on above adobe site with Flash 9 movie with Action Script 3.0 ? If not is there any way to get variables inside Flash movie using Flash External Interface and Selenium RC ?


Best Regards !


/ Yogesh

How Print Html Page Or Word Outside Flash When Click Button Inside Flash ?
hello,


how print html page or word outside flash when click button inside flash ?

any ideas or what the action can help me to do that ?

Remove Double Click In XP For Flash & Show Flash In Firewall Protected Environment
Remove Double click in XP for flash & show flash inside firewall protected environment


Here is some code that will disable the annoying double click feature for flash when using XP. This code also enables all viewers to see your flash. For example some firewalls block flash (SO STUPID) but with this code instead of using the embed tags and object tags allows those users behind firewall environments to see your hard worked flash masterpiece.

Okay here is how you do it.
Inside your main file that is calling the flash .swf.
Remove the code that you currently have there and replace it with the code that is inside the putInsideIndex.html (see attachment)
Make sure that you change the name of the movie in that code so that it opens your swf. You might need to change the width and the height too so that you don't have your flash looking like a monster.

Alright then you need to take the other file called RemoveDoubleClick.js
Open it in your editor and change the name to the name of your choosing on line 12. Then post that file (DO NOT RENAME IT) into the same directory as the main file that you edited above. Most cases that would be the index.html or whatever.

So enjoy and start letting EVERYONE see your sites & be more user friendly!
GOOD LUCK!

New To Flash, Create A Flash Form Which Is Emailed Using CGI Script When Submit Button Is Pressed
I'm trying to build a form in flash that is emailed using CGI script. I'm just lost and confused and I just can't seem to figure this out.

This is the CGI coding for HTML and I just need to convert it to use in CS3:
<form action="

Outputting Data In Flash To Text Documents, Creating Textdocs With Flash & Mc Filters
Question 1: How do I add a filter to a movieclip from actionscript,
More specificly, the "adjust color" filter, and I want to decrease brightness, saturation, hue, and contrast... by actionscript...
If you dont know what I mean, use the circle tool to create a circle, convert to movie clip, click the "filter" tab, then click + and add a adjust color filter, you'll see what I mean...

Question 2: I need to output text to 'text' documents, no I cannot use shared objects for this, as it is a program for a client, and it isn't safe enough for me...

Basically, this is what I want to do...


Code:
var archive:Array = [];
archive[7] = "Hello I am the 8th archive";

//save to a text document called "archive7" in the directory myProgramfiles
//finished with code...
then

on initilization of my program, it'd do this

Code:
//get text from the text document I saved in the directory "myProgramfilesarchive7"
Thats what I really need

Question 3:Is there a way to create a folder, text document, through flash
//example


Code:
var textdoc:TextDocument = new TextDocument();
textdoc.name = archive7;
textdoc.text = "Hello I am the 8th archive";
Can anyone tell me how to do this

Thanks in advance

The Flash Anthology: Cool Effects &amp; Practical ActionScript - Chapter 1: Flash Essentials
This is an article discussion thread for discussing the SitePoint article, "The Flash Anthology: Cool Effects & Practical ActionScript - Chapter 1: Flash Essentials"

The Flash Anthology: Cool Effects & Practical ActionScript - Chapter 1: Flash Essenti
Notice: This is a discussion thread for comments about the SitePoint article, The Flash Anthology: Cool Effects & Practical ActionScript - Chapter 1: Flash Essentials.
__________

eXCELLENT! clearly composed article, gonna read the other chapters too. thanks

Call Flash Function From Href Tag Within A Flash Html Text Field?
I'm creating dynamic html fields within Flash and have been succesful calling javascript functions or launching browsers, but what would REALLY be cool would to actually call Flash functions with those href tags.

Does that sound like a possibility to anybody?

Or, alternatley, could a javascript function in the web page execute a function within the swf?

Create Java Pop Up From Flash Index Site To Standalone Flash Popup
Want bad help to create a javapop up link from index.htm flash movie with a enter button that leads to the other .swf that is a popup window with another .swf. How do I do that.

One more thing is there a real good downloadable on how to make "news" scrolls in flash the ones I have seen did not please me.

And is there a way to connect that "news" feed scroller to a text dokument for easier updates instead of having to redo the thing in the .fla file

Hope you understand my problems and I would really appreciate all help I can get.

Cheers

Best regards

/s

Flash 6 Generator Equivalent To Export Dynamically Populated Images From Flash
I'm trying to do an automatic export of graphics developed in flash, for static site elements- graphic buttons.
Generator used to export images from dynamically populated templates, but MX does not support generator, Also being that generator ran with 4 and 5, dynamic text field sizing was not an option-this is necessary to fit the button graphics to text.

Is there either something that I can generate buttons with flash, or has anyone seen a button generator that can batch export and use imported graphics?

Thanks in advance!!!

Using Flash To Open A New Browser Window - Exact Size Of Flash Movie?
Hi,

In Dreamweaver, I've previously used the 'open new browser window' behaviour from a link to display my Flash movies, and entered the .SWF filename as the URL to launch (this launches a browser window thatls exactly the size of the movie, no scrollbars, buttons etc). Can I do a similar thing with Flash's 'get URL' command, or does that only go to HTML/HTM files?

Cheers, Skratch

Using Flash To Open A New Browser Window - Exact Size Of Flash Movie?
Hi,

In Dreamweaver, I've previously used the 'open new browser window' behaviour from a link to display my Flash movies, and entered the .SWF filename as the URL to launch (this launches a browser window thatls exactly the size of the movie, no scrollbars, buttons etc). Can I do a similar thing with Flash's 'get URL' command, or does that only go to HTML/HTM files?

Cheers, Skratch

Pass Variable To Custom Function Not Working In Flash MX For Flash 6 Player
I have a Flash application that I built in Flash 5 that I want to now output in Flash MX (not 2004, though) for Flash 6 Player. The problem is that part of my code, which works fine if published for Flash 5 Player, breaks if published for Flash 6 Player. I am loading text from an external text file, and then passing the text contents of each variable to a function (to strip line breaks). Following is the code... does anyone know how to rewrite this so that it will work as Flash 6 Player swf? The contents of the variable are not getting passed, and eval does not work on left side of expression... I've tried everything I can think of...

Thanks in advance for help.

-S



PHP Code:



/* content, correct, Q1, Q2, Q3, etc are all variable loaded from external text file. I am trying to pass contents of variables, which is why I need to eval them. This worked in Flash 5, but not in Flash MX if I publish as Flash Player 6 file.  */   
temp = stripLineBreak("content");
temp = stripLineBreak("correct");
for (i=1; i<=10; i++){
     z="Q"+i
     temp = stripLineBreak(z);
}
     
function stripLineBreak(x) {
     tempArray = new Array();
     tempArray = eval(x).split("
");
     eval(x) = tempArray.join("");
     tempArray.splice(0,tempArray.length);
     tempArray = eval(x).split("
");
     eval(x) = tempArray.join("");
     tempArray.splice(0,tempArray.length);
}

Href Not Useable In Flash. . .then Any Ideas On How To Make A FAQ Type Thing In Flash
Without having to make all of your questions into buttons ??

any ideas sugestions please help.. .thanks

Darin

Any Tools To Convert Macintosh Flash Movie Source To PC Flash Version?
Hi Folks,

One of my client has given me a flash movie made in flash mx 2004 version 7.It is in Macintosh.

I am trying to open it in PC ,but it says " unexpected file format"

Are there any tools to convert from macintosh flash to PC flash.

Your help will be appreciated.

Thanks

Ie6 Crashes When The Mousepointer Leaves The Flash Movie Area. [Flash Player 8]
Not sure if this is the right area for this thread, but i'm not sure where it fits in...

I have a draggable map program that uses LoadVars.load to send location messages back to the server.

After a user saves a location, thereby triggering the load() method, and then moves their mouse pointer outside the area of the .swf movie on the html page, the browser crashes.

I haven't been able to replicate it on any other computer except this users', which is using Flash Player 8, and IE6. Of course the only user of this side of the app, is this user, so im forced to find an answer.

Anyone else run into this, or have any wisdom to impart on me?

Copyright © 2005-08 www.BigResource.com, All rights reserved