Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Positionsrahmen ansprechen

290 views
Skip to first unread message

Andreas

unread,
May 16, 2000, 3:00:00 AM5/16/00
to
Hi NG,

ich möchte per VBA einen Positionsrahmen ansprechen und die Hintergrundfarbe
veraendern.

Koennt Ihr mir helfen ???

Word 97

Danke
Andreas

Thomas Löwe [MS MVP Word]

unread,
May 16, 2000, 3:00:00 AM5/16/00
to
Hallo,

ich habe deine Anfrage auch in die Newsgroup

news:\\microsoft.public.de.word.vba

weitergeleitet. Alle Antworten hierauf erscheinen dort.

--
Schöne Grüße Thomas Löwe [Microsoft MVP Word]
Bitte alle Supportanfragen in die Newsgroup stellen.
Microsoft KB: englisch: http://support.microsoft.com/support/search/
Microsoft KB: deutsch : http://search.microsoft.com/germany/supportkb

"Andreas"
Bezug: news:i9dU4.63$vk6....@nreader1.kpnqwest.net...

> ich möchte per VBA einen Positionsrahmen ansprechen und

> die Hintergrundfarbe verändern.

Silvia Widmer

unread,
May 17, 2000, 3:00:00 AM5/17/00
to
Hallo Andreas

Um den ersten Positionsrahmen im Dokument einzufärben, verwende folgende
Mimik:


Gruss
Silvia Widmer


Sub TestF()
Dim PR As Frame
Set PR = ActiveDocument.Frames(1)
PR.Shading.BackgroundPatternColorIndex = wdRed
End Sub


Andreas

unread,
May 17, 2000, 3:00:00 AM5/17/00
to
Hallo Silvia,

danke für Deine Antwort.-funktioniert.
was ist eigenlich der unterschied zwischen einem textfeld und
positionsrahmen. beim textfeld funktioniert es nämlich nicht.

lg
Andreas

Silvia Widmer <repr...@ksc.th.com> schrieb in im Newsbeitrag:
udFLEs1v$GA.275@cppssbbsa03...

Andreas

unread,
May 17, 2000, 3:00:00 AM5/17/00
to
Hallo Silvia,

jetzt möchte ich den positionsrahmen in einer Kopfzeile verändern; das geht
auch nicht.

hast du noch eine idee?

danke

Silvia Widmer

unread,
May 18, 2000, 3:00:00 AM5/18/00
to
hello again, Andreas

Teile mir einfach rechtzeitig mit, wenn wir das gesamte Objektmodell von MS
Word durch haben:


Gruss
Silvia Widmer


Sub ErstesTextfeldImHaupteilDesDokumentes()
Dim Form As Shape
For Each Form In ActiveDocument.Shapes
If Form.Type = msoTextBox Then
Form.TextFrame.TextRange.Shading.BackgroundPatternColorIndex = wdBlue
Exit For
End If
Next
End Sub

Sub ErsterPositionsrahmenInDerHauptKopfzeileDesErstenAbschnittesImDokument()
Dim kz As HeaderFooter
Set kz = ActiveDocument.Sections(1).Headers(wdHeaderFooterPrimary)
kz.Range.Frames(1).Shading.BackgroundPatternColorIndex = wdPink
End Sub

Sub ErstesTextfeldInDerHauptKopfzeileDesErstenAbschnittesImDokument()
Dim Form As Shape
Set kz = ActiveDocument.Sections(1).Headers(wdHeaderFooterPrimary)
For Each Form In kz.Shapes
If Form.Type = msoTextBox Then
Form.TextFrame.TextRange.Shading.BackgroundPatternColorIndex = wdGreen
Exit For
End If
Next
End Sub

Silvia Widmer

unread,
May 18, 2000, 3:00:00 AM5/18/00
to

Andreas

unread,
May 18, 2000, 3:00:00 AM5/18/00
to
Vielen Dank Silvia

Gruss
Andreas


Silvia Widmer <repr...@ksc.th.com> schrieb in im Newsbeitrag:

OsexMUHw$GA.225@cppssbbsa03...

0 new messages