Welcome to MSDN Blogs Sign in | Join | Help
Office Web Applications Hits Major Milestone

This is the reason why I haven't been updating my blog lately. We have been heads-down making sure we delivery an incredible user experience in our next release:

Once this product is released, I will be typing up a set of useful blog posts to show-off some really cool features in our new product.

Please continue to send me questions about Excel Services 2007.

 

Excel Services: Charting and Visual Analysis

I have been extremely busy lately and haven't been able to update this blog as much as I would like. However, I have been speaking with many of you frequently over the email. I'm glad I was able to help most of you out. Please keep the questions coming, I love hearing from customers.

Excel Services Charting vs Excel Charting: What's the Diff?

Excel Services Charting work very differently from Excel Charts. Excel Services Charts:

  • Load as PNGs (Pictures) rather than objects
  • Cannot be selected, moved, or created
  • Do not support pictures, or Objects on top of them
  • Do not support gradients
  • Most importantly, all 3D charts are down-converted to 2D charts

However, they do update based on the cell reference that was updated (via Parameters)

Example of a 3D to 2D chart conversion

 

What type of charts are Unsupported?

Surface Charts and Grouped Charts

Excel Services: Saving Workbooks back to the Server

Clients have recently asked questions about Saving workbooks back to the server. In Excel Services, there are several ways to save back to the server. However, the two simplest ways to do it are:

  1. Open in Excel (or Snapshot) using the Client, modify the file, and save it back to the server
  2. Write it back programmatically

Business Scenario:

Nancy is a Chief Information Officer for an Aerospace Engine manufacturer that travels frequently across the world in order to coordinate IT activities and delegate responsibilities. She uses an Excel Spreadsheet to keep track of what each department is responsible for. Since she changes between multiple laptops, she does not keep a local copy of a workbook on any specific computer. This is to prevent her from mistakenly overwriting existing changes she may have made on multiple computers (One-Version-Of-The-Truth). As a result, she has always reliably depended on Excel Services to display and store her workbooks. However, from time to time, she decides to delegate different activities across regional teams and needs to edit a workbook. In these cases, she opens the workbook in Excel and Saves the workbook back to the server in order to maintain a single copy of the truth. How can this be achieved?

How can we Save? 

Method 1: User Interface (Excel)

This is probably the simplest and most popular way users will be saving back to the server.

  • Open the workbook in Excel (or in Snapshot)
  • Edit the workbook
  • Save the workbook in the client back to the server

 Method 2: Programmatically Save As via Excel Client

In some cases, some users might be interested in opening, editing, and saving the workbook back to the server programmatically via Excel Client. Here is some example code that I wrote really quickly to give you an idea (Please tailor this code to your need and do not use it as reliable production code).

SaveAsAppforBlog

Method 3: Programmatically via Excel Services using Binary Writer

This method was documented in MSDN and works pretty well.

 

Once again, if you have any suggestions or comments on how we could make Excel Services exceed your expections, let me know. I love hearing from you.

Excel Services: Snapshot vs Open in Excel - What's the diff?

Let me begin by explaining the two concepts first. When you load a workbook on Excel Services, you are given two options to open the workbook on Excel.

  1. Snapshot: This provides users a copy of the workbook with all the formulas behind the numbers stripped out.
  2. Open in Excel: This provides users with a copy of the original workbook. Changes to the read-only version of this workbook will not appear in the original workbook on Excel Services.

What the Diff?

  • Snapshot has all the formulas behind the numbers stripped out.
  • Some features within snapshot are stripped out: Conditional Formatting

Why have Snapshots?

Security! Again, Snapshot is another excellent example of how Excel addresses security. This technology will allow authors of these workbooks to prevent readers from surfacing formulas (which could be considered confidential).

Business Scenario

Tracy is a Sales Manager that works for a software consultation company. One of her primary tasks is to conduct client visits and advertise how their company could benefit their client. In order to convince her clients of the benefits of working with her company, she would like to provide each client with a workbook indicating how other company's have benefited from using her company's products. This Excel Services workbook contains a chart indicating that their previous anonymous client have reduced their IT expenditure by 35% over 8 months after using their product. However, Tracy does not want to reveal how the number 35% was derived (via external data or other manners). As a result, she provides each potential client with a Snapshot of the original workbook.

 

 Suggestions on how we could make Excel Services surpass your expectation? Let me know.

Excel Services - Only let them see what you want them to see

One of the most impressive controls that Excel Services offers its spreadsheet owners is the ability to limit which parts of the workbook are accessible through the server (IE, sharepoint, API, etc). This is an incredibly powerful ability, especially considering the environment where it is hosted (network).

Why is this so great?

  • A common scenario: Bob needs to report the overall growth of a small financial portfolio. In order to calculate this trend, he needs to use all the customer financial gains (or loses) within this portfolio. All this information is stored on a single spreadsheet. At the end, he creates a chart displaying a global growth trend for this portfolio and wants all his customers to view this impressive data. However, he doesn't want any one customer to know what another customer's financial growth is.


  • Excel Services will:
    • Provide security. Why should users be able to see parts that they have no rights to view or don't need to know about.
    • Make is easy for customers to view the result on a server. (Yes! No more huge email attachments)

 The basic components of Excel Web Access

What can Excel Services publish (or hide)

  • Named Ranges (Essentially a set of cells given a specific name)
  • Charts!
  • PivotCharts
  • Tables
  • PivotTables

Great, but how do I do this?

As easy as 1-2-3. When you finished working on your spreadsheet, all you need to do is:

  • Select the Office Menu Button
  • Select Publish (Save)
  • Select Excel Services options
  • Within the Show tab, select the items you want to show
publish

 

Excel Services: Supported File Format and Features

By now, most of you have probably encountered the following common error while attempting to load legacy Excel workbooks (*.xls). If you didn't, you must have read-up extensively on MSDN. (Congrats to you!)

example1.PNG

File Format 

Well, the reason why this message appears is because you are attempting to Load an unsupported file format. Currently, Excel Services support the following two file formats:

  1. Excel 2007 Workbook (*.xlsx)
  2. Excel Binary Workbook (*.xlsb)

This implies that if you attempt to load a legacy *.xls file, it won't work. The workaround is SUPER simple. Open your legacy workbooks in the Excel 2007 client and Save As *.xlsx or *.xlsb. If you have a large number of Excel 11 or older workbooks, it's actually extremely easy to convert them using a batch script into Excel 12 format in order to make them "server friendly". I will post some of these solutions in later posts.

Unsupported Features?

There are 4 main categories of Unsupported Features in the first release of Excel Services:

  1. Workbooks with Security (Permissions, Digital Signatures, Protections)
  2. External Data Queries (SharePoint Lists, Links to other workbooks)
  3. Graphic Objects (Shapes, SmartArt)
  4. Macros or VBA Solutions

 

 

 

Excel Services: A Good Read

For anyone who is interested in learning more about Excel Services, this is one of my favorite books (not only because it's written by my colleagues):

 XLbook.jpg

I highly recommend reading this one!

Excel Services Trusted Location: Resolving a Common Issue

Excel Services is an enterprise-class application server that is geared towards performance, scalability, and security. Trusted Locations is one of the many excellent example of how Excel Services offer security when managing access to workbooks on the server.

A Trusted Location is one of the following areas that contain workbooks in which the Excel Calculation Services (ECS) is allowed to access. The ECS will only open files located in these trusted locations.

  • SharePoint Document Library
  • UNC Path (\\ServerPath\)
  • HTTP Web Site

How can I Add a Trusted Location? (so that Excel Services can access files in this location)

It is actually really simple to add a Trusted Location:

  • Open SharePoint Central Administration
  • Select Application Management
  • Select Create or Configure this Farm's Shared Services
  • Select your default SSP (probably SharedServices1)
  • Selected Trusted File Locations
  • Select Add Trusted File Location
    • Specify the Address of the location
    • Select the Type (SharePoint, UNC, HTTP)
    • Select Trust Childrens

What is a Common Issue that people run into?

Here is a scenario regarding Trusted File Location and UNC paths that some people that encountered. Nancy attempts to load a Workbook on Excel Services (Excel Web Access) from a UNC location that she set as "Trusted" using the steps indicated above. However, she can't see the workbook. Instead, she sees the following error appear.

11.PNG

This is NOT a bug. What's actually happening is a security feature. Although Excel Services "Trusts" this UNC location, the UNC path is being accessed using Sharepoint authentication (Impersonation by Default) and not your personal authentication; so from the point of view of the UNC path, it's not you that's attempting to access it. As a result, the UNC path will deny access to the ECS.

How can you fix this? (Super Easy Solution)

  • Open SharePoint Central Administration
  • Select Application Management
  • Select Create or Configure this Farm's Shared Services
  • Select Excel Services Setting
  • Select File Access Method > Process Account

12.PNG

How can my Business Benefit?

  • Security

Keep in mind, I love hearing from customers.  

 

How can a Stored Procedure help you?

I had an interesting discussion over lunch yesterday. Someone asked me to explain to them what Stored Procedures are and how their businesses could benefit from using them. Firstly, let me start by saying that I love Stored Procedures (sprocs). I developed Stored Procs for massive schemas at the Canadian Space Agency and they made my life way simpler.

What are they?

Stored Procedures is a subroutine acting as an API to the Database. Since I'm from Excel, my generalized explanation is that they are similar to UDFs. They are completely native to the database server; and as a result, execute complex queries and data access in a far more efficient way than client side code. I generally develop Store Procs using PL/SQL Developer. In summary:

  • They are pre-compiled (Queries)
  • Stored and Executed on the Database Server
  • Secured (if written properly using User Roles)
  • Simplify triggering complex queries

How Can your Business Benefit?

Stored Procedures are excellent subroutines for executing complex queries quickly and frequently. In many cases, they can benefit your business by:

  • Updating database tables using a triggered run
  • Manipulating Database information without providing users with direct access to the database (Security)
  • Creating complex queries and returning them to client side applications without overhead generally introduced by client apps
  • Porting pseudo real time data

If you would like to talk about specifics on Stored Procedures, please let me know. I'm always up for a good discussion.

Installing Excel Services on your Corporate Networks: Quick Reference

I have recently received countless request on providing more information regarding Excel Services installation on a Server Machine (Windows 2003). In this blog post, I will outline a quick overview of a Standalone installation for both 32 bits and 64 bits. A Standalone configuration implies that all the components of Excel Services are placed on a single machine (WFE, ECS, SQL DB).

Basic Procedure:

  1. Ensure that Windows 2003 is installed without a previous version of Microsoft Office Sharepoint Server 2007
  2. Install .NET Framework 2.0
  3. Install .NET Framework 3.0
  4. Within IIS, set ASP.NET 2.0 to "Allow"
  5. Install Microsoft Office Sharepoint Server 2007 (Advance > Standalone)
  6. Once the installation is complete, a Post Setup Configuration dialog will appear. Complete the setup by selecting (Next).

Though this is a very high level view of the installation, it should be sufficient for most standalone deployments. some users may experience issues with Trusted Location, SSP creation, Site Collection creation, and other minor configurations. I will write other entries to address these issues in the near future.

Once again, I love getting feedback from users. If you have any comments, suggestions, or questions regarding Excel Services, please let me know.

Excel Services: Welcome to the future of spreadsheets

Excel Services is a brand new server technology that enables you to Load, Calculate, and Display Excel workbooks on an Office SharePoint Server. Excel Services is currently released with Microsoft Office SharePoint Server 2007.

 There are essentially two ways to interact with Excel Services:

  1. Through an interactive interface provided in the Web browsers
  2. API (Programming Interface)

How can my Business Benefit?

The most frequent scenario that I generally provide users to explain Excel Services is my Financial Consultant example. Mr. Todd travels from client to client providing sound financial advice. Occasionally, he needs to access updated information from his analysts summarizing global market trends and transaction fees on an Excel workbook. However, in order to do this, his analysts email him the latest copy of the workbook and Mr. Todd downloads this workbook onto his clients computer to check the results.

With Excel Services, Mr. Todd will:

  1. Access his workbook with updated data (At the moment of access)
  2. Securely read his workbook without having to worry about forgetting to delete his workbook from his client's computer
  3. Access his workbook on his PocketPC via web browser
  4. Filter unnecessary data using Pivot Tables
  5. Edit Worksheet data by using Parameters
  6. Allow clients to view workbook on their computer without displaying worksheet formulas (Snapshot View)

XL1.bmp

XL2.gif

I will update my blog with many interesting information regarding Excel Services. However, if you have any comments, suggestions, or pain points about this products, PLEASE, let me know. I really enjoy getting any kind of feedback regarding our services.

How to make an easy ASP application to Benefit your team

In a capsule, ASP 3.0 or ASP.NET is a server scripting language that enables programmers to generate HTML or JavaScript code. Since it is server side, clients will not be able to view the server side script by simply using "View Source". As you probably can tell, I generally like to keep my explanations as simple and straightforward as possible. As a result, I won't dwell into too much details.

Why is it so powerful?

  1. It's easy to use (VBS) 
  2. It has Database read and write capabilities (ADO) 
  3. It has file read and write capabilities (FSO)

 How can it benefit your company?

  1. Create web applications with high customization 
  2. Displaying specific real-time data from a database onto your web page and securing protected data from being accessed
  3. Automatomatically generate dynamic websites based on new data
  4. Creating simple search engines (My Favorite)
  5. Parsing Text Files and displaying the results on the web

1. Setting up your computer for ASP development:

Generally, ASP development would be ideal within a server OS; but this is not the only place where it can be developed. Here are some simple steps to setup your system for ASP development.

1.1 Server OS: Windows 2003

  • Select the "Manage Your Server" wizard within "Administrative Tools"
  • Select "Add or Remove a Role" 
  • Select "Custom Configuration"
  • Select "Application Server Role"
  • Select "Enable ASP.NET", this will enable both ASP 3.0 and ASP.NET
  • Select "Manage This Application Server
  • Select "Internet Information Services IIS"
  • Ensure that Default Web Site is running
  • Within the "Web Service Extensions" folder, highlight "Active Server Pages" and click "Allow"

1.2 Client OS: Windows XP Professional

  • Within the "Control Panel", select "Add/Remove Programs"
  • Select "Add/Remove Windows Components"
  • Check "Internet Information Services" and then OK
  • Once the IIS is installed
    • "Inetpub" folder will be created on your C:\
    • "wwwroot" folder will be created within the "Inetpub" folder
    • Within the "wwwroot" folder, create a new folder for your project "MyProject"

 

2. Creating a REALLY Simple ASP program (For some motivation)

When creating your first ASP program, simply follow the proceeding instructions

  • Open NotePad
  • Type the following: <% Response.Write("Hello World") %>
  • Save the file within the "MyProject Folder" as "something.asp"
  • Open Internet Explorer and type the following within the URL: http://localhost/MyProject/something.asp

 

3. Creating a Simple ADO Database Connection

ADO (ActiveX Data Objects) is a common way to read and modify a database from within an ASP page. ADO is installed along with IIS; so no worries there. There are 4 Basic Types of Database Connections via ADO. These connections will enable you to access and manipulate database records. This will open doors to storing information, building mini search engines, and displaying a subset of database data on your web page.

3.1.1 Microsoft Access Database via ODBC (DSN-less)

Dim connection
connection= "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ="& Server.Mappath("./myfirstdatabase.mdb") & ";"

3.1.2 Microsoft Access Database via OLE DB (DSN-less)

Dim connection 
connection = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.Mappath("myfirstdatabase.mdb") & ";"

3.1.3 SQL Server Database (DSN-less)

Dim connection 
connection = "Provider=SQLOLEDB;User Id=username;Password=password; Connect Timeout=15;"

3.1.4 DSN Connection using SQL Server

Dim connection 
connection = "DSN=DSNname; UID=username; PWD=password;DATABASE=databasename"

3.2 Generate a SQL query in order to specify which records you are interested in

Dim qryString 
qryString = "Select Col1, Col2 FROM table1;"

3.3 Create a RecordSet Object that will contain the records obtained from the SQL query and using one of the four discussed connection methods

Dim rs
Set rs = Server.CreateObject("ADODB.Recordset")
rs.Open qryString, connection, adOpenKeyset, adLockPessimistic, adCmdText       'Please note: the last three parameters can be modified based on your needs

3.4 Database Manipulation using the Recordset Object

3.4.1 Database Read

A pointer is pointed at the first record retrieved from the SQL query. In order to display the record that is pointed by this recordset object's pointer, simply use the following syntax:

rs.Fields("Field Name").Value

Example: response.write(rs.Fields("Col1").Value)       'Will display the Col1 field value of the record current pointed by the pointer

3.4.2 Database Write

In order to add a record to the database table, simple add a new row, assign the value, and update the database.

rs.AddNew
rs.Fields("Field Name").Value = "Desired Value"
rs.Update

3.4.3 Moving to the next record in the RecordSet Object

rs.MoveNext

3.4.4 Closing the RecordSet Object

Each time a recordset object is no longer required, ensure that the recordset is closed and pointed to nothing.

rs.Close
Set rs = Nothing

 

And there you go. A simple 10 minute introduction to how you can create a simple ASP application to benefit your team. I will go into further detail in future entries.

A little bit about Me

I guess let me start by saying something about myself before I start rambling about all the cool stuff in Excel. My name is Sherman. I'm a Software Design Engineer in Test (SDET) in the Microsoft Excel Team; a team that I am very proud to be part of. I started this position not too long ago, so I have a very fresh perspective on this product. Over the next few months, I will blog about my learnings and some cool tricks I would like to share with you about Excel.

Education

I graduated from McGill University in Montreal (Canada) with a Bachelor in Electrical Engineering. Before then, I was studying Pure & Applied Sciences at Marianopolis College. I also completed thirteen years of chinese studies.

Work Experience

Before taking on this position at Microsoft in Redmond, I attempted a variety of internships and career paths. The thirst for Engineering began with my two summer internships at Pratt & Whitney Canada. My career began in the Satellite Operations department at the Canadian Space Agency where I was responsible for developing, testing, and releasing a real-time product structure oriented server-side application used for the maintenance and operation of the SciSat and RadarSat-1 satellites. This application was awarded a spot at the SpaceOps2004 conferences held in Montreal. After this, I explored the hardware industry at Matrox Electronic Systems as a FPGA-ASIC Validation Specialist, where I took part in designing, developing, and testing several medical imaging boards. Finally, I attempted to explore the Aerospace industry once again at CAE as a System Software Specialist in the Air-to-Air Tactics and Analysis division for the CF-18 aircraft; where I was responsible for developing and designing real-time embedded software for Missiles and GPS Navigational systems.

Presently, I feel that I have finally found the company that fits me best and provides me with the tools to build a strong and fun career. Based on the companies that I have worked for before, I really appreciate my career here at Microsoft. This is definitely the best company to work for.

Page view tracker