Sign up on the Revelation Software website to have access to the most current content, and to be able to ask questions and get answers from the Revelation community

At 23 MAY 2004 05:14:56PM Terry Rainville wrote:

I am looking for someone to help me out with a small executable

that will read long file names.

Basicly what is needed:

1) My arev program will do dirlist to determine files exist

in a directory.

2) I will then run the executable from arev using suspend

inorder to rename the long file names.

Executable

1) read files from a given directory (directory is hard coded)

2) rename the files to a 8 charcter name with 3 character extention

If you can help me out please get back to me here or :

trainville@jbellis.com

or (604) 408-7167 (pacific standard time)


At 24 MAY 2004 02:20PM Ralph Johler wrote:

At 24 MAY 2004 05:07PM Terry Rainville wrote:

I should mention I have looked at the documents already on this site about long file names and they sound promissing except for one detail.

In the long file name the first 12-18 characters are going to be a key value that I need to extract from the name before renameing the

file. Therefore getting the alias name with a ~ tilda is not going to do me any good, I need to have a executable that will actually be

able to extract those exact characters.

Once grabbed the characters will be stored in a file named exactly the same as the current file which will be renamed.

here is a example.

file=123456789012345.20030919-093056.tif

File will be renamed in same directory as 1234.tif

another file in different directory will be created as 1234.txt

this file will contain 123456789012345 as data.


At 24 MAY 2004 05:14PM Matt Sorrell wrote:

Terry,

What about shelling out, performing a "DIR" command redirected to a file, like this:

DIR ] dirlist.txt

Then, your program can read and parse the dirlist.txt file. It has a fixed column format, so it should be pretty easy to read in. Naturally, you can filter the DIR command so you don't have to parse as much, if necessary.

msorrel@greyhound.com

Greyhound Lines, Inc.


At 24 MAY 2004 07:36PM Terry Rainville wrote:

Thanks for the sugestion, I actually already thought of this and am currently composing a system diagram to put it into use.

Only one problem though which you may be able to solve for me.

If I run a DIR command to a file from a suspended arev session it only gives me the truncated names.

SUSPEND DIR F:\TEMP ] TEST.TXT

Files show as 12345678.tif

if I run a DIR command from a dos prompt.

DIR F:\TEMP ] TEST.TXT

Files show as 1234567890123456.20040520-235910.tiff

So currently becuase of this I am letting the users start of the whole

process by running a batch file which gives me the proper dos listing.

If I can find a way of getting the proper dos listing thru a AREV shell then I can make it a AUTO process instead of getting a user

to start it.


At 25 MAY 2004 10:52AM Matt Sorrell wrote:

Terry,

If I perform the following command:

SUSPEND EXIT DIR C:\ ] C:\DIRLIST.TXT

and then look at the file, the first column is in 8.3 format, while the last column shows the LFN version. I am running on Windows 95, with ARev 3.02.

msorrel@greyhound.com

Greyhound Lines, Inc.


At 25 MAY 2004 07:12PM Terry Rainville wrote:

Sorry Mat I just tried it on a DOS computer no windows installed

and I still only get the first 8.3 column.

No long names. Perhaps it has to do with the version of novell

or something like that. We are currently running Novell 3.12.

The computer I was attempting it on previously was Win2000.

but I get same resaults.

Anyway If you can figure it out that would be great I am still going to attempt to get this working somehow.


At 26 MAY 2004 11:39AM Jared Lessl wrote:

Right, the "dir ] file" trick only works on 9x, maybe ME as well. NT, 2k, and XP are no good.

What you might try would be to write a small standalone DOS program that does the same job. For instance, AREV doesn't know how to move files, so we wrote a program mv.exe that acts just like move. Pass in the source and dest. filenames as parameters and AREV never knows the difference.


At 26 MAY 2004 12:06PM support@sprezzatura.com wrote:

You could use the /X DIR modifier to get both on more modern OSs.

support@sprezzatura.com

The Sprezzatura Group Web Site

World Leaders in all things RevSoft


At 26 MAY 2004 02:11PM Terry Rainville wrote:

Thank you all for your input

I believe I found the solution.

If you create a BAT file and execute it from AREV using

SUSPEND EXIT CMD /C START

the arev shell seems to release itself to a regular dos session

becuase the commands within the BAT file now work correctly.

Credit goes to Ralph Johler on this one for his input on

05/07/04 (Search=Long Filename) about oswriteing to

a RENAME.BAT file. Basicly you rewrite the BAT file everytime

you want to rename a file.


At 27 MAY 2004 09:06AM Matt Sorrell wrote:

Terry,

Well, you also need to make sure that the version of Novell you are using supports LFN, and that LFN support is turned on.

msorrel@greyhound.com

Greyhound Lines, Inc.

View this thread on the forum...

  • third_party_content/community/commentary/forums_nonworks/4fa1744f2685d38b85256e9d0074b94c.txt
  • Last modified: 2023/12/28 07:40
  • by 127.0.0.1