Hi, there
Im new to flash, mostly in to php and html, but i want to try out new things this is more of a hobby thing… well, let me get in to my to major problems right now…
-
I cant seem to load external txt correctly… i cant load it with fonts only if i select “use system fonts” and when it loads my Scroll dont work, like it isnt activated… i double checked everything, names , codes, and started from strach…
the lay out is as follows…
Main scene -----|
|
|—Movie 1
|
|—Movie 2
|
|— then in side movie 2 i have the txt area where it needs to load the external txt…
is that a problem because i have to many movies…?
-
no for my second problem is i cant get the pop script to work…
layout same as above
Main scene -----|
|
|—Movie 1
|
|—Movie 2–button<<with script<<
so can my problem be that i have it to deep in to flash??
thanks for the help
sorry i asked 2 questions in one thread just that i didnt want to make 2 spearate threads…
Sounds like it could be a path problem. Are you using a kirupa tutorial by any chance? Regardless, since your textbox is inside a movieclip you have to include the instance name of the movieclip in your code. In other words, if you have _root.TextBoxName you have to change that to _root.MovieClipName.TextBoxName.
It doesn’t matter how many movies you have, as long as the path to the textbox through the movies is correct.
I suspect problem #2 is similar but hard to tell without seeing the code.
Hope this helps :hr:
Thanks Lunatic
well for the pop i used this code from this site
http://www.flashkit.com/tutorials/Actionscripting/Cool_pop-Peyman_H-708/index.php
[FONT=Arial][SIZE=2]**Step 1. **Create a button symbol in flash and attach this code to the instance on stage:[/SIZE][/FONT]
[FONT=Arial][SIZE=2] [COLOR=#0000ff]on[/COLOR] ([COLOR=#0000ff]release[/COLOR]) {
[COLOR=#0000ff]getURL[/COLOR] ([COLOR=#333333]"JavaScript:pop();"[/COLOR]);
}
[/SIZE][/FONT]
[FONT=Arial][SIZE=2]This code calls a JavaScript function -pop- that is inside the html file hosting it. That means when the button is released the JavaScript function *[COLOR=#336699]pop[/COLOR] *will be executed.[/SIZE][/FONT]
[FONT=Arial][SIZE=2]**Step 2. **Save your fla file and name it [COLOR=#336699]opener.fla[/COLOR]. publish your file (Press F12) and open the HTML file that has just been created where you had saved the current fla file. Insert the JavaScript Code below, between the [COLOR=#336699]<Head> </Head>[/COLOR] tags. [/SIZE][/FONT]
[FONT=Arial][SIZE=2]** [COLOR=#ffffff][U]IMPORTANT NOTE : DON'T COPY AND PASTE THIS CODE. REWRITE IT.[/U][/COLOR]**[/SIZE][/FONT]
[FONT=Arial][SIZE=2][COLOR=#0000ff]<SCRIPT LANGUAGE[/COLOR]="JavaScript"[COLOR=#0000ff]>[/COLOR]
f[COLOR=#cc0000]unction pop() {
window.open("popup.html","","height=200,width=200,left=0,top=0");
}[/COLOR]
[COLOR=#0000ff]</script>[/COLOR][/SIZE][/FONT]
[FONT=Arial][SIZE=2][COLOR=#000000]**Step 3. **Now you have your button that will open a popup window named [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#336699]popup.html [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000]and it is the time for you to create another HTML file named [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#336699]popup.html [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000]that will be opened as I mentioned above. Ok this HTML file can also contain a swf file or whatever you put inside it But this HTML file will be opened with height and width you specify in the JavaScript code. That means you have to adjust what [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#336699]popup.html [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000]contains with your JavaScript code.[/COLOR][/SIZE][/FONT]
[FONT=Arial][SIZE=2][COLOR=#000000]**Settings. **You can adjust the popup's [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#0000ff]height[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000] (200 in the example)[/COLOR][/SIZE][/FONT]
[FONT=Arial][SIZE=2][COLOR=#000000] [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000]You can adjust the popup's [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#0000ff]width[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000] (200 in the example)[/COLOR][/SIZE][/FONT]
[FONT=Arial][SIZE=2][COLOR=#000000] [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000]You can specify the popup's position ([/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#0000ff]x[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000]=0 & [/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#0000ff]y[/COLOR][/SIZE][/FONT][FONT=Arial][SIZE=2][COLOR=#000000]=0 in the example)[/COLOR][/SIZE][/FONT]
hmmm - I don’t know what to do with that one.
Try this one - it seems to work well for others
http://www.kirupa.com/developer/mx/centered_popup.htm