Thema Datum  Von Nutzer Rating
Antwort
24.02.2018 18:18:09 hwl
NotSolved
24.02.2018 18:52:11 Gast60714
NotSolved
25.02.2018 11:59:35 hwl
NotSolved
25.02.2018 16:08:12 Gast46562
NotSolved
25.02.2018 16:32:58 hwl
NotSolved
25.02.2018 17:07:00 Gast41734
NotSolved
25.02.2018 18:16:33 hwl
NotSolved
25.02.2018 18:33:48 Gast13352
NotSolved
25.02.2018 18:44:29 hwl
NotSolved
25.02.2018 18:50:40 hwl
NotSolved
25.02.2018 18:51:39 Gast96005
NotSolved
25.02.2018 19:23:29 Hwl
NotSolved
Rot Rahmen
26.02.2018 01:22:39 Gast1614
NotSolved
26.02.2018 09:46:18 hwl
NotSolved
26.02.2018 13:20:24 hwl
NotSolved
26.02.2018 15:32:33 hwl
Solved
26.02.2018 16:08:03 hwl
Solved
26.02.2018 17:00:51 Gast * 7
NotSolved
26.02.2018 17:27:36 Gast27337
NotSolved
26.02.2018 17:38:41 hwl
NotSolved
26.02.2018 18:00:03 hwl
NotSolved
26.02.2018 18:06:41 Gast * 9
NotSolved
26.02.2018 18:08:43 Gast * 9
NotSolved
26.02.2018 18:02:14 Gast91980
NotSolved
26.02.2018 18:12:23 hwl
NotSolved
26.02.2018 18:57:37 hwl
NotSolved
27.02.2018 14:41:17 Gast26469
NotSolved
27.02.2018 17:23:54 hwl
NotSolved
27.02.2018 17:43:59 Gast * 9
NotSolved
Blau Blau Rahmen
27.02.2018 17:44:05 hwl
NotSolved

Ansicht des Beitrags:
Von:
Gast1614
Datum:
26.02.2018 01:22:39
Views:
528
Rating: Antwort:
  Ja
Thema:
Rahmen

Hallo,

okidoki, die Leerzeichen sind hartnäckig, aber probiers mal hiermit...

Option Explicit

Public Sub Adjektive()
Const xlUp As Long = -4162 '// Konstante der Excel-App...
Dim AktWord As Range
Dim AllWord() As String, iWord As Long, Found As Boolean
Dim TmpStr As String

' Exceldaten aus offener Arbeitsmappe einlesen
' Aktuell 1. Spalte Zeile 1-5000
Dim xlApp As Object ' Excel.Application
Dim avntSearchWords() As Variant
Dim ialngIndex As Long
Set xlApp = GetObject(Class:="Excel.Application")
With xlApp
    avntSearchWords = .Cells(1, 1).Resize(.Cells(.Rows.Count, 1).End(xlUp).Row, 1).Value '// <--- an Stelle von --  Range("A1:A5000") -- besser so....
End With
For ialngIndex = 1 To UBound(avntSearchWords, 1)
    If Len(avntSearchWords(ialngIndex, 1) & "") > 0 Then
      ReDim Preserve AllWord(iWord) As String
      AllWord(iWord) = UCase$(avntSearchWords(ialngIndex, 1))
      iWord = iWord + 1
    End If
Next
' Worddokument durchsuchen und Wörter Rot färben
With ActiveDocument.Range
    For Each AktWord In .Words
       With AktWord
            TmpStr = Trim$(.Text)
            For iWord = 0 To UBound(AllWord)
                 If UCase$(TmpStr) Like AllWord(iWord) & "*" Then
                     If Len(TmpStr) <> .Characters.Count Then
                        Call prcSetBorders(probjBorder:= _
                          ActiveDocument.Range(Start:=.Characters(1).Start, _
                            End:=.Characters(.Characters.Count).Start).Font.Borders(1))
                     Else
                        Call prcSetBorders(probjBorder:=.Font.Borders(1))
                     End If
                 End If
            Next
       End With
    Next
End With
Set xlApp = Nothing
End Sub

Private Sub prcSetBorders(ByRef probjBorder As Border)
With probjBorder
    .LineStyle = wdLineStyleSingle
    .LineWidth = wdLineWidth150pt
    .ColorIndex = wdRed '//wdBrightGreen
End With
End Sub

Gruß,


Ihre Antwort
  • Bitte beschreiben Sie Ihr Problem möglichst ausführlich. (Wichtige Info z.B.: Office Version, Betriebssystem, Wo genau kommen Sie nicht weiter)
  • Bitte helfen Sie ebenfalls wenn Ihnen geholfen werden konnte und markieren Sie Ihre Anfrage als erledigt (Klick auf Häckchen)
  • Bei Crossposting, entsprechende Links auf andere Forenbeiträge beifügen / nachtragen
  • Codeschnipsel am besten über den Code-Button im Text-Editor einfügen
  • Die Angabe der Emailadresse ist freiwillig und wird nur verwendet, um Sie bei Antworten auf Ihren Beitrag zu benachrichtigen
Thema: Name: Email:



  • Bitte beschreiben Sie Ihr Problem möglichst ausführlich. (Wichtige Info z.B.: Office Version, Betriebssystem, Wo genau kommen Sie nicht weiter)
  • Bitte helfen Sie ebenfalls wenn Ihnen geholfen werden konnte und markieren Sie Ihre Anfrage als erledigt (Klick auf Häckchen)
  • Bei Crossposting, entsprechende Links auf andere Forenbeiträge beifügen / nachtragen
  • Codeschnipsel am besten über den Code-Button im Text-Editor einfügen
  • Die Angabe der Emailadresse ist freiwillig und wird nur verwendet, um Sie bei Antworten auf Ihren Beitrag zu benachrichtigen

Thema Datum  Von Nutzer Rating
Antwort
24.02.2018 18:18:09 hwl
NotSolved
24.02.2018 18:52:11 Gast60714
NotSolved
25.02.2018 11:59:35 hwl
NotSolved
25.02.2018 16:08:12 Gast46562
NotSolved
25.02.2018 16:32:58 hwl
NotSolved
25.02.2018 17:07:00 Gast41734
NotSolved
25.02.2018 18:16:33 hwl
NotSolved
25.02.2018 18:33:48 Gast13352
NotSolved
25.02.2018 18:44:29 hwl
NotSolved
25.02.2018 18:50:40 hwl
NotSolved
25.02.2018 18:51:39 Gast96005
NotSolved
25.02.2018 19:23:29 Hwl
NotSolved
Rot Rahmen
26.02.2018 01:22:39 Gast1614
NotSolved
26.02.2018 09:46:18 hwl
NotSolved
26.02.2018 13:20:24 hwl
NotSolved
26.02.2018 15:32:33 hwl
Solved
26.02.2018 16:08:03 hwl
Solved
26.02.2018 17:00:51 Gast * 7
NotSolved
26.02.2018 17:27:36 Gast27337
NotSolved
26.02.2018 17:38:41 hwl
NotSolved
26.02.2018 18:00:03 hwl
NotSolved
26.02.2018 18:06:41 Gast * 9
NotSolved
26.02.2018 18:08:43 Gast * 9
NotSolved
26.02.2018 18:02:14 Gast91980
NotSolved
26.02.2018 18:12:23 hwl
NotSolved
26.02.2018 18:57:37 hwl
NotSolved
27.02.2018 14:41:17 Gast26469
NotSolved
27.02.2018 17:23:54 hwl
NotSolved
27.02.2018 17:43:59 Gast * 9
NotSolved
Blau Blau Rahmen
27.02.2018 17:44:05 hwl
NotSolved