![]() |
Chilkat HOME Android™ AutoIt C C# C++ Chilkat2-Python CkPython Classic ASP DataFlex Delphi DLL Go Java Node.js Objective-C PHP Extension Perl PowerBuilder PowerShell PureBasic Ruby SQL Server Swift Tcl Unicode C Unicode C++ VB.NET VBScript Visual Basic 6.0 Visual FoxPro Xojo Plugin
(PowerBuilder) S3 Delete Multiple ObjectsDemonstrates how to delete multiple objects in a single HTTP request. Note: This example requires Chilkat v11.0.0 or greater.
integer li_rc integer li_Success oleobject loo_Http string ls_BucketName string ls_ObjectName1 string ls_ObjectName2 string ls_ObjectName3 oleobject loo_St oleobject loo_Resp li_Success = 0 // This example requires the Chilkat API to have been previously unlocked. // See Global Unlock Sample for sample code. loo_Http = create oleobject li_rc = loo_Http.ConnectToNewObject("Chilkat.Http") if li_rc < 0 then destroy loo_Http MessageBox("Error","Connecting to COM object failed") return end if // Insert your access key here: loo_Http.AwsAccessKey = "ABQXXABC83ABCDEFVQXX" // Insert your secret key here: loo_Http.AwsSecretKey = "XXXXYYYYabcdABCD12345678xxxxyyyyzzzz" ls_BucketName = "chilkattestbucket" ls_ObjectName1 = "starfish.jpg" // Delete a particular version of this object: ls_ObjectName2 = "conch.jpg; VersionId=~"3/L4kqtJlcpXroDTDmJ+rmSpXd3dIbrHY+MTRCxf3vjVBH40Nr8X8gdRQBpUMLUo~"" ls_ObjectName3 = "seaUrchin.jpg" loo_St = create oleobject li_rc = loo_St.ConnectToNewObject("Chilkat.StringTable") loo_St.Append(ls_ObjectName1) loo_St.Append(ls_ObjectName2) loo_St.Append(ls_ObjectName3) loo_Resp = create oleobject li_rc = loo_Resp.ConnectToNewObject("Chilkat.HttpResponse") li_Success = loo_Http.S3_DeleteObjects(ls_BucketName,loo_St,loo_Resp) if li_Success = 0 then Write-Debug loo_Http.LastErrorText destroy loo_Http destroy loo_St destroy loo_Resp return end if // Display the JSON response. Write-Debug loo_Resp.BodyStr destroy loo_Http destroy loo_St destroy loo_Resp |
© 2000-2025 Chilkat Software, Inc. All Rights Reserved.