|
-
Aug 11th, 2005, 05:43 AM
#1
Thread Starter
Lively Member
How to:-Application with multiple icons.
I want to create application in VB6.0 with multiple icons like e.g. Internet Explorer, but I've not been able to put more than 1 icon while creating an executable file.
pls help.
-
Aug 11th, 2005, 05:48 AM
#2
Re: How to:-Application with multiple icons.
The only icon associated with Internet Explorer is the e on top of a piece of paper icon.
Each .exe program will have just one icon associated with it (at a time), but I believe you can change that icon periodically if you want to.
What is it precisely that you want to do with multiple icons?
-
Aug 11th, 2005, 06:09 AM
#3
Thread Starter
Lively Member
Re: How to:-Application with multiple icons.
but when we open internet explorer in icon extracting applications like microangelo, we can see a bunch of icons....i just wanted to add that functionality to my app.
actually, i'm using command line argumet while calling my application, which would behave differently with different parameters.
now if i can get different icons to different short cuts (to same application)then it would be amazing.
-
Aug 11th, 2005, 06:56 AM
#4
Addicted Member
Re: How to:-Application with multiple icons.
you will have to create resource file for that, also known as satellite dll i think.
You can do following:
1. Select a project type a Active DLL.
2. From AddIn manager, add VB 6 resource Editor
3. Use this resource editor to add icons, 1 by 1.
4. Compile this DLL.
This DLL can be used for icons.
-
Aug 12th, 2005, 06:42 AM
#5
Thread Starter
Lively Member
Re: How to:-Application with multiple icons.
Can you please give me a small, full-example of the same. I've tried many things but i'm not familiar to resource editor.
-
Aug 12th, 2005, 06:53 AM
#6
Addicted Member
Re: How to:-Application with multiple icons.
Unfortunately, i cannot explain more about resource editor, than the one i have already mentioned.
You will have to check MSDN, because it is more like "click here-click there" stuff.
Assuming that you have entered your bitmap image using Resource Editor, you can use a simple VB function as follows:
bytData = LoadResData(ID, "CUSTOM")
Now, the ID here reflects the ID for the resource you entered.
The bytData can be used further, because it is your raw bytes, representing the icon\image.
So, use the bytData to write to a file, with say .ico as extension.
Use:
Open OutputFilePath For Binary Access Write As #fp
Put #fp, , bytData
Close #fp
Now, your icon file is ready in OutPutFilePath
Check the following for Resource Editor:
http://www.thevbzone.com/l_res.htm
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|