2
votes

I pinned Notepad2-mod to the taskbar. When I click the pinned shortcut, it opens a new instance but doesn't stack in place. It begins a new stack. Additional clicks will utilize the second stack. This can probably best be explained via screenshot:

Odd Taskbar Stacking

The oddest part is it used to stack on the taskbar shortcut if I started it by clicking on it or using WIN+num, but if I started Notepad2-mod by right-clicking on a file and using "open with notepad2-mod" it would stack in a new stack. Now, they all stack in a new stack (not on the taskbar-pinned shortcut).

Both the "open with notepad2-mod" registry shortcut and the taskbar-pinned shortcut run the same executable.

Ultimately, I'd like them all to stack in the same place, on top of the taskbar-pinned icon.

1) What did I do to persuade it to behave like this?
2) How can I convince it to all stack on the pinned icon?

Edit: I just noticed in the Task Manager that when I double click a .txt file I'm running a version of this binary named Notepad2.exe and when I click on the icon on the Taskbar I'm running a copy of this same binary named notepad.exe. I must have done that to fool Windows 7 into thinking it was using vanilla Notepad. I thought changing this might fix it, but it did not. They still stack on a different portion of the Taskbar. They even respond to keyboard shortcuts like Start Button+Number for the slot where they do actually stack.

3

3 Answers

2
votes

Thanks to the this link, this issue is fixed. Go read his site for a better answer than mine, but, in case his site ever goes away, here are the relevant snippets:

Notepad2 windows are now assigned to a custom AppUserModelID, that's why multiple icons may appear if Notepad2.exe is directly pinned to the taskbar. To fix this, open a Notepad2 window first, and then pin it to the taskbar from the Notepad2 taskbar button context menu.

Note that if you have followed the rest of his instructions on the page and set it up to redirect notepad.exe to notepad2.exe, you actually have to start up Notepad2.exe directly, then right click on the taskbar instance and click "Pin to Taskbar".

Now that I did that, all my Notepad2 instances stack in the same place on the taskbar!

Note that the author of Notepad2 says that you have to add code in your application to handle this.

Some reference documentation.

0
votes

Assuming that your OS is Windows 7 1. Check the settings of your task bar IE. right click the task bar and click properties @ the properties menu there is a drop down list it should say "Stack & hide-labels" if not set it to that setting.

If that does not work then you can try dragging the file that will not stack to the regular notepad and pin-it to the list in the stack-able tab.

aside from all of that, when you pin a application to the task bar even if it was edited and saved before it was pinned, it will always open a new instance of the application.

also you can make a simple batch file to start the application

@echo off rem you will want to set the directory using the DIR command start "your program's name here" rem you can use the pause>nul command to check if it worked.

Hope this helps.

0
votes

I had this problem with Internet Explorer because I had created a short cut and pinned that to the Task Bar. Then all new instances would stack on a separate icon. I unpinned the shortcut, then navigated to the IE executable, right clicked and selected "Pin to Task Bar". After I did that, all new instances stacked on top of the original pinned IE icon.