Xbase++
Xbase++
S3 Delete Bucket
See more Amazon S3 Examples
Demonstrates how to delete a bucket.Chilkat Xbase++ Downloads
LOCAL nSuccess
LOCAL oHttp
nSuccess := 0
// This example assumes the Chilkat API to have been previously unlocked.
// See Global Unlock Sample for sample code.
oHttp := CreateObject("Chilkat.Http")
// Insert your access key here:
oHttp:AwsAccessKey := "ABQXXABC83ABCDEFVQXX"
// Insert your secret key here:
oHttp:AwsSecretKey := "XXXXYYYYabcdABCD12345678xxxxyyyyzzzz"
oHttp:KeepResponseBody := 1
nSuccess := oHttp:S3_DeleteBucket("chilkattestbucket")
IF (nSuccess != 1)
? oHttp:LastErrorText
// Also examine the error response body from AWS:
? oHttp:LastResponseBody
ELSE
? "Bucket deleted."
ENDIF
oHttp:destroy()