G
Guest
How can I delete a specific slide tag? I want to delete empty tags. I've
tried this:
Sub Delete_Empty_Tag()
Dim x As Long
Dim oSl As Slide
Set oSl = ActiveWindow.View.Slide
If oSl.Tags.Count > 0 Then
With oSl.Tags
For x = 1 To .Count
If oSl.Tags.Name(x) = "" And oSl.Tags.Value(x) = "" Then
oSl.Tags(x).Delete
End If
Next ' x
End With
End If
End Sub
But I get this error message:
Compile error: Invalid qualifier Tags(x)
(referring to the line " oSl.Tags(x).Delete ")
I'm not sure how the empty tags got there to begin with, but when I
ShowTags, I see tags for which Name="" and Value="", and I want to get rid of
them. I can't seem to target a single, specific Tag for deletion because
there's a Tags (plural) object, but not a Tag (singular) object to be deleted.
Any ideas?
tried this:
Sub Delete_Empty_Tag()
Dim x As Long
Dim oSl As Slide
Set oSl = ActiveWindow.View.Slide
If oSl.Tags.Count > 0 Then
With oSl.Tags
For x = 1 To .Count
If oSl.Tags.Name(x) = "" And oSl.Tags.Value(x) = "" Then
oSl.Tags(x).Delete
End If
Next ' x
End With
End If
End Sub
But I get this error message:
Compile error: Invalid qualifier Tags(x)
(referring to the line " oSl.Tags(x).Delete ")
I'm not sure how the empty tags got there to begin with, but when I
ShowTags, I see tags for which Name="" and Value="", and I want to get rid of
them. I can't seem to target a single, specific Tag for deletion because
there's a Tags (plural) object, but not a Tag (singular) object to be deleted.
Any ideas?