Skip to main content
Known Participant
September 16, 2010
Question

FMS 3.5 where is the Client.getStreamLength()

  • September 16, 2010
  • 1 reply
  • 862 views

Hi,

I have a server side script, what contains the Client.getStreamLength() function, but since I have to upgrade that from 3.0 to 3.5 the function not works. How get I the stream name from the Client object in FMS 3.5? NetConnection.call not works, because I use FLVPlayback on the client side, and I don't manipulate the Connection's data (I don't send the stream name from client to server)

Thank's!

    This topic has been closed for replies.

    1 reply

    Participating Frequently
    September 16, 2010

    As far i remember that was no function defined on Client object named getStreamLength by default. It must be user-defined function in custom SSAS something like Client.prototype.getStreamLength.

    Can you tell me is this your own custom application or one of Adobe's apps.

    tomipontAuthor
    Known Participant
    September 17, 2010

    Hi,

    On FMS 3.0 this code have to work:

    p_client.getStreamLength = function( streamName )

    {

         p_client.stream = streamName;

    }

    Here in the doc: http://www.adobe.com/livedocs/flashmediaserver/3.0/hpdocs/help.html?content=00000264.html

    I need some alternative solution...

    Thank's

    Participating Frequently
    September 17, 2010

    Looks like you are right, i don't see it in 3.5 docs but see them in 3.0 docs. I will check whether support for this was removed or something.

    Meanwhile you can always get length of the stream by using Stream.length().

    You just code your own custom function like Client.prototype.getStreamLength, something like below

    Client.prototype.getStreamLength = function(name){

         return Stream.length(name);

    }

    If you are still not getting on how to get it work - can you pass your scripts - Server-side and client-side.