How to register a global hotkey for your application in C#

How to register a global hotkey for your application in C#

Register a hotkey for your application that can be triggered even if your form is minimized and does not have focus. More »

How to download a file in C# (progressbar and download speed)

How to download a file in C# (progressbar and download speed)

Learn how to download files in C# while displaying the percentage and the download speed. More »

UDP hole punching implementation in C#

UDP hole punching implementation in C#

Learn how to implement UDP hole punching so you can make your clients life a lot easier by not forcing them to open ports on their end. More »

 

How to set a custom page zoom value in Google Chrome

By default Google Chrome has predefined values for the page zoom setting. But what happens if none of those values satisfy your needs ? Since Google Chrome doesn’t provide you with way to set your own custom value we will need to use a workaround to achieve that.

The following workaround works by modifying the HTML code of the settings page allowing you to add (or remove if needed) more options from the drop down list. Another advantage of this method is that it doesn’t require an extension to be installed therefore not consuming extra unneeded memory.

Lets get started!

Access Google’s Chrome settings page by visiting chrome://settings/.

Share on FacebookTweet about this on TwitterShare on Google+Share on StumbleUponShare on LinkedInShare on RedditPin on PinterestShare on TumblrDigg thisPrint this pageEmail this to someone

How to display a progressbar in taskbar in C#

You might have noticed that programs display a progress bar in the taskbar a lot of times. This allows users to see the progression of the task even if the application is minimized by simply looking at the taskbar. Today I will be showing you a way to achieve that functionality so you can use it in your projects.

Taskbar progress bar

First you will need to download Windows API Code Pack for Microsoft .NET Framework. Extract the contents of the file and search for Microsoft.WindowsAPICodePack.Shell.dll which is located under the binaries folder.

Add Microsoft.WindowsAPICodePack.Shell.dll as a reference to your project. This will allow you to use the namespaces which are required in order to display the progress bar.

The code below is an example on how you can implement the feature.

Share on FacebookTweet about this on TwitterShare on Google+Share on StumbleUponShare on LinkedInShare on RedditPin on PinterestShare on TumblrDigg thisPrint this pageEmail this to someone

How to make Firefox ask to save tabs on exit

Sadly the newer versions of Firefox no longer ask you if you want to save the open tabs when you close Firefox. This is probably because of the new feature that has been implemented in the general options which allows Firefox to always remember the open tabs and windows upon closing.

Firefox save windows and tabs option

But what happens if you don’t always want to save the open tabs ?

To get back the original functionality of Firefox, that used to show a message on exit asking if we want to save the open tabs or not we need to dig a bit in Firefox’s configuration settings.

  1. Type about:config in your address bar and press enter.
  2. There are three entries we are interested in (four if you are using Firefox 12 or higher).
    • browser.tabs.warnOnClose
    • browser.warnOnQuit
    • browser.warnOnRestart
    • browser.showQuitWarning (for Firefox 12 and higher)

    Search for each one individually and make sure that their value is set to true.

  3. Restart Firefox.

Now everytime you will close Firefox (assuming you have tabs open) you will get a message asking you if you want to save the current tabs or not.

Firefox save tabs message

Share on FacebookTweet about this on TwitterShare on Google+Share on StumbleUponShare on LinkedInShare on RedditPin on PinterestShare on TumblrDigg thisPrint this pageEmail this to someone

Disable grey urls in Firefox’s address bar

Firefox 6 and higher support a new feature that will automatically color the domain name and the top level domain black, greying out the rest of the URL.

Since this feature is enabled by default in the latest versions you might want to disable it if you don’t like the way Firefox is displaying the URL in the address bar. If that is the case simply follow the steps below.

browser.urlbar.formatting.enabled (true)
Firefox url formatting color setting enabled

browser.urlbar.formatting.enabled (false)
Firefox url formatting color setting disabled

How to disable Firefox’s url formatting.

  1. Type about:config in your address bar and press enter.
  2. Search for browser.urlbar.formatting.enabled.
  3. Make sure the value is set to false.

The URL in the address bar should now be colored in black only.

Share on FacebookTweet about this on TwitterShare on Google+Share on StumbleUponShare on LinkedInShare on RedditPin on PinterestShare on TumblrDigg thisPrint this pageEmail this to someone

Disable recently closed tabs and recently closed windows in Firefox

Firefox’s recently closed tabs and recently closed windows are not controlled by the history settings. Which means even if you have history disabled the last windows and tabs you closed will still be there.

If you are worried about your privacy and you don’t want others to able to find out the last websites you visited then an addition solution to disabling the history is to disable the recently closed tabs and recently closed windows as well.

In order to do that you will need to following the steps below:

  1. Type about:config in your address bar and press enter.
  2. Search for browser.sessionstore.max_windows_undo and browser.sessionstore.max_tabs_undo.
  3. Change the value to the number of max entries you want Firefox to remember. Use 0 to disable them completely.

And as always, if you are making changes to Firefox’s configuration, it is always wise to restart Firefox once the changes have been made.

Share on FacebookTweet about this on TwitterShare on Google+Share on StumbleUponShare on LinkedInShare on RedditPin on PinterestShare on TumblrDigg thisPrint this pageEmail this to someone