Search The ForumSearch   RegisterRegister  LoginLogin

MailBee Objects

 AfterLogic Forum : MailBee Objects
Subject Topic: Message.SaveMessage filepath max length Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
David Poirier
Guest Group
Guest Group


Joined: 10 November 2003
Online Status: Online
Posts: 262
Posted: 27 June 2005 at 10:12pm | IP Logged Quote David Poirier

What is the maximum allowable length of the FilePath param of the Message.SaveMessage method supposed to be? I am having problems saving messages to file when the path is longer than 258 chars.
Back to Top View David Poirier's Profile Search for other posts by David Poirier
 
Alex
AfterLogic Support
AfterLogic Support
Avatar

Joined: 19 November 2003
Online Status: Offline
Posts: 2206
Posted: 28 June 2005 at 8:43am | IP Logged Quote Alex

Maximum length of a file path allowed by WinAPI functions is MAX_PATH=260 chars (including null terminator). You cannot use longer file paths.

Regards,
Alex
Back to Top View Alex's Profile Search for other posts by Alex
 
David Poirier
Guest Group
Guest Group


Joined: 10 November 2003
Online Status: Online
Posts: 262
Posted: 29 June 2005 at 11:19pm | IP Logged Quote David Poirier

What about using the Unicode versions of the WinAPI functions? These will let you use paths up to 32000+ chars.

http://msdn.microsoft.com/library/default.asp?url=/library/e n-us/fileio/fs/createfile.asp
Back to Top View David Poirier's Profile Search for other posts by David Poirier
 
Alex
AfterLogic Support
AfterLogic Support
Avatar

Joined: 19 November 2003
Online Status: Offline
Posts: 2206
Posted: 30 June 2005 at 10:00am | IP Logged Quote Alex

MailBee Objects cannot rely on Unicode functions since they are not fully supported in Win9X.

Regards,
Alex
Back to Top View Alex's Profile Search for other posts by Alex
 
David Poirier
Guest Group
Guest Group


Joined: 10 November 2003
Online Status: Online
Posts: 262
Posted: 30 June 2005 at 8:14pm | IP Logged Quote David Poirier

I believe this could be overcome by detecting what version of Windows you're running on, and using the the appropriate function.
Back to Top View David Poirier's Profile Search for other posts by David Poirier
 
Alex
AfterLogic Support
AfterLogic Support
Avatar

Joined: 19 November 2003
Online Status: Offline
Posts: 2206
Posted: 01 July 2005 at 9:08am | IP Logged Quote Alex

In theory, long paths are supported by WinAPI. However, in real world situations, long paths do not work in the most cases. For example, .NET framework itself does not support long paths even on WinNT/2000/XP/etc. Since we have to retain compatibility with .NET, we will not add any features which cannot be supported by upcoming native .NET versions of MailBee.

Regards,
Alex
Back to Top View Alex's Profile Search for other posts by Alex
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump

Powered by Web Wiz Forums version 7.9
Copyright ©2001-2004 Web Wiz Guide