Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Batch Process Frame 7 to 6

Status
Not open for further replies.

pmidwest

Programmer
Jan 9, 2002
162
0
0
US
Is there anyway to run a batch process to save Structured Frame 7 files as Frame 6?
I know you can open the file and do a save as then change it to Frame 6 but we have about 2,000 files that need to be converted. Any help would be greatly appreciated.

Thank you

Paul
 
Hi!

F_ApiSave allows to set a FS_FileType property to FV_SaveFmtBinary60 which notifies to API that a document should be saved as FrameMaker 6.0 binary. Never tried it, but it sounds promising. Let me know.

Kerlin
 
Yeah... I have no clue what you just said Hehe... sorry, I don’t work with Frame we are a technical publications company and the writers use frame 7 but in order for us to convert the files to XML we have to first convert them back to Frame 6 and you can imagine how long it takes to file save as on 1000 files. But as I said I don’t know anything about Frame so if that’s like a setting I need to change or something could you please be a bit more specific as to what it is I should do?

Thanks a lot for your time

Paul
 
Sorry, I thought you were an FDK programmer. The solution I talked about means writing a Frame API client. The client with the functionalities you need could be written in a couple of hours or so. I ignore however if off-the-shelf solutions are readily available.

Kerlin
 
Just out of curiosity, why do you need to convert 7 files to 6 to be able to convert to XML. 7 has better XML support than 6

Mark

If sunflower oil comes from sunflowers, and vegetable oil comes from vegetables, where does baby oil come from?
 
We are useing Webworks 7.0 I think and it wont work with the frame 7 files
 
Ok I've gotten it to run the script and it saves the files as frame 6 like I needed only problem is every time it opens a file the script stops untill I click on "ignore missing graphics"

here part of the scrip I've made

Sub OpenAndSaveIt using pvDocFileName

Local lvDocVar lvAlreadyOpen(False);

Set lvDocVar = eDocUtils.DocIsOpenAlready{pvDocFileName};
If lvDocVar = 0
Set lvAlreadyOpen = False;
Set ErrorCode = 0;
Open Document File(pvDocFileName) Invisible FileIsOldVersion FontNotFoundInDoc NewVar(lvDocVar);
If ErrorCode not 0
Display 'Error Opening Document-'+pvDocFileName+' Msg-'+ErrorMsg;
EndIf
Else
Set lvAlreadyOpen = True;
EndIf

If lvDocVar not = 0
Local lvOutFileName;
Set lvOutFileName = eSys.RemoveFileExtension{pvDocFileName,'.fm'};
Set ErrorCode = 0;
Save Document DocObject (lvDocVar) File(lvOutFileName) FileType(SaveFmtBinary60);
If ErrorCode not = 0
Display 'Save to PDF Failed errorcode='+ErrorCode+' Msg='+ErrorMsg;
Else
Write console 'Document ('+pvDocFileName+') saved as '+lvOutFileName;
Set gvPdfFileCount = gvPdfFileCount + 1;
EndIf
If lvAlreadyOpen = False
Close Document DocObject(lvDocVar) IGNOREMODS;
Set lvDocVar = 0;
EndIf
EndIf

EndSub

is there any way to code into the script to make it auto ignore missing graphics?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top