On Oct 27, 9:35*am, "Jon Lewis" <jon.le...@cutthespambtinternet.com>
wrote:
> Can't you get the short file name at runtime to pass to your CopyFile
> procedure whilst keeping the full name stored/displayed?
>
> Jon
>
> "bala" <balk...@gmail.com> wrote in message
>
> news:45a6e5b9-9c49-4e07-af9d-(E-Mail Removed)...
> On Oct 26, 10:42 pm, "Stuart McCall" <smcc...@myunrealbox.com> wrote:
>
>
>
>
>
> > "bala" <balk...@gmail.com> wrote in message
>
> >news:7836c18b-b7b6-4470-bab6-(E-Mail Removed)....
>
> > > Hi,
>
> > > I am using CopyFile (Scripting.FileSystemObject) to copy file from one
> > > location to another. The naming convention followed makes the file
> > > names (+ the path) lenghty and the total characters can exceed 260
> > > characters.
>
> > > I would appreciate if you can let me know if there is any solution to
> > > bypass max limit (Filename + Path) of 260 characters.
>
> > > The copying of file from one location to another happens on the click
> > > of a button in MS Access Forms.
>
> > > Thanks in Advance.
>
> > > Regards
> > > Bala
>
> > Well you can use short file names instead:
>
> >http://www.smccall.demon.co.uk/Strin...ShortPath-Hide quoted text -
>
> > - Show quoted text -
>
> There lies the problem, the clients wants the naming convention to be
> followed and the naming convention does creates long names. Any work
> around?- Hide quoted text -
>
> - Show quoted text -
That is a good suggestion but the client wants the files to be named
according to the naming convention (translated : long name). According
to them they want to identify the nature of the file by glancing at
the name.
What I also tried is using the short dummy name to copy file using
CopyFile and then tried to rename it with the long name but it didn't
work out.
I have search web and couldn't find any solution for it as Windows XP
as a max limit of 260 characters when NTFS file system can handle upto
32,000 char.
To be honest I think the bottom line is as per Stuart and your
suggestion the File Name (inclusive of the Path) have to be restricted
to less than 240 chars (to be on a safer side). A file name (including
Path) with lenght of 253 Chars also created problem.
If there is any work around well it would be nice if not have to start
the long never ending process of convincing the Client.