DotNetGnat
Programmer
Hello All,
Ok, I will try my best to describe my problem.
I have a VB macro that modifies a word document. Everything works fine.
I needed some specific image, text and page number alignment in the footer.But the alignment is currently skewed. If the text is smaller in length...alignment of image, text and page number works fine...but this gets skewed if the text is longer. Image hides the text...
then i thought of making the image inline and below is the function i wrote...now when the text is longer the page number is pushed down..also height is increased...
The other option i thought of is having like 3 containers in which i can i have image, text and page number respectively which stay in their fixed position all the time...but i am not sure how to implement it...
any suggestions...
below is my current code...
-DNG
Ok, I will try my best to describe my problem.
I have a VB macro that modifies a word document. Everything works fine.
I needed some specific image, text and page number alignment in the footer.But the alignment is currently skewed. If the text is smaller in length...alignment of image, text and page number works fine...but this gets skewed if the text is longer. Image hides the text...
then i thought of making the image inline and below is the function i wrote...now when the text is longer the page number is pushed down..also height is increased...
The other option i thought of is having like 3 containers in which i can i have image, text and page number respectively which stay in their fixed position all the time...but i am not sure how to implement it...
any suggestions...
below is my current code...
Code:
Sub FormatFooterLogo()
Dim bFoundFirst As Boolean
Selection.HomeKey unit:=wdStory
If ActiveWindow.ActivePane.View.Type = wdNormalView _
Or ActiveWindow.ActivePane.View.Type = wdOutlineView Then
ActiveWindow.ActivePane.View.Type = wdPrintView
End If
ActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageHeader
For Each Section In ActiveDocument.Sections
With Section
For Each Shape In .Footers(wdHeaderFooterPrimary).Shapes
Shape.Select
Debug.Print "Primary:: " & Shape.Name & " :: " & Shape.Visible
If UCase(Left(Shape.Name, 7)) = "PICTURE" And Shape.Visible = True Then
Shape.ConvertToInlineShape
End If
Next
For Each Shape In .Footers(wdHeaderFooterFirstPage).Shapes
Shape.Select
Debug.Print "First Page:: " & Shape.Name & " :: " & Shape.Visible
If UCase(Left(Shape.Name, 7)) = "PICTURE" And Shape.Visible = True Then
Shape.ConvertToInlineShape
End If
Next
End With
Next
ActiveWindow.ActivePane.View.SeekView = wdSeekMainDocument
End Sub
-DNG