FrameMaker Mif

20 pts.
Tags:
ACII
FrameMaker
MIF
I wrote a program to easily create a FrameMaket MIF file using Word-VBA. In a way the MIF file is not understood by FrameMaker. However if I do a line by line compare with the equivalent FrameMaker, MIF file created by FrameMaker itself there seems to be no differences. Anyone familiar with this problem?


Software/Hardware used:
Sub makeframeref() Dim i, j As Integer Dim myRange Dim strInput Dim strPage Selection.EndKey Unit:=wdStory Selection.TypeText Text:="" Selection.TypeParagraph Selection.TypeText Text:=" 0 ReadFrameDataAtOnce "D:\FrameAutomation\InsertPDFRefTemplate.txt" With ActiveDocument.Range.Find .Text = "[ID]" .Replacement.Text = j - 1 .Execute Replace:=wdReplaceAll End With With ActiveDocument.Range.Find .Text = "[PAGE]" .Replacement.Text = strPage .Execute Replace:=wdReplaceAll End With With ActiveDocument.Range.Find .Text = "[PDF]" .Replacement.Text = strInput .Execute Replace:=wdReplaceAll End With j = j + 1 strInput = ActiveDocument.Tables(1).Cell(j, 1).Range.Text strInput = Left(strInput, Len(strInput) - 2) strPage = ActiveDocument.Tables(1).Cell(j, 2).Range.Text strPage = Left(strPage, Len(strPage) - 2) Wend Selection.EndKey Unit:=wdStory Selection.TypeText Chr(13) & ">" & Chr(13) & "" & Chr(13) & "" & Chr(13) & ">" Next i Selection.TypeText ">" & Chr(13) & ">" WriteTofile KLAAR: End Sub Sub ReadFrameDataAtOnce(fileName As String) Dim textData As String, fileNo As Integer fileNo = -1 textData = "" fileNo = FreeFile 'Get first free file number Open fileName For Input As #fileNo textData = Input$(LOF(fileNo), fileNo) Selection.EndKey Unit:=wdStory Selection.TypeText textData Close #fileNo End Sub
1

Answer Wiki

Thanks. We'll let you know when a new response is added.

ALready solved it. Sometimes it is simple. I used <MIFFFILE as tagname, where it should be <MIFFFile. So it is case sensitive.
Dsicussion closed.

Discuss This Question:  

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following

Share this item with your network: