1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Turn shortcut icon images into YouTube thumbnails

Discussion in 'All Other Software' started by crcook84, Jun 13, 2018.

Advertisement
  1. crcook84

    crcook84 Thread Starter

    Joined:
    Aug 12, 2010
    Messages:
    407
    There’s a YouTube channel that I like a lot of the videos on. So, each time I see a video link I’m interested in, I drag the link to a folder so that Windows automatically creates a shortcut to the video. The problem is I recognize some of the videos by the thumbnail that was displaying on the YouTube page. So, that’s when I got to thinking: Is there a program out there that will cache the thumbnail image for a video link that has an accompanying thumbnail image and use that to replace the icon on said shortcut?

    Yes, for a page full of shortcuts, that could take some time. However, taking into consideration the fact that YouTube now offers a variety of thumbnail sizes (LQ, MQ, HQ, & BQ), the amount of data that gets downloaded can be determined just by the size of the thumbnail.
     
  2. Sponsor

  3. Xsage

    Xsage

    Joined:
    Jan 8, 2016
    Messages:
    225
    First Name:
    Dave
    It begs the question, why not just add the videos to a playlist on YouTube or use the "watch later" feature. That basically does what you want without having to save anything on your side.

    That being said, what you are asking is possible. I don't know of any programs that do this, and a quick google search shows up nothing. However it shouldn't be too difficult to make an application to do this. I've done some preliminary tests and have made a quick application that does what you ask.

    If you are a windows user and still want something like this, let me know and I can add some bells and whistles to this and upload it for you.
     
  4. crcook84

    crcook84 Thread Starter

    Joined:
    Aug 12, 2010
    Messages:
    407
    Well, now that I know that the three dots next to a given video has that option (I probably found that out before but just forgot), it's something to think about. Although, I see myself loosing track of playlists if I don't know where I put them...and I can easily see this getting complicated with YouTube changing it's layout every now and then.
    I'd love to try out your software. I can try it out and see what all it can do for me. Although, will it have some integration problems with Windows 10 or is it it's own application like Agent Ransack or Locate and you access the directory from the software instead of Explorer? I ask only because the latest versions of Explorer are not MOD friendly (not that that would deter me from using it).
     
  5. Xsage

    Xsage

    Joined:
    Jan 8, 2016
    Messages:
    225
    First Name:
    Dave
    No problem, I'll finish it off tomorrow at work (instead of doing what I'm actually paid to do haha).
    Its a standalone application where you provide a couple of parameters, such as the location of the shortcuts, the location you want to store the thumbnails and a button to start the process.
    It will then find any new .url files and:
    - parse the shortcut
    - identify the video ID
    - download the JPEG from youtube servers
    - convert the JPEG into a bitmap .ico file of 256x256
    - rewrite the shortcut with the changes
    - somehow apply the changes, the only effective way I have found is to make a copy of the file and delete the old one and rename the new one ... but I'm sure there is a better way.

    And then boom, you will have the thumbnail as the icon.

    All of the settings will be saved so all you will need to do after dragging a shortcut to the folder is run the application and click go.
     
  6. crcook84

    crcook84 Thread Starter

    Joined:
    Aug 12, 2010
    Messages:
    407
    Hm. Sounds like it converts, or replaces, the shortcut with a modified shortcut that utilizes a thumbnail image...interesting. Does that mean the change will be visible outside of the program?
     
  7. Xsage

    Xsage

    Joined:
    Jan 8, 2016
    Messages:
    225
    First Name:
    Dave
    Yes, the change is visible outside of the program. All the program does, it modify the already existing shortcut.
     
  8. Xsage

    Xsage

    Joined:
    Jan 8, 2016
    Messages:
    225
    First Name:
    Dave
    Finally finished.
    Its not pretty, but it does the job.
    There also seems to be a problem where on occassion, some of the icons will appear in a smaller size for no apparent reason, after reading into this for a long time - it seems that this a bug in windows and there is no real way to fix it, so you will have to deal with it :p

    1) Download the ZIP here: https://drive.google.com/open?id=1Xeo_j66bWkPlU0jASnR2tkIoX6msw-Gj
    2) Extract to a location
    3) Run the .exe
    4) using the browse button, select the folder location that has all of your youtube links in it.
    5) using the browse button, select a folder to store the thumbnails in. (its advised you make a new folder and do not keep anything else inside this folder as the software automatically cleans files that arn't associated with anything in the folder with the links in.
    6) Click "Get Icons" to automatically download and set the icons.


    [​IMG]

    Please see the video link below to see the application in action.

    https://i.gyazo.com/0e1bee236a6802e7ff62e39756156efd.mp4

    Enjoy!
     
  9. crcook84

    crcook84 Thread Starter

    Joined:
    Aug 12, 2010
    Messages:
    407
    This is the error message I get:
    "An exception occurred during a WebClient request."
    I tried running it in Windows 7 and 10. I get the same response. The good news is it downloaded all the JPG images and converted them into ICOs. So, it, partially, does the job. It does get me thinking that maybe I could try changing the default icon location for Windows itself. Anyways, that's how far the program gets for me.
     
  10. Xsage

    Xsage

    Joined:
    Jan 8, 2016
    Messages:
    225
    First Name:
    Dave
    Thats strange, because the WebClient part takes place during the downloading, so if its already downloaded and converted the jpegs into Icons, you shouldn't be getting that error o_O

    I'll run some more tests on my side to see if I can figure it out.

    The only way I can see you getting that error, is if the shortcuts include a time stamp. I've made some tweeks and updated the download link, redownload and replace the files.

    The window should say V1.1 in the bottom left.

    Try it out and let me know if it fixes your issue, It should also give more information on why its not working if it fails.
     
    Last edited: Jun 16, 2018 at 4:06 PM
  11. crcook84

    crcook84 Thread Starter

    Joined:
    Aug 12, 2010
    Messages:
    407
    I re-downloaded the file and it says v1.1 in the bottom left corner. It downloads the images and converts them into ICO files. I still get the "An exception occurred during a WebClient request" error message. But, I. also, get an additional message saying "The given path's format is not supported". All of my links are .url files. Is there a specific weblink format you use? I do see that it changes all the files from .url to .url.iconed2.url. So, it's making an effort.

    As for a time stamp, I took a look at one of the original .url links and neither the details tab nor the previous versions tab contain info for a creation date or a modified date.
     
  12. Xsage

    Xsage

    Joined:
    Jan 8, 2016
    Messages:
    225
    First Name:
    Dave
    if you can open one of the iconed .url files in notepad, what does the "IconFile" parameter say.

    Actually, you might aswell post everything in the file, because it may be I'm accidently overwriting a parameter on your end which wasn't happening on my end due to a different order ...

    Even if you are getting a webclient exception, if its downloading the pictures, and recreating the files with the correct information it should be working. :cry:
     
  13. crcook84

    crcook84 Thread Starter

    Joined:
    Aug 12, 2010
    Messages:
    407
  14. Xsage

    Xsage

    Joined:
    Jan 8, 2016
    Messages:
    225
    First Name:
    Dave
    Good news, I can see the issue.

    I'll get back to you in a few days after I've had time to look at it.

    Also, what browser do you use and how to you create the shortcuts?
     
    Last edited: Jun 18, 2018 at 5:54 PM
  15. crcook84

    crcook84 Thread Starter

    Joined:
    Aug 12, 2010
    Messages:
    407
    I use Chrome. I'll usually just drag the weblink form the info icon into a folder and I assume Windows just creates a .url file from that.
     
  16. Xsage

    Xsage

    Joined:
    Jan 8, 2016
    Messages:
    225
    First Name:
    Dave
    Alright, redownload. should be v2.0

    There where two problems with that link you had, the first was there where extra headers in the .url folder that shouldn't have been there. I wasn't able to recreate this, so I've just added something to cut out any unwanted headers.

    The second problem was the name of the video contained a strange bullet point looking character, so I added Regular Expression filtering to clean the names, you may notice on both the .ico file and the url files, the name will change slightly (as in any strange characters will be removed).

    I'm fairly confident that this will work and shouldn't need any further work.

    Please be aware, that the software won't touch any .url files with "iconed" in the name, so if you want to run this on any exisiting files from the last test you did, you will need to rename the files to remove the "iconed" text. :)
     
  17. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...

Short URL to this thread: https://techguy.org/1211501

  1. 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.
    Dismiss Notice