I have one download URl,
How to download file from this url in c# Code . wp8 .
and This file may be store in external storage not be use isolated storage because file is so large Please Help
Use HttpClient for downloading files, see sample here.
Also, you must use IsolatedStorage since you don't have external storage available to you. Also, consider using Windows.Storage instead of IsolatedStorage.
Related
Please can you help me understand? Is it possible to use the Azure SAS URL to download Blob(all files) once from Azure Blob Storage into Browser?
I mean can the user click generated SAS URL and it will download all files into my Browser as a Folder?
The problem that I have some time I have very large files I make them ZIP and want to put them into Azure Blob storage and give the user URL to click and download it as Folder ZIP, not as file one by one.
Or if you have another suggestion please let me know, if there are some solutions to do code level I can do it via C#.
Any help will be appreciated.
I can't download the azure blob using sas URL. I'm new in this space, if you have another solution in this case or another way please let me know. Thank you :)
You could do this in 2 steps:
Firstly, run a program that takes all the files in a blob storage container and places them in a zip file, store that zip file in another container.
Then give the user a SAS URL to that file.
Is there any way to upload a PDF file that is on my local computer in a way where anyone can retrieve the PDF?
If I do something like
var filename = #"c:\test.pdf";
m.Attachments.Add(new Attachment(filename));
Anyone who goes onto the website has to have the same local path and same test.pdf file in the correct place (which would be impossible). So is there a way I can go about having to upload the pdf so it's not hard coded with a local path?
There are many ways to upload a file e.g. using an HTTP request and then download a file again using another HTTP request. If you just need to download files (no other API endpoints), consider using blob storage like AWS S3 bucket, Azure Blob Store or equivalents of other providers directly and configure the access rules in such a way that public read access is possible. To download the file in your program you then just need an instance of HttpClient and make a request to your blob store.
If you want to upload files through ASP.NET have a look at the Microsoft docs which describe all things to be considered in detail. You will still need to store the file somewhere when using this approach. Either on disk of the server you run the application on or again a blob store (and there are of course other possibilites).
I am going to upload my files from local PC to OneDrive using c#, I would need how to check the file existance before upload them.
Please suggest any has algorithm which is using by One Drive.
I have tried to create XORHash but it different.
For my scenario, our current app is begin coded in html5 and angularjs communicating with web api. I have a workflow scenario that I seem to not be able to find an end to end example for. I would like to allow users of my website to upload videos and images to Azure Media Services. I found several examples that seem to move the data from a web page to blob storage and then copy over to azure media services.
Is there a way to upload the file directly to Media Services, instead of having a temporary and permanent blob container(one tied to AMS), as this approach seems to force me to have an additional storage container or is there a way to move the file to blob storage followed by linking the blob file to AMS via IAssetFile?
Can someone provide an end example that demonstrates the flow from web frontend upload to the file ending up in AMS?
Once up there, is there a way to make sure users can view but not download videos?
1.Is there a way to upload the file directly to Media Services:
The Media Services SDK requires you to first create an Asset object in our system. That Asset object is backed by a container in Storage. You can create an empty Asset object, and request a write only SAS URL (We call them "Locators" in our API) to upload your content directly into. You may want to check out this AngularJS module and see if it works. http://ngmodules.org/modules/angular-azure-blob-upload
2.Can someone provide an end example that demonstrates the flow from web frontend upload to the file ending up in AMS?
Your web API/frontend should use the Media Services SDK to create the empty Asset first. Once created, hand create a write only SAS URL and hand that back to your Angular client. The Angular client can then use client side javascript library to upload directly to the blob/container using the SAS URL and a module for azure-blob upload like the one here: http://ngmodules.org/modules/angular-azure-blob-upload
3.Once up there, is there a way to make sure users can view but not download videos?
Once the video is uploaded, you should Delete the Write only SAS "Locator" from your Asset's Locators collection. This way, nobody can use it to write again.
At this point you can create a Streaming Locator. Users will only be able to stream the file through our streaming services. Your file has to be encoded in a format that we can support streaming for, so you may have to first kick off an encoding job to get it into the right format and encoding settings (MP4 files with H264 and AAC audio). If you want to stream from Media Services, you need to make sure you have at least 1 streaming reserved unit enabled on your account. In addition, if you are looking to protect your files, you can take a look at our Content Protection services, which will provide on-the-fly AES 128 or PlayReady DRM encryption to your assets. You can integrate that with JWT tokens and Active Directory to authenticate/auth your users before they are able to decrypt the video on the client side.
I'm not too familiar with Azure Media Services but after looking at this guide http://azure.microsoft.com/en-us/documentation/articles/media-services-rest-get-started/ it appears to me that you can create an asset on Azure Media Services and link it to a blob. This means you'll only have one blob container.
AMS provides Rest API for all media processing capabilities including uploading, encoding, publishing. There is a sample project (postman collection) in GitHub to play around. This sample project is also accompanied by a well-written article. Please find the links below.
https://github.com/Azure-Samples/media-services-v3-rest-postman
https://learn.microsoft.com/en-us/azure/media-services/latest/stream-files-tutorial-with-rest
Hope this will help
I am trying to use Azure Blob Storage as a location for secure file downloads using Shared Access Signature. Everything is working very well, however the problem I am having is I am trying to allow the user to save files from the browser and I have all browsers except IE9 working.
Reviewing this question,
What content type to force download of text response?
this works well when I can control all of the headers, however in Azure Blob Storage, I have set the Content-Type to application/octet-stream and this allows all browsers except IE to ask the user to save the file, IE simply opens the file. It appears that known file types will open (example .jpg, .wmv etc…).
In Azure, I have found no way to set
Content-Disposition: attachment;filename="My Text File.txt"
Is there a way, using Azure Blob Storage, to use IE to download any file directly from Azure Blob Storage?
Thanks in advance.
I don't think there's a way to set the Content-Disposition header in Windows Azure blob storage.
You can now by right clicking the resource - properties.