Ejemplo n.º 1
0
        private void GetGifStreamFromHttp(Uri uri)
        {
            try
            {
                var webReadState = new WebReadState();
                webReadState.memoryStream       = new MemoryStream();
                webReadState.webRequest         = WebRequest.Create(uri);
                webReadState.webRequest.Timeout = 10000;

                webReadState.webRequest.BeginGetResponse(WebResponseCallback, webReadState);
            }
            catch (SecurityException)
            {
                CreateNonGifAnimationImage();
            }
        }
Ejemplo n.º 2
0
        private void GetGifStreamFromHttp(Uri uri)
        {
            try
            {
                var webReadState = new WebReadState();
                webReadState.memoryStream = new MemoryStream();
                webReadState.webRequest = WebRequest.Create(uri);
                webReadState.webRequest.Timeout = 10000;

                webReadState.webRequest.BeginGetResponse(WebResponseCallback, webReadState);
            }
            catch (SecurityException)
            {
                CreateNonGifAnimationImage();
            }
        }