![]() |
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) Example: Http.QuickGetSb methodDemonstrates the
integer li_rc integer li_Success oleobject loo_Http oleobject loo_Sb li_Success = 0 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 // Send the HTTP GET and return the content in a StringBuilder loo_Sb = create oleobject li_rc = loo_Sb.ConnectToNewObject("Chilkat.StringBuilder") li_Success = loo_Http.QuickGetSb("https://www.chilkatsoft.com/helloWorld.json",loo_Sb) if loo_Http.LastMethodSuccess = 0 then if loo_Http.LastStatus = 0 then // Communications error. We did not get a response. Write-Debug loo_Http.LastErrorText else Write-Debug "Response status code: " + string(loo_Http.LastStatus) Write-Debug "Response body error text:" Write-Debug loo_Sb.GetAsString() end if destroy loo_Http destroy loo_Sb return end if // The downloaded content: Write-Debug loo_Sb.GetAsString() Write-Debug "Success" destroy loo_Http destroy loo_Sb |
© 2000-2025 Chilkat Software, Inc. All Rights Reserved.