I guess in the new recession economy computing has gotten an interesting metric
. Big $ performance of your program! With Amazon’s S3 charging for space, EC3 charging for computing and Google charging similarly on the app engine platform we have a new metric to reckon Big $ performance of your service/ web-app!
Entries from May 2008 ↓
The New Economy Computing – Big $(n)
May 27th, 2008 — Ideas, News, Programming
Customizing HealthVault Redirection
May 12th, 2008 — ASP.NET, HealthVault
The HealthServiceActionPage gives you a very nice mechanism by which you can declaratively define pages handling various HealthVault shell targets. However, folks frequently run in to situation where they need more dynamic way of redirecting and handling shell targets. A simple scenario is if you want to users to come back to the same URL they clicked after being authorized by healthvault shell, e.g. User clicks and returns to https://www.healthapp.com/username/stats instead of going to the default home https://www.healthapp.com/username/.
Here is a code snippet which illustrates how to extend the HealthServiceActionPage:
using System;
public partial class Redirect : Microsoft.Health.Web.HealthServiceActionPage
{
//We don't want this page to require log on because when we sign out,
//we still want this page to read the WCPage_ActionSignOut key in the
protected override bool LogOnRequired
{
get
{
return false;
}
}
public const String ActionQueryStringValue = "actionqs";
public const String DefaultURL = "http://www.healthapp.com/username";
protected override void OnActionApplicationAuthorizationSuccessful(string action,
string actionQueryString)
{
string targetLocation;
String fullTargetLocation;
string url = Request.QueryString[ActionQueryStringValue];
// TODO: Validate that the URL is from home domain
if (url != null)
{
targetLocation = url;
}
else
{
targetLocation = DefaultURL;
}
// we assume that the query string startswith '?'
fullTargetLocation = targetLocation + actionQueryString;
Response.Redirect(fullTargetLocation);
}
}
The magic is in the OnActionApplicationAuthorizationSuccessful method, which allows us to override the authorization successful target. The HealthVault SDK HealthServiceActionPage now provides us several OnAction
You can also download this code from MSDN Code here.
