Results 1 to 2 of 2

Thread: LinearGradientBrush to VB

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jul 2012
    Location
    Denmark
    Posts
    216

    LinearGradientBrush to VB

    Hi,

    I need help to convert a piece of XAML to VB.Net

    XAML
    Code:
                            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                <GradientStop Color="#FF464646" Offset="0.243"/>
                                <GradientStop Color="White" Offset="1"/>
                            </LinearGradientBrush>
    Thank you in advance

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    110,274

    Re: LinearGradientBrush to VB

    Have you read the documentation for the LinearGradientBrush class? That seems the obvious place to start looking. That said, if you understand how XAML works then you should be able to translate that fairly easily. Obviously it's a LinearGradientBrush object and each attribute translates to a property. The nested elements would be items in a collection property and the fact that they are GradientStop elements suggests that that property would be named GradientStops or something close to that.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width