Tuesday, December 17, 2013

Autoend task Windows 8.1

More annoyances. When I choose reboot or shutdown windows timeouts and waits for the user to actually push end tasks. This happens on most of my W8 machines.

To shutdown these apps more brutally heres another reghack.

-----autoend.reg-------------

Windows Registry Editor Version 5.00

[HKEY_USERS\.DEFAULT\Control Panel\Desktop]
"AutoEndTasks"="1"

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control]
"WaitToKillServiceTimeout"="2500"

------------------eof----------------

 

References:

http://www.anushand.com/2013/02/auto-end-tasks-windows-8-at-shutdown.html

http://www.reddit.com/r/windows/comments/1936nl/waiting_for_background_programs_to_close_how_do_i/

Saturday, December 14, 2013

Windows 8.1 and the mythical WinSxS

To see the actual size of the WinSxS folder in Windows 8.1

/>dism /online /cleanup-image /analyzecomponentstore

Backups and Cache is the actual space used by WinSxS

To cleanup the folder in Windows 8.1

/> dism.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase
To do it on previous versions (to w7 or vista)
/>dism /online /cleanup-image /spsuperseded
After running this command its no longer possible to uninstall updates or servicepacks. But most people don’t and if you change your mind, you can always get the msi-package and still do an uninstall.
 


References:


http://technet.microsoft.com/en-us/library/dn251566.aspx


http://technet.microsoft.com/en-us/library/dn251565.aspx

Thursday, December 12, 2013

Disable alerts

In some scenarios we don’t want our users to able to use alerts on lists or libraries on a en entire site.

Reason for this could be to simplify for the users, less clutter, or simply cause you don’t want it to be possible to put alert on sites that might carry sensitive information that shouldn’t be sent over the wire.

More and more people host their email off-premises these days and not everyone is up to speed on TLS just yet so this kind of scenarios is getting more common.

To disable Alert for an entire site:

  1. Central Administration > Application Management> Manage Web Applications >
  2. Current Site > General Settings> Alerts > Alerts on this server are = Off
  3. Verify on the site.

Changes appear immediately without any reset.

Before: image

 

After: image

References:

http://technet.microsoft.com/en-us/library/dn178511.aspx

Setting permissions on calendars

A customer want two specifik users to have edit permissions on certain users in the company. It’s many users, is a situation that might have to be done again and again.

So we use powershell for the solution.

First we created a script to check the current permissions to get a baseline of what we’re working with.

foreach ($user in get-content editcalendarusers.txt)

{

write-host "Permissions for user: $user" -foregroundcolor red -backgroundcolor yellow

get-mailboxfolderpermission ${user}:\calendar

}

Where editcalendarusers.txt is a text with one username per line. This is also a good way of validating your editcalenderusers.txt list, to catch any errors or localized boxes.

Since set-mailboxfolderpermissions only can edit existing userpermissions, not add new ones, we first need to run add-mailboxfolderpermission on our userlist. If an account already exist ps throws an error, but no changes are made. Other users already added to the permssions aren’t modified.

First script

----addperm.ps1----

foreach ($user in get-content editcalendarusers.txt)

{

add-mailboxfolderpermission ${user}:\calendar -user john.doe -Accessrights Editor

write-host "john.doe added as editor for $user."

add-mailboxfolderpermission ${user}:\calendar -user charles.doe -Accessrights Editor

write-host "charles.doe added as editor for $user."

}

-----eof-----

Second script

----setperm.ps1.

foreach ($user in get-content editcalendarusers.txt)
{
set-mailboxfolderpermission ${user}:\calendar -user john.doe -Accessrights Editor
write-host "john.doe added as editor for $user."
set-mailboxfolderpermission ${user}:\calendar -user charles.doe -Accessrights Editor
write-host "charles.doe added as editor for $user."
}

---eof-----

If the permissions already are set the second script reports this and goes on to the next line.

One error we ran into was that a few users had changed the language on their mailbox. On these we exchanged the :\calender for the correct folder. In our case :\kalender .

Now obviously we could have made this less static by adding a second loop to process the editors but in this case there were only two so it wasn’t really necessary in this case.

References:

http://technet.microsoft.com/en-us/library/dd298062%28v=exchg.150%29.aspx

Monday, December 02, 2013

Getting your own themes on Sharepoint 2013

In 2010 it was really easy to change the theme. All you needed to was open Powerpoint and make it look good there and then upload and apply the design to 2010.

In 2013 it’s been some changes, to make it less easy. Powerusers, it would seem, have no longer the trust of the Microsoft guys. It wasn’t obvious so here one way to it in 2013.

  1. Download and install Sharepoint Color Palette Tool
  2. Run Color Palette Tool, change Group By to UI Groups to make more logical.
  3. Design to your hearts content, then save file to local drive (ex mydesign.spcolor)
  4. Open Sharepoint Designer to the root of your site collection
  5. Open All Files> _Catalogs\Theme\15\
  6. Drop your mydesign.spcolor in the folder.
  7. Create a new composed look to make it easy to switch to the new design
    1. Site Settings> Web Designer Galleries> Composed Looks>new Item
    2. Point to Theme URL to your mydesign.spcolor
    3. Copy other settings from another Composed theme. Make sure you pick same Master Page as you’ve based your Color Palette theme on.
  8. Now you can pick the new theme from the current site. Note that the composed theme seems to required to be created on every subsite, unless heritage can be activated in some fashion.

 

References:

http://www.microsoft.com/en-us/download/details.aspx?id=38182 – Microsoft Sharepoint Color Palette Tool

http://en.share-gate.com/blog/create-sharepoint2013-theme-using-color-palette-tool – more detailed description on the procedure. Founders of this procedure.