[Webinar] Streamline your web hosting managementRegister Today

x
?
Solved

Active X - picture property

Posted on 1999-12-01
2
Medium Priority
?
202 Views
Last Modified: 2013-11-25
I know how to add a property to the properties page for my OCX, but how do I allow a user to browse for a picture at design time? I am creating a type of picture control, and I would like to be able to set any picture I want into it, but I need to know how to browse the hard drive.
0
Comment
Question by:microboard
2 Comments
 
LVL 32

Accepted Solution

by:
Erick37 earned 300 total points
ID: 2248119
A property which is of the StdPicture type will automatically have the browse feature in the property window. In order to add the browse function to the property page, you can add the StandardPicture built in page to the property page.  All of your StdPicture properties will then be listed.

e.g.

Public Property Set Picture2(ByVal NewPic As StdPicture)
    Set mPic2 = NewPic
End Property

Public Property Get Picture2()
    Set Picture2 = mPic2
End Property
0
 

Author Comment

by:microboard
ID: 2248871
thanks
0

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

590 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question