[SF Coders] Grabbing an Icon from a File and Saving! [TUT] - Printable Version +- Support Forums (https://www.supportforums.net) +-- Forum: Categories (https://www.supportforums.net/forumdisplay.php?fid=87) +--- Forum: Coding Support Forums (https://www.supportforums.net/forumdisplay.php?fid=18) +---- Forum: Visual Basic and the .NET Framework (https://www.supportforums.net/forumdisplay.php?fid=19) +---- Thread: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] (/showthread.php?tid=23343) Pages:
1
2
|
[SF Coders] Grabbing an Icon from a File and Saving! [TUT] - milopeach - 11-20-2011 In this tutorial I will show you how to open any file, extract the icon and save it! First of all, Let's start with the GUI. We'll need the following: -Menu Strip (Two button, Open and Save) -Picturebox Quite a basic GUI but you can add on to it with whatever you like! On our Menustrip, double click the "Open" button to get automatically generated sub methods of the button when clicked. Inside this Sub we will put our code to open an OpenFileDialogue and then use that dialogue to open the program! Spoiler to see the whole code: Spoiler (Click to View) Once you have the OpenFileDialogue set we will make sure the Icon can be loaded into the Picturebox. So we will use a function I wrote to get the Icon and set it as an Image in the Picturebox. Once again, A spoiler so it doesn't get ruined early: Spoiler (Click to View) We're almost there!! Ok, Now to save the icon! This is almost the same as the OpenFileDialogue - If you've guess it, we're going to use a SaveFileDialogue for this one. Try this step before you open the spoiler, It might intrigue you. Spoiler (Click to View) That's it! You've now made your own File Extracting program! Congradulations! Here's the source if something has gone wrong. Download it here. (VB.NET 2010) RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - BreShiE - 11-20-2011 Nice program milo, also you did it in quick time too! I think the coding section on this forum is going to benifit having you here. Well done, you will be set a new project some time next month. RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - milopeach - 11-20-2011 Ouch, Next month. I've finished my High Schooling career and only work 3 days a week. I have about 4-5 months spare before University - Ht me up bro. RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - Ignite. - 11-20-2011 Nice application, it's great that we have a group that benefits the community, hope to see more releases from the SF Coders. A+. RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - BreShiE - 11-21-2011 (11-20-2011, 05:39 AM)Ignite. Wrote: Nice application, it's great that we have a group that benefits the community, hope to see more releases from the SF Coders. You sure will do, each month the members are assigned a project and they are to complete it within a week. If they do not complete by then they're put into the category of inactivity and kicked from the group. Seems a bit harsh I know, but to keep a HQ group you have to do what you have to do. RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - Ignite. - 11-21-2011 (11-21-2011, 07:15 AM)BreShiE Wrote: You sure will do, each month the members are assigned a project and they are to complete it within a week. If they do not complete by then they're put into the category of inactivity and kicked from the group. Been in a group just like that on HackForums, not sure if it was a week deadline though think it was a bit longer. RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - UrbanByte - 11-21-2011 Nice tutorial and simple. Nice to see non-malicious code ;). RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - BreShiE - 11-24-2011 (11-21-2011, 07:18 AM)Ignite. Wrote: Been in a group just like that on HackForums, not sure if it was a week deadline though think it was a bit longer. The projects I set are easily done in a day, nevermind a week, haha. RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - HostGap - 12-03-2011 Thank you for this. This is what I've needed. Bookmarked for sure. RE: [SF Coders] Grabbing an Icon from a File and Saving! [TUT] - FizzyMentos - 12-05-2011 Very basic, but very clear, you have written well and its easily understandable, good work ... again |