Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SendFile inside a TIWCallbackProc3
#2
An Async request initiated by IntraWeb JavaScript code expects to receive a XML response, formatted in a very specific way.

So in theory you can't send a file in an async reponse.

Having said that, it is possible to encode a file as, for instance, a base64 string and send it back as part of your XML packet. Then the calling code should be able to take the response and decode it back. But then you will hit another wall, which is the browser security that won't let your JS code do anything useful with this file (i.e. you won't be able to save it to the user local disk).

If you want to download a file, use one of the well known ways to start a file download and you should be fine.
Reply


Messages In This Thread
SendFile inside a TIWCallbackProc3 - by giorgio_c - 05-30-2023, 03:47 PM
RE: SendFile inside a TIWCallbackProc3 - by Alexandre Machado - 05-31-2023, 10:24 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)