UploadControlAmazonSettings Class
Contains settings that allow you to connect the Upload Control to Amazon Simple Storage Service (Amazon S3).
Namespace: DevExpress.Web
Assembly: DevExpress.Web.v24.2.dll
NuGet Package: DevExpress.Web
#Declaration
public class UploadControlAmazonSettings :
UploadControlUploadStorageSettingsBase
#Related API Members
The following members return UploadControlAmazonSettings objects:
Library | Related API Members |
---|---|
ASP. |
ASPx |
ASPx |
|
ASP. |
Html |
Upload |
|
Upload |
#Remarks
Follow the steps below to connect the Upload Control to Amazon:
- Call the RegisterAmazon method in the Global.asax file.
- Set the Upload Control’s UploadStorage property to
Amazon
. - Assign an Amazon account’s name to the AmazonSettings.AccountName property.
- Assign a bucket name to the AmazonSettings.BucketName property.
Important
The Amazon
The following example demonstrates how to connect the Upload Control to Amazon Simple Storage Service:
void Application_Start(object sender, EventArgs e) {
DevExpress.Web.AccountManager.RegisterAmazon("YourAmazonAccount","YourAccessKeyID","YourSecretAccessKey");
}
<dx:ASPxUploadControl ID="UploadControl" runat="server" UploadStorage="Amazon" ShowUploadButton="True" >
<AmazonSettings AccountName="YourAmazonAccount" BucketName="YourBucketName" Region="us-east-1" />
</dx:ASPxUploadControl>
Once the Upload Control uploads a file to cloud storage, you can use the key name of this file to access it. To obtain a file key name, use the FileNameInStorage property of an UploadedFile object.