|   |   | Object Model Reference : Classes : T : TextureFill : Properties : TextureFill.StyleName | 
Property StyleName As String
Member of TextureFill
The StyleName property returns the name of the style upon which a texture-fill pattern is based.
The StyleName property returns a read-only value.
The following VBA example displays the names of the texture-pattern fill and the texture library for each texture fill found in the drawing.
| Sub Test() | 
|  Dim s As Shape | 
|  Dim tf As TextureFill | 
|  Dim ss As String | 
|  Dim r As VbMsgBoxResult | 
|  For Each s In ActivePage.Shapes | 
|   If s.Fill.Type = cdrTextureFill Then | 
|    Set tf = s.Fill.Texture | 
|    s.CreateSelection ' Select the shape | 
|    ss = "Texture Name: " & tf.TextureName & vbCr & "Library Name: " | 
|    If tf.LibraryName = "" Then | 
|     ss = ss & "Styles" | 
|    Else | 
|     ss = ss & tf.LibraryName | 
|    End If | 
|    ss = ss & vbCr & "Style Name: " & tf.StyleName & vbCr | 
|    ss = ss & vbCr & "Press OK to continue" | 
|    r = MsgBox(ss, vbOKCancel) | 
|    If r = vbCancel Then Exit For | 
|   End If | 
|  Next s | 
| End Sub | 
|   |   |   | 
Copyright 2013 Corel Corporation. All rights reserved.