troubleshooting Question

Custom Controls Set Property Problem In VB 2008

Avatar of vickjam
vickjam asked on
Visual Basic Classic
12 Comments1 Solution307 ViewsLast Modified:
I have created a control which has 3 inner controls. A picturebox, Richtextbox and a panel control. I have created a property so I can access the background color property of the inn picturebox control. Here is the code:

 Public Property PictureBoxBgColor() As Color
        Get
            Return PictureBox.BackColor
        End Get
        Set(ByVal value As Color)
            PictureBox.BackColor = value
        End Set
    End Property

I don't get any errors with this and it shows up after I build the colntrol. everything works great except that it does not change the background color no matter which color you choose. What am I doing wrong here?

Thanks in advance
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 12 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 12 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros