NetTalk Central

Author Topic: Where to check if file upload has failed?  (Read 5642 times)

Mike McLoughlin

  • Full Member
  • ***
  • Posts: 126
    • View Profile
    • Clarion Templates
    • Email
Where to check if file upload has failed?
« on: February 03, 2010, 03:38:42 PM »
I'm using the File Upload field type in NTWS 4 - where I can check if the file upload actually completed successfully?

I guess somewhere in WebHandler?

regards

Mike
Mike McLoughlin

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Where to check if file upload has failed?
« Reply #1 on: February 04, 2010, 09:12:23 PM »
How will you know if it completed correctly?
I mean, what about the incoming file will tell you that it's "complete"?
I'm not sure how the _server_ will be able to tell the difference between a complete and incomplete submission.
hmm - as I say, not sure.

Actually I'm not terribly sure you have to do anything. Off the top of my head I'd say that if the user gets a page back then it completed. If not, then probably not.

Cheers
Bruce

Mike McLoughlin

  • Full Member
  • ***
  • Posts: 126
    • View Profile
    • Clarion Templates
    • Email
Re: Where to check if file upload has failed?
« Reply #2 on: February 06, 2010, 04:08:59 AM »
I'm keeping a log of files uploaded by users and it would be very handy to mark an upload as 'Failed' - it would cut down support massively if they were stopped from clicking to download files that weren't there.

Mike
 
Mike McLoughlin

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Where to check if file upload has failed?
« Reply #3 on: February 06, 2010, 11:38:37 AM »
use the Clarion EXISTS command to see if a file exists.

cheers
Bruce

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Re: Where to check if file upload has failed?
« Reply #4 on: February 08, 2010, 11:20:28 PM »
Mike
Disable the download button if the file doesn't exist. I have some code that works if it will help.
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186

Mike McLoughlin

  • Full Member
  • ***
  • Posts: 126
    • View Profile
    • Clarion Templates
    • Email
Re: Where to check if file upload has failed?
« Reply #5 on: February 11, 2010, 07:22:42 AM »
Yes I'd like to see that

thanks

Mike
Mike McLoughlin

terryd

  • Hero Member
  • *****
  • Posts: 759
    • View Profile
    • Davcomm
    • Email
Re: Where to check if file upload has failed?
« Reply #6 on: February 13, 2010, 08:02:59 AM »
Sorry about the delay. salt to taste iro variables

[attachment deleted by admin]
Terry Davidson
Windows 10 64 bit/Windows7 64bit
Clarion 9.1.11529/Clarion10 12567
Nettalk 913
Nettalk 1015
StringTheory267/Winevent515/XFiles298/MessageBox239/Cryptonite186