VideoJukebox stop streaming

Hello there all you flash gurus and experts!
I'm trying to learn how to use the VideoJukebox sample that
you can download from:
http://www.adobe.com/support/documentation/en/flash/samples/
My problem is, that I'm adding the child swf (videojukebox)
to my main swf as a videoplayer. When I remove the child the sound
continues to play. I know this is a common problem and that I
should use unload and close the netstream, but some how I can only
do it within the external actionscript code. I even added a button
to the Videojukebox fla, to test if I manage to close the net
stream. That worked ok, but trying to control the VideoJukebox from
the mother swf doesn't work. There are three files involved:
website.swf, videojukebox.swf and videojukebox.as.
This is how I attach the videojukebox.swf to my website.swf:
var container:Sprite = new Sprite();
addChild(container);
var ldr:Loader = new Loader();
var urlReq:URLRequest = new URLRequest("VideoJukebox.swf");
ldr.load(urlReq);
ldr.contentLoaderInfo.addEventListener(Event.COMPLETE,
loaded);
function loaded(event:Event):void
myMovieClip_mc.addChild(ldr.content);
Then to remove it I use:
button1.addEventListener (MouseEvent.CLICK,do_videoaway);
function do_videoaway(event:Event):void
myMovieClip_mc.removeChild(ldr.content);
I know I should access the NetStream of videojukebox.as
somehow and turn it off before removing the child...
Videojukebox.as uses:
package {
(...first imports all kinds of stuff...)
public class VideoJukebox extends Sprite {
private var meta:Object;
private var nc:NetConnection;
private var ns:NetStream;
private var playlist:XML;
private var t:Timer;
private var uldr:URLLoader;
private var vid:Video;
private var videosXML:XMLList;
This might be really stupid question, but how can I use the
commond ns.close(); from my website.swf???
Using it just like that it gives an error:
1120: Access of undefined property ns.

Could it have something to do with the package? Can I enter
the variables outside of the package?
- Still an amateur

Similar Messages

  • AirTunes stops streaming after each song but iTunes shows it playing

    I've read through a lot of posts and either people are having the same issue just describing them differently or I'm seeing an entirely different issue.
    My setup is Windows Vista running iTunes 8, Airport Express and an iPod Touch running the Remote app. I just bought it all yesterday and did all the firmware and software updates it asked me to when setting it all up.
    I had it setup wirelessly and working -- the remote controlled iTunes which send audio to my AE and it worked beautifully. Then I realized the music stopped, I went to check and iTunes still showed the music playing, but no sound was coming out of the remote speakers. If I change the speaker output to computer then back to the remote speakers it starts playing again.
    I've disabled wireless on the AE and put a long wire across to rule out wirless interference or problems. I've disabled the Windows Vista firewall as well.
    I've tested both from the remote and from using iTunes directly. So I've ruled out the Remote App from the equation (I think). I say that, because first thing this morning I ran using just iTunes and it worked for 15 straight songs. I used the remote to change albums and start another and after the first song played it went silent. I noticed in iTunes a playlist called "Remote" comes up so I was thinking the Remote was causing it. I switched over to my library local on iTunes again removing the remote and it keeps happening anyway. So I'm not sure if by using the remote I put it in this "state" or if it's really not the Remotes problem.
    OK, so once it happens, it stops streaming after very single song however iTunes still shows it's playing fine. To fix, turn the speaker off then on again or switch to computer then back to remote again. It works doing this via the Remote App or on iTunes directly.
    This is FRUSTRATING! I spent a lot of money on the iPod, AE and getting a cheap stereo receiver/amp to feed my in-house speakers and now it's pretty much not even useful.
    Suggestions? Help? Anything?
    Message was edited by: TimLindner

    I wanted to post a follow-up. I solved my own issue after starting to rule out every possible cause.
    I have a Western Digital networked hard drive (NAS) which houses all of my MP3's. I knew accessing this drive was pretty slow but I've had my MP3's on it and iTunes' library is all coming off this drive. It has worked fine on my computer for years. However, it appears that the lag doesn't play nice with AirTunes.
    I moved my entire iTunes library (about 80 GB) to my local machine's hard drive, rebuilt my library and now it plays flawlessly!
    Just so people know, I've updated firmware on the AirportExpress and the iPod Touch, I have the new version of Remote on the touch and am running iTunes 8 on Windows Vista with its library on the local harddrive. No glitches, pauses, or problems. I ran it for 6 hours during a party over the weekend without flaw.
    -Tim

  • HT201077 I have windows 8.1 and ios7.  contacts and calendar stopped streaming to my laptop but was ok on ipad and iphone. That problem fixed but now photos stopped streaming to laptop.  Any suggestions

    I have windows 8.1 & ios7.  Contacts & calender stopped streaming to laptop. ok to ipad & iphone.  This was fixed but now photos stopped streaming to laptop again ipad/iphone talk.  All settings seem ok.  Any suggestions?

    Hey pat121,
    I would run through the recommended troubleshooting steps in the following article to see if that alleviates the issue:
    iCloud: My Photo Stream troubleshooting
    http://support.apple.com/kb/TS3989
    Welcome to Apple Support Communities!
    Regards,
    Delgadoh

  • Why does my apple tv constantly stop streaming and become unable to connect to itunes?

    I have a 2nd gen Apple TV, which I bought in Dec'10. Lately, as in the last month, it just stops streaming. It will be streaming content, then all of a sudden, it stops, and bar comes up on the bottom of the screen, showing the length of the video, with a spinning icon on the left, where the play/RW/FF icon usually appear. It never recovers. I'll stop the video, and try playing again, but it will say that "netflix" or "iTunes" etc. is currently not available. It's as if it's getting knocked offline. I check my setting, and the ip address is fine, it is not assigning itself an ip address. My internet is working with no issues at all. I'll try doing a network test but it sits there trying to connect to itunes, then it says it's unable to do so.
    It's becoming more and more frequent. The only thing that works is resetting it, and sometimes even that doesn't work. So, I have to restore it. I've had to restore a couple times in the past month, and I'm resetting almost daily.
    Also, sometimes it just reboots itself for no reason at all. This, too is occuring more and more on a regular basis.
    I have the apple tv plugged right into my Time Capsule via ethernet. The hdmi out is going to an input on my surround sound receiver. I've also bypassed the receiver, just to rule it out. I typically get anywhere from 30-40 mbps when I do a speedtest from my macbook on speedtest.net or speakeasy. I'm mentioning this because my connection is more than sufficient to stream the 720p content the apple tv is limited to. My interenet has gone out in the past, but it's rare. It's not the culprit, since someone is always on line when this happens, so we'd know right away if it was the internet going out. It's always the first thing I check when this happens, even though I'm pretty sure my connection is not the issue. Also, I don't start freaking out, the second it happens. I usually don't look into it until a minute or so after the video has frozen. At that point I usually hit MENU, to escape the current screen, then try playing the content again. That's when it can't do anything, and I'm often forced to reset or reboot.
    I have tried searching for others with this issue, but haven't come across anything. The closest I've seen are situations where people can't stream at all, due to a network issue. Also, it's been getting worse, which makes me wonder if it's a hardware issue. Again, the apple tv is on a wired connection to my Time Capsule, and the ip address is not self assigned, it starts with DHCP, not 169... And, my internet connection is not the issue.
    Any help would be appreciated, and sorry if I repeated myself, I just wanted to make sure I didn't leave anything out.

    I had problems with streaming until I changed the WiFi channel that I was using.  The original one conflicted with my neighbor.  After that, MOST of my streaming problems vanished.  Occasionally, a movie would pause for more buffering and I eventually ran an ethernet cable from the Apple TV to my Apple Extreme (to eliminate the Wifi).  I have not had a single problem since then (except to repair the drywall after running the ethernet from one floor to another).  :-)

  • Apple tv stop streaming when screensaver starts

    When I am listening to Spotify from My iPad through appletv the appletv stop streaming the music when screensaver turn in. It worked before the last update of appletv.

    Try to restart your wireless router.... Do you have issues with connectivity when using netflix or crackle apps on the ATV?

  • IPod Touch 2.2.1 Stopped Streaming Quicktime Clips

    Hello,
    I searched and couldn't find any info on why my iPod Touch 2G stopped streaming quicktime clips from the site drummerworld.com.
    This has not been an issue until recently, and now I just get a strange icon rather than a clip playing. Any info would be great as I visit this site quite often for tips and such.

    [quote]Since it is tied to the OS you are running, you really don't have any control over which version of Quicktime you are running. [/quote]
    Ok, I'm running v 7.6 which is the same as the site.
    Perhaps the site has changed something ? This is strange because it worked for the first few weeks.

  • My Photos have stopped streaming to my pc

    My Photos have stopped streaming to my PC from Iphone 4s & Ipad.  I have IOS 8.1.1 on both  phone & Ipad.  I have iCloud 4 on pC. It was working fine before I upgraded to iCloud 4.
    The photos are streaming between my two apple products just not to my PC.
    Thanks for any help.

    Hi ctmelancon,
    If you are having issues with your Photo Stream, you may find the following articles helpful:
    iCloud: My Photo Stream FAQ
    http://support.apple.com/kb/ht4486
    iCloud: My Photo Stream troubleshooting
    http://support.apple.com/kb/ts3989
    Regards,
    - Brenden

  • TV and Airport EXPRESS stop streaming after update

    I have read all of the posts regarding the Airport Extreme update being the culprit of the slow streaming with the Apple TV, but I have an Airport Express (2 actually) that suddenly stopped streaming after the last batch of updates (iTunes 8 etc.).
    Everything has been working flawlessly - I have all my movies and TV shows on an old Mac that streams to my Apple TV via 2 Airport Express base stations. I have one AE station "hosting" my internet connection, and then the other acting as a WDS remote. Suddenly after the last updates I have no streaming. I have re-set everything, and re-connected my media server to my Apple TV and no luck. My AE's are at the latest firmware 6.3, and Apple TV, iTunes and even OS is all up to date.
    If anyone has any ideas how to fix this I would really appreciate it - it's driving me crazy.
    Thanks in advance.

    Am in the same boat as it where, so will be happy to hear a solution!

  • Both of my ATV1's stopped streaming today!

    Both of my ATV1's stopped streaming today! I can set them up for streaming to any of several Macs in the house, but I can't stream any content!
    The user interface is very sluggish on both of them. Every time I try to scroll down to "Shared Movies" it jumps back to the top of the menu before it recognizes that I have hit the select button. I believe this is the reason I cannot stream content--one time I was able to stream music but that was after much trial and error, and I have not been able to repeat it since that one time.
    I have one ATV3 which still seems to work fine.
    I am using hardwired Ethernet, not Wifi.
    Anyone else seeing this?

    There is a fault with iTunes and apple tv 1
    See this thread
    https://discussions.apple.com/thread/6099057?start=165&tstart=0
    Report it to apple

  • How to stop streaming

    I'm developing a Dashboard widget that plays an internet radio stream using the Flip4Mac .wma codec.
    When i use the javascript API and call SetURL and Play() it plays fine. When I call Stop() it stops playing, but it doesn't stop streaming. It keeps streaming even if I try to use SetURL with an empty url, "about:blank" and other gibberish.
    Actually, even reloading the widget doesn't help - it keeps streaming. Closing the widget seems to do the trick after a few seconds.
    I can't really release this widget without a solution, so any solutions or suggestions are welcome!

    artmar1 wrote:
    I want to turn off streaming on one ATV.
    If it is a primary library that you no longer wish to stream, select 'Show only the synced items on my Apple tv' from the summary tab in itunes when the Apple tv is selected in the device menu.
    If it is a secondary library ctrl-click/right-click on the Apple tv in the device list and choose 'turn off streaming' from the contextual menu that appears.
    (Please excuse my unsupported nomenclature)
    Message was edited by: Winston Churchill

  • How to stop streaming to @tv...

    Ok I synced about 140G on my ATV. I moved the thing upstairs and wanted to sync more so I set up streaming overnite to sync the new movies. Now I want to stop streaming and just watch what I have synced. How the heck do I do that? No internet upstairs so plugging a line in will not do that. I am stumped. I stream to the one in the LR.
    Thanks,
    Art

    artmar1 wrote:
    I want to turn off streaming on one ATV.
    If it is a primary library that you no longer wish to stream, select 'Show only the synced items on my Apple tv' from the summary tab in itunes when the Apple tv is selected in the device menu.
    If it is a secondary library ctrl-click/right-click on the Apple tv in the device list and choose 'turn off streaming' from the contextual menu that appears.
    (Please excuse my unsupported nomenclature)
    Message was edited by: Winston Churchill

  • TS1398 My wifi signal in my iphone 4 is very poor it wasn't the same before. When ever I try to play video it stopes streaming. I hope apple has an answer for this.

    I do not experience any problem browsing Internet or using social networks via wifi but whenever I play a video from YouTube or any other source it stopes streaming after playing 10 to 15 sec video, doesn't matter how close I am from the homehub or which Internet provider I am using. Recently I am experiencing that my phone became slow after installing the new iOS 6.1.2. Application takes time to open. Sometimes application closes on there won without any command. The key l board became slower. I wish I could get the previous version of iOS which was perfect for my iPhone 4.

    Try:
    - Reset the iOS device. Nothing will be lost       
    Reset iOS device: Hold down the On/Off button and the Home button at the same time for at
    least ten seconds, until the Apple logo appears.
    - Unsync/delete all music and resync
    - Reset all settings                  
    Go to Settings > General > Reset and tap Reset All Settings.
    All your preferences and settings are reset. Information (such as contacts and calendars) and media (such as songs and videos) aren’t affected.
    - Restore from backup. See:                                                
    iOS: Back up and restore your iOS device with iCloud or iTunes
      - Restore to factory settings/new iOS device.

  • HT2463 Why does my apple tv play one song then stops streaming?

    Why does my apple tv play one song then stops streaming?

    Make sure all of your songs have a checkmark next to the song title. There are small blue boxes that need to be checked for songs to play consecutively.
    If the library is unchecked, you can easily recheck things by clicking on a song, going to the top line selecting Edit>Select All, then right clicking on the selection and choosing "Check Selection".

  • How to release camera after stop streaming to FMS

    When stop streaming, i close NetStream, close NetConnection, clear video, and remove any event listoner on camera. After these actions, the camera is still in used. What's the problem?
    thanks.

    Hi, you drop connection to the web camera by issuing either vid.attachCamera(null); or vid.attachVideo(null); command.

  • Stop streaming when a popup is created

    Hello,
    I've just installed a button on my flash player that, when clicked, a popup window of said flash player appears.
    Everything works but I have one wee problem. When I click for the Flash player to popup, the existing player in the original window continues streaming the video. Until the video has completely streamed in the existing window, the popup window does not start streaming.
    Some of the vids are quite large, forexample taking about 5 mins for the download on the existing page, and then another 5 mins in the popup, which the customer is not at all happy with.
    Is there anyway I can stop the existing player streaming when a popup is created? I think I could move the slider to 100% but can't workout how to do this
    My code for the popup button is (in AS3):
    public function doublePopup(event:Event = null):void
                if (player)
                    var jscommand:String = "window.open('/flash_popup.php','win','height=600,width=695,toolbar=no,scrollbars=no');";
                    var url:URLRequest = new URLRequest("javascript:" + jscommand + " void(0);");
                    navigateToURL(url, "_self");
    Thanks!

    Start Firefox in [[Safe Mode]] to check if one of your add-ons is causing your problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    * Don't make any changes on the Safe mode start window.
    See [[Troubleshooting extensions and themes]] and [[Troubleshooting plugins]]
    If it does work in Safe-mode then disable all your extensions and then try to find which is causing it by enabling one at a time until the problem reappears.
    * Use "Disable all add-ons" on the [[Safe mode]] start window to disable all extensions.
    * Close and restart Firefox after each change via "File > Exit" (Mac: "Firefox > Quit"; Linux: "File > Quit")

Maybe you are looking for