--- Craig Hoyt <[EMAIL PROTECTED]> wrote:

> In my current project I incorporate a check for updates and the
>  
> ability to download an update via HTTPSocket. When testing
> earlier I  
> used a small text file. Now I've posted the actual file in zip 
> 
> format. My FTP client shows the file as a PC zip archive and is
> the  
> correct size. When I download through my app the file is
> received but  
> is seen as a text file and not a zip file. Changing the opening
> app  
> in 'Get info' fixes it (shows correct icon and double clicking
> will  
> decompress). Otherwise it just opens in 'TextEdit'. The file
> does  
> have it's '.zip' extension. I am not explicitly defining
> encodings  
> for the download - do I need to do this? Anybody know of a way
> to get  
> the download to come in properly?

You're passing a FolderItem variable to HTTPSocket for the
download, right? After the download is complete, set MacType and
MacCreator on the FolderItem to the proper values for the file
you're downloading.  If you're having trouble finding the right
type and creator codes, try setting each of them to 

  chr(0) + chr(0) + chr(0) + chr(0)

That's off the top of my head, so take it as more guess than
guru, but it shouldn't take more than a couple minutes of playing
to see if it's going to work or not.


Mark Nutter

Quick and easy regex creation and debugging!
http://www.bucktailsoftware.com/products/regexplorer/

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to