T.R | Title | User | Personal Name | Date | Lines |
---|
563.1 | not what you asked... | CHRLIE::HUSTON | | Fri Apr 24 1992 15:06 | 6 |
|
I know this is not what you asked for, but would a MAC interface to
the IOS file cabinet help?
--Bob
|
563.2 | Yes | BIGUN::BRUCE | | Mon Apr 27 1992 00:37 | 6 |
| Yes, a MAC interface to the IOS file cabinet would be a great help.
Any chance of getting one within the next two months? :-)
Malcolm
|
563.3 | script to cycle through folder | RUNAWY::NTTDA::MENARD | | Mon Apr 27 1992 18:00 | 49 |
| The attached script cycles through a particular folder and creates files in TXT
and WPL format in predetermined diretories. You'll have to add code to build
the subdirectories on the fly and to cycle through all folders in file cabinet.
!
! Select folder; default to current folder
!
GET #SEARCH_FOLDER = OA$CURDOC_FOLDER
FORM SELECT_FOLDER
.IF OA$FORM_DISPOSE EQ 0 THEN .EXIT
.IF #SEARCH_FOLDER EQS "" THEN .EXIT
GET #COMPARE_FOLDER = #SEARCH_FOLDER
!
! Select output Destination
!
GET #VMS_TEXT_DIR = "APPLICATIONS:[PROPOSALS_DEV.CONTENT.TXT]"
GET #VMS_WPL_DIR = "APPLICATIONS:[PROPOSALS_DEV.CONTENT.WPL]"
!
! Make the first document in the selected file the current file
!
CABINET SELECT #SEARCH_FOLDER,,,
GET #TOP_DOC = OA$CURDOC
!
.LABEL COPY_NEXT
!
GET OA$DISPLAY = OA$CURDOC_TITLE
FORCE
!
! Create the text version
!
GET #VMSFILE = #VMS_TEXT_DIR OA$CURDOC_TITLE ".TXT"
COPY OA$CURDOC_FILENAME #VMSFILE
!
! Create the WPL version
!
GET #VMSFILE = #VMS_WPL_DIR OA$CURDOC_TITLE ".WPL"
GET OA$DCL = "COPY " OA$CURDOC_FILENAME " " #VMSFILE
!
! Check for end of folder; if not end go to beginning of loop
!
CABINET NEXT_DOCUMENT #TOP_DOC
.IF OA$CURDOC_FOLDER NES #COMPARE_FOLDER THEN .GOTO EXIT_IT
.GOTO COPY_NEXT
.LABEL EXIT_IT
DISPLAY "FINI"
.EXIT
|
563.4 | script to remove spaces from tiitle | RUNAWY::NTTDA::MENARD | | Mon Apr 27 1992 18:12 | 38 |
| This command procedure will remove spaces from a title so that you can make a
valid VMS file name. Use symbols to pass the title back and forth from a script.
You may have to hack a little to get it to work like you want, but at least it's
a start.
RAM
$!------------------------------------------------------------------------------
! Purpose:
$! The purpose of this command file is to take the title of the current
$! WPL document and create the filename of the document to be transfered.
$!
$!------------------------------------------------------------------------------
$ NEW_TITLE = ""
$! Title is parameter P1
$ COPY_TITLE = P1
$ COPY_TITLE_LEN = F$LENGTH(COPY_TITLE)
$ SEARCH_STRING:
$!
$! Search throught the string searching for blanks. When one is found, take the
$! text preceding it and add to already created title. An occurence of a blank
$! will be replaced with an underscore. Continue until end of string.
$!
$ BLANK_LOC = F$LOCATE(" ", COPY_TITLE)
$ NEW_TITLE = NEW_TITLE + F$EXTRACT(0,BLANK_LOC,COPY_TITLE)
$ NEW_COPY_TITLE = F$EXTRACT(BLANK_LOC+ 1, COPY_TITLE_LEN-BLANK_LOC, COPY_TITLE)
$ COPY_TITLE = NEW_COPY_TITLE
$ COPY_TITLE_LEN = F$LENGTH(COPY_TITLE)
$ IF COPY_TITLE_LEN .EQ. 0 THEN GOTO FINISH_AND_EXIT
$ NEW_TITLE = NEW_TITLE + "_"
$ GOTO SEARCH_STRING
$ FINISH_AND_EXIT:
$! Create the entire destination spec and copy the file to it
$ DEST_SPEC = P3 + NEW_TITLE + ".WPL"
$ COPY 'P2' 'DEST_SPEC'
$ EXIT
|
563.5 | What's different? | SHALOT::NICODEM | Who told you I'm paranoid??? | Mon Apr 27 1992 23:42 | 3 |
| RE: .4
Is there a reason you didn't simply use the MAKE_FILE_NAME function?
|
563.6 | ignorance | DEVOTN::NTTDA::MENARD | | Tue Apr 28 1992 17:44 | 1 |
| re: -1 in my defense, I didn't write .4! MAKE_FILE_NAME is definitely the way to go!!
|