Microsoft Office Files Viewer

Background

Needed to quickly review Microsoft Excel files.

As I don’t have Microsoft Office installed on the server that I was connected to at the time, wanted to install a light weight version.

That version is Excel Viewer.

Microsoft

How to obtain the latest Excel Viewer

Retired

How to obtain the latest Excel Viewer
Link

Image

microsoft.office.viewer.retired.20190317.1046AM.PNG

Textual

Excel Viewer has been retired

Important: The Microsoft Excel Viewer was retired in April, 2018. It is no longer available for download or receive security updates. To continue viewing Excel files for free, we recommend installing the Excel mobile app or storing documents in OneDrive or Dropbox, where Excel Online opens them in your browser.

Explanation

  1. Retired
    • So since April 2018, Microsoft Excel Viewer has been retired
  2. Alternatives
    • Platform
      • Desktop
        • Not available
      • Mobile Apps
        • Available
    • Online Storage
      • OneDrive
      • Dropbox

 

Alternate Download Sources

MS Office Excel Viewer

  1. Github
    • Github/DanielAdeniji
  2. Spreadsheto.com
    • Excel Viewer
  3. vessoft.com
    • Excel Viewer

 

MS Office Word Viewer

  1. Github
    • Github/DanielAdeniji
  2. vessoft.com
    • Word Viewer

Summary

So if you need to access Microsoft Office files and you do not have a corporate license or do not have installed on the computer you are using, please consider per-using the links above.

Microsoft – Access Database Viewer

Background

Have a database that I need to review.

Unfortunately it is a Microsoft Access Database and I do not have Access installed.

And, so googled for opportunities.

Sample Databases

You likely want to try things out against sample databases before hand.

Here are some sample databases that are available online.

  • Microsoft Office Access 2010
    • Links
      • Download Sample Databases
        Link

 

Tools

Here are some sample databases that are available online.

  • Online
    • Maklabu GmbH
      • MDB Opener
  • Desktop
    • Alex Nolan
      • MDB Viewer Plus

Error :- The Microsoft Access database engine cannot open or write to the file. It is already opened exclusively by another user, or you need permission to view and write its data.

Background

Debugging an application and thankfully I have managed to add good exception handling.

Error

Here is the error message :-

Error Image

err_20181203_0532PM

Error Text


Attempt to connect to Provider = Microsoft.ACE.Oledb.12.0;User ID = Admin;Data Source=\\hrdb\payroll\payroll.mdb failed.
Exception Type is System.Data.OleDb.OleDbException
Exception Message is The Microsoft Access database engine cannot open or write to the file '\\hrdb\payroll\payroll.mdb'. It is already opened exclusively by another user, or you need permission to view and write its data.
Error Code is -2147467259
Error Source is Microsoft Access Database Engine
Error Inner Exception is
Stack Trace is at System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection)
at System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup)
at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
at System.Data.OleDb.OleDbConnection.Open()
at intc.svc.timer1_Elapsed(Object sender, ElapsedEventArgs e) in C:\\Service1.cs:line 339

Remediation

I watched the connection string over and over.  Installed the Database Connectivity driver and no good.

Finally, I accepted the error message.

Error Message :-

The Microsoft Access database engine cannot open or write to the file ‘\\hrdb\payroll\payroll.mdb’. It is already opened exclusively by another user, or you need permission to view and write its data.
Error Code is -2147467259.

The keyword is need permission to view and write.

The contextual user did not have the permission needed.

Microsoft – Excel – SubTotals

Background

I have a situation where I need to summarize some data and I don’t really want to do so in a database.

 

SQL Server

In Database we have roll-up and Windowing Functions.

And, it is really likely the way I should go.

 

Excel

But, as the data is not in a database, I will really rather not bring it in.

I will just use Excel and send the Excel file to our business partner.

 

Data in Excel

Menu

Menu – Data

Menu – Data – Outline

 

SubTotal

Subtotal – Process – Category – Country

Click the Data menu option.

Select the range of data by clicking on the column header as well on last data row.

Click the Subtotal menu option…

Subtotal –  Operation

Image

Explanation

  1. At each change in : Country
  2. Use function :- Sum
  3. Add Subtotal to : Population
  4. Replace current options :- Checked
  5. Page break between groups :- Not Checked
  6. Summary below data :- Checked

 

Subtotal –  Results

Image

Explanation

  1. We have subtotals for our two countries, Canada & US
  2. And, we have a Grand Total

Subtotal – Process – Category – State

Subtotal –  Operation

Image

Explanation

  1. At each change in : State
  2. Use function :- Sum
  3. Add Subtotal to : Population
  4. Replace current options :- Not Checked
  5. Page break between groups :- Not Checked
  6. Summary below data :- Checked

 

Subtotal –  Results

Image

Explanation

  1. We have subtotals for State/Regions
  2. Cumulative subtotals for the countries
  3. And, we have a Grand Total

 Summary

To add secondary sub-totals please make sure to un-check “Replace current options” in the subtotal window.

 

Powershell Modules – AzureAD – “Get User’s Information “

Background

Now that we have “AzureAD” Powershell modules installed, let us play around with it.

First off, the let us review what type of information is returned on a Member Account.

 

Code

Outline

  1. Using CmdletBinding define our script argument list
  2. To connect to our “Tenants Domain“, Issue “Connect-AzureAD
  3. To get specific AD Accounts, call get-azureaduser and filter appropriately
    • Get the returned object type by issuing GetType().Fullname
    • Get the first item in the result list by issuing Select-Object -first 1
    • Get Object’s Property list by issuing Select-Object -Property *
    • Display PropertyList

 

Actual Code

 


[CmdletBinding()]
Param(
  [Parameter(Mandatory=$True,Position=1)]
   [string]$personName
	
)
Set-StrictMode -Version Latest;

#Connect to Azure AD
Connect-AzureAD

# get list of AD users that matches the name passed in
$objListofPerson = get-azureaduser -Filter "startswith(displayName,'$personName')"


# if List is empty, then say so
if (!$objListofPerson)
{
     "Object (objListofPerson) is null (empty)"
     return
}
 
# Keith Hill - Get Type name
# the-typename-and-inheritance-chain/
# http://rkeithhill.wordpress.com/2007/10/28/powershell-quicktip-using-pstypenames-to-see-# 
$strLog = "Type name is " + $objListofPerson.GetType().Fullname;
$strLog
 
# Get top item in list
$objPerson = $objListofPerson | Select-Object -first 1

# if List is empty, then say so
if (!$objPerson)
{
     "Object (objPerson) is null (empty)"
     return
}
 
#https://www.codykonior.com/2013/03/26/powershell-how-to-show-all-of-an-objects-properties-and-values/
$objPersonPropList = $objPerson | Select-Object -Property *

if (!$objPersonPropList)
{
	 "Object has no properties"
	 return
}

$objPersonPropList

Invoke

Syntax


powershell -file ./Office365AzureAccount.ps1 -personName "[personName]"

Sample


powershell -file ./Office365AzureAccount.ps1 -personName "Daniel Adeniji"

Output

Images

Image – 01

Image – 02

Image – 03

Image – 04

 

Tabulate

  1. Type
    • Type name is Microsoft.Open.AzureAD.Model.User

Source Code

GitHub

DanielAdeniji/Office365AzureADPowerShell
Link

 

References

  1. Microsoft Azure
    • Azure/Azure PowerShell
      • Connect-Azure
        Link
      • GetAzureADUser
        • GetAzureADUser
          Link
  2. PowerShell
    • PowerShell Parameters
      • Don Jones
        • Windows PowerShell: Defining Parameters
          Link
    • PowerShell Properties
      • Cody Konior
        • PowerShell: How to show all of an object’s properties and values
          Link
    • PowerShell List
      • Don Jones
        • How can I get just the first entry from a list of entries?
          Link
  3. AzureAD Powershell
    • GetAzureADUser
      • StackOverflow
        • Example of Get-AzureADUser [-Filter <String>] command
          Link

Powershell Modules – AzureAD – Installation

Background

Needing to do some minimal Microsoft Office 365 work.

Found out that I need Azure Powershell Modules.

Requirement

The Azure Active Directory ( AD) Powershell Modules are available on Microsoft’s Powershell Gallery.

Here is Microsoft’s write-up of what it takes to access the gallery and download modules from it:

Image

Azure Active Directory PowerShell for Graph
Link

Tabulate

Product Version Prerequisite
Operating System ( OS) Windows 10
Windows Management Framework ( WMF ) WMF v5.0
PackageManagement PowerShell Modules Preview – March 2016 v1.1 Powershell v3.0 or v4.0

 

Do we meet the requirement?

Let us do a quick check to determine whether we meet the requirement.

OS version

WinVer

From Console, issue winver

Syntax

winver

Output

Explanation

We are looking to have Windows Version 10, we are only at Version 7.

 

WMI Version

WMI Version – Using Powershell

From Console, run powershell and query $PSVersionTable

Syntax

Powershell -Command "$PSVersionTable"

Output

Explanation

We are looking to have WSManStackVersion be at v5.0, but we are only at v3.0.

 

Powershell – Module – PackageManagement

PackageManagement Powershell Modules

In Powershell issue “Get Module -ListAvailable

Syntax

powershell -Command "Get-Module -Name *Package* -ListAvailable"

Output

Explanation

We appear to be good with the Powershell Module Package Management.  The version installed is 1.*.

 

Meeting Requirement

If we did not meet the requirements, here are options to do so.

Windows Management Framework ( WMF )

Version

Version 5.1

As of 2018-Jan-21st, the latest version of WMF is 5.1 and it is available here.

Powershell – Module – PackageManagement

Go here and download the module that fits your your OS bitness.

 

Review Installation

Current

Let us quickly see whether we have the Azure Powershell Module installed.

Syntax

The module’s name is AzureAD and so we can look for anything bearing the Azure moniker.


powershell -Command "Get-Module -Name *Azure* -ListAvailable"

Output

Explanation

Nada

Actual Installation

Syntax


powershell -command "Install-module AzureAD"

Output

Explanation

We confirmed that we are OK with downloading modules from PSGallery.

 

Installation Validation

Syntax


Powershell -Command "Get-Module -Name *Azure* -ListAvailable"

Output

Explanation

We now have AzureAD installed.

The current version is 2.0.x.x

 

References

  1. Microsoft Azure
    • Azure PowerShell
      • Azure Active Directory PowerShell for Graph
        • Installation
        • How can I find the version of the Azure AD PowerShell module I’m using?
          Link

Sharepoint – Export List – Error – “To export a list, you must have a Microsoft SharePoint Foundation-compatible application”

Background

Trying to export a SharePoint List, but getting the prompt and error pasted below.

Prompt

Do you want to open or save owssvr.iqy from sp..

Textual

Do you want to open or save owssvr.iqy from sp..

Image

Error

Error – SharePoint Foundation-Compatible Application

Textual

To export a list, you must have a Microsoft SharePoint Foundation-compatible application.

Image

 

TroubleShooting

Microsoft SharePoint Foundation Support

Is “Microsoft SharePoint Foundation Support” installed?

Accessed “Control Panel \ “Add or Remove Programs” \ “Microsoft Office Professional Plus 2010” \ Changed and made sure that “Microsoft SharePoint Foundation Support” is checked

 

Microsoft Office

Check MS Office Version #

MS Word

Using MS Word Help/About, check Version#

Image

Version Info:

Product :- Microsoft Office Professional Plus 2010
Version # :- 14.0.7184.5000 ( 32-bit)

Version Matrix

Image

Tabulate
Product Version Version# – Low Version# – High
Office 2010 – RTM 14.0.4763.1000 14.0.6029.1000
Office 2010 – SP1 14.0.6029.1000 14.0.7015.1000
Office 2010 – SP2 14.0.7015.1000

 

Explanation

Our current version # is 14.0.7184.5000.

And, SP2 is at minimum 14.0.7015.1000.

 

Microsoft Office – Repair

Image

Control Panel \ All Control Panel Items \ Programs and Features – Uninstall or Change

Microsoft Office Professional Plus 2010 – Change your Installation of Microsoft Office Professional Plus 2010

Microsoft Office Professional Plus 2010 – Configuration Progress

Repairing Microsoft Office Professional Plus 2010 ….

Microsoft Office Professional Plus 2010 – Configuration Complete

The configuration for Microsoft Office Professional Plus 2010 is complete.
To make your changes take effect, exit and restart and open Office Programs.

Microsoft Office Professional Plus 2010 – Configuration Complete

In order to complete setup, a system reboot is necessary.
Would you like to reboot now?

Validation

Post system reboot, launch Internet Explorer and revisited SharePoint List

Images

Microsoft Excel Security Notice

Microsoft Office Has identified a potential security concern

Textual

Microsoft Office Has identified a potential security concern.

Image

Excel

Exported List

Summary

To address the error “To export a list, you must have a Microsoft SharePoint Foundation-compatible application“, we were getting we simply repaired our microsoft Office 2010 installation.

In some cases one needs to apply the latest Service Pack, but we verified that we are already on the latest SP.

 

References

  1. Microsoft
    • Technet
      • Kim P – MSFT
        • To export a list, you must have a Microsoft SharePoint Foundation-compatible application
          Link
    • Support
      • Description of Office 2010 Service Pack 2
        Link