Yes,It`s simple:
In the Form properties window select "icon" and choose an icon from the dialog box.
note :You can select your icons from Icon folder where you installed VB. Behnam2204@yahoo.com
BehnamPro
Your original version of this question in thread222-345122 mentioned that you actually wanted to be able to place a small jpeg in the titlebar. CestusGW's reply that you can only use a .ico was a little misleading - it is possible to use any of the image files that can be loaded via LoadPicture.
The trick involves use of the ImageList control (which is one of the components of the Microsoft Common Controls library). Here's an example of a function to do this: [tt]
Private Sub SetFormIcon(frmTargetForm As Form, ByVal strImageSource As String)
ImageList1.ListImages.Clear
ImageList1.ListImages.Add , "MyIconSource", LoadPicture(strImageSource)
frmTargetForm.Icon = ImageList1.ListImages("MyIconSource".ExtractIcon
End Sub
Yes,It`s simple:
In the Form properties window select "Icon" and select an icon for it.
Note:You can select your icons from Icon folder where you installed VB.(...\VB98\Graphics\Icons) Behnam2204@yahoo.com
BehnamPro
?? my MSDN Help only shows 'ImageList' as a VC++ control. Of course, I have had a lot of trouoble with 'Ms. Help speak' since being rewarded with MSDN, but usually when I can find the topic, the VB references are at least there. Is this a VB object, or are you using an API which isn't shown?
MichaelRed
m.red@att.net
There is never time to do it right but there is always time to do it over
ImageList is a standard control in the Common Controls library. It has been there since W95. So, no special API calls. It is definitely documented on MSDN, under:
MSDN Library/Visual Studio 6.0 Documentation/Visual Basic Documentation/Reference/Controls Reference/ActiveX Controls/ImageList Control
Thanks. Aparently I now have another topic to find a textbook for (MSDN?)
I had thought (ASS-U-ME-D?) that selecting "(Entire Collection)" in the active subset realy meant "ALL", but now, I'm completly UNSURE of this.
Of course, since MSDN has been added to my "Help" it appears to be a lot less helpful and a lot more confusing. It is surely another sign of advancing age ...
MichaelRed
m.red@att.net
There is never time to do it right but there is always time to do it over
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.