Thursday, 2 July 2015

Using Outlook 2016 without Exchange AutoDiscover

re: Problem getting Outlook 2016 connected to Exchange
re: Outlook 2016 is missing Exchange account set-up

Disclaimers:
1. This post is written on 3 July 2015, when Outlook 2016 is still in preview. Nothing is set in stone, but it is very relevant at this point in time.
2. Making changes to the system registry can damage your machine, sometimes even beyond repair. If you do not accept the risks, do not follow these instructions.

Apparently, after several searches on Google for ways to get Outlook 2016 Preview working with our Exchange server, it turns out the option has been removed.  Compare the options available for Outlook 2013 (top) and Outlook 2016 Preview (bottom):

Outlook 2013 Mail Options

Outlook 2016 Mail Options
An Outlook MVP has this to say on the Microsoft Answers forum regarding this change:
Outlook 2016 can only add Exchange accounts using autodiscover. This is a change from Outlook 2013. If you want to use Outlook 2016 with an Exchange account, you need to use autodiscover.
and this
As far as I know, they have no plans to change it. If your employer doesn't have autodiscover configured, you won't be able to use Outlook 2016 to connect using Exchange services.
From my research, there appears to be a window of opportunity in that upgrades from Office 2013 to 2016 can retain the Exchange setup.  This led me to think that connection to Exchange is only broken (intentionally!) from the UI, which is good in the sense that as long as you can get the profile into the system, all will be well again.

It turns out Outlook profiles are stored in the registry.  So, as long as you have a working Outlook 2013 profile somewhere connected to Exchange already, you can "import" it into Outlook 2016 using three simple steps:

  1. Start the registry editor, e.g. Start > Run > Regedit.
  2. Browse to HKEY_CURRENT_USER\Software\Microsoft\Office\15\Outlook\Profiles.
  3. Right-click on "Profiles" and click on "Export". Choose a location to save the registry file.
  4. Edit the registry file saved in step 3, e.g. open in Notepad.
  5. Search for "Office\15.0" and replace-all with "Office\16.0". Save the file.
  6. Double-click on the registry file and answer "Yes" when asked to continue.
  7. Start Outlook 2016 (Preview).
Congratulations, Outlook 2016 is now connected to your Exchange server!


Sunday, 28 June 2015

No-IP Windows Script (VBS) updater

This post concerns Windows clients.  There are plenty of other similar scripts for Linux/OSX - just search on Google.

PowerShell is the future, but there are yet some machines in the past or present. So I chose instead to use plain old tried and true VBS which works for Windows XP through 2012 R2.
Paste the below content into a text document, and give it a good name with an extension of ".vbs".

strFileURL = "https://api.ipify.org"
Set objXMLHTTP = CreateObject("Microsoft.XMLHTTP")
objXMLHTTP.open "GET", strFileURL, false
objXMLHTTP.send()
myIP = objXMLHTTP.responseText
updateURL = "https://dynupdate.no-ip.com/nic/update?hostname=sdrc.ddns.net&myip=" & myIP
Set objXMLHTTP2 = CreateObject("Microsoft.XMLHTTP")
objXMLHTTP2.open "GET", updateURL, false
objXMLHTTP2.setRequestHeader "Authorization", "Basic <your credentials*>"
objXMLHTTP2.setRequestHeader "User-Agent", "Custom NoIP Update Client weonlydo@mailinator.com"
objXMLHTTP2.send()
Use Windows Task Scheduler to run it.  The main trigger to use is "On startup", but because the network interface may not be ready at startup, it may work best to edit the trigger properties and add a small delay (e.g. 30 seconds).  To get maximum coverage, you could have two startup triggers, one immediately, and the other delayed by two minutes.

Some notes about the scheduled task:

  1. Use the System account, or choose a user and provide a password, both will work
  2. You cannot use the VBS file as the "Start Program" directly. Use "cscript" as the program, and the full path of the file in double quotes as the "arguments"
About credentials:

Replace <your credentials> in the script with the base-64 encoded version of your credentials used to log into the No-IP website. e.g. if you log into No-IP using

email: my@email.address
password: mynoippassword

The authorization string would be "Basic bXlAZW1haWwuYWRkcmVzczpteW5vaXBwYXNzd29yZA=="

The site https://www.base64encode.org/ is useful for converting your credentials into the base-64 encoded format.  In the top part, enter "my@email.address:mynoippassword" without quotes and press the "Encode" button.  If you end up with the same code as the above paragraph, congratulations - you have done it correctly.  Now you can encode your own credentials and paste into the script.


References:

Here is the official documentation for updating your Dynamic DNS entry at No-IP.