David McGehee wrote: > > Microsoft Server2003 jbase 4.1 environment. We need a > > different method of making http: connections from > > jBase. We are currently using a CALLC custom-written > > interface for which we no longer have the code.
From: Jim Idle > The easiest way is to EXECUTE an external program > (curl is good: http://curl.haxx.se/download.html and > works on WIndows), redirect the output to a file, then > read in the file. > > There is also a C library version of it and if it has > string input and output then you can make a DEFC for > it (or maybe get CALLC to work) and just call it like > your old custom code. It would be trivial to create a > CALLC wrapper for it though. This is both a suggestion as well as an inquiry: I've used cURL for various projects. It's well supported, very popular, and if you don't mind the execute/capture method, it a good option. The library "libcurl" that Jim mentions can be tough to use though there are bindings for many languages - so you can write your client code in C, PHP, or Java for example, and still make use of cURL if you like the way it works. This same library gets you HTTP plus FTP and other protocols. I'm not sure of the demographics of jBASE developers but most MVBASIC developers that I know have C just one step up from assembler, both at the very bottom of the list of tools that they're inclined to use. So CALLC is an effective option that may be out of reach for most. There are many examples of Java HTTP clients around, so CALLJ may be higher on the list of preferable options. There is also CALLDOTNET, since David is on Windows. It's relatively easy to write a .NET HTTP client, including for web services, and again, this is well documented with lots of examples on the 'net. [ I can do this as a service and provide the source, as long as you promise not to lose it. :) ] According to the BASIC manual, .NET code will bind the first time it's executed but there is only an initialization performance penalty, and subsequent operations should be as fast as the transfer itself. I don't know if this true for CALLJ. Anyone? Java has an advantage in that you can use almost the same code on any OS, but from what I've read it seems a bit tougher to implement. And coming back to ease of development, with .NET you have your choice of over 30 languages, though VB.NET and C# are most preferred by BASIC developers. So given all of that, are there any reasons not to use CALLDOTNET or CALLJ? Technical preferences? (Not philosophical, technical...) Tony Gravagno Nebula Research and Development TG@ remove.pleaseNebula-RnD.com Nebula R&D sells mv.NET and other Pick/MultiValue products worldwide, and provides related development and training services --~--~---------~--~----~------------~-------~--~----~ Please read the posting guidelines at: http://groups.google.com/group/jBASE/web/Posting%20Guidelines IMPORTANT: Type T24: at the start of the subject line for questions specific to Globus/T24 To post, send email to [email protected] To unsubscribe, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/jBASE?hl=en -~----------~----~----~----~------~----~------~--~---
