Tag | API Posts

Unfortunately, in the current version of the Windows Phone 7 Silverlight framework, it is not possible to attach any command on the ApplicationBarMenuItem and ApplicationBarButton controls. These two controls appear in the Application Bar, for example with the following markup:

Read the rest of this entry »

One of the things that might be surprising in the LINQ Distinct standard query operator is that it doesn’t automatically work properly on custom classes. There are reasons for this, which I’ll explain shortly. The example I’ll use in this post focuses on pulling a unique list of names to load into a drop-down list. I’ll explain the sample application, show you typical first shot at Distinct, explain why it won’t work as you expect, and then demonstrate a solution to make Distinct work with any custom ...
To be honest I have not been very interested in the caching before I’m going to a project which would be using the multi-site deployment and high connection and concurrency and very sensitive to the user experience. That means we must cache the output data for better performance. After looked for the Internet I finally focused on the Memcached. What’s the Memcached? I think the description on its main site gives us a very good and simple explanation. Free & open source, high-performance, distributed ...
In this Issue: Michael Washington, Hassan, David Anson, Jeff Wilcox, UK Application Development Consulting, Davide Zordan, Victor Gaudioso, Anoop Madhusudanan, Phil Middlemiss, and Laurent Bugnion. Shoutouts: Josh Smith has a good-read post up: Design-time data is still data Shawn Hargreaves reported his MIX demo released From SilverlightCream.com: Silverlight MVVM: Enabling Design-Time Data in Expression Blend When Using Web Services Michael Washington has a tutorial up on MVVM and using a web service ...
When an USB Disk plugs into CE/Mobile based device, how do you know the folder name of the mounting point? Usually, it should be "USB Disk" but it is really depends on how OS image builder; they may change the folder name for whatever reason. FindFirstFlashCard looks simple and promising, the drawback is it only available on Windows Mobile. In fact, these find flash card API set will enumerate all of the mountable file system which includes SD card, CF and etc that we don't expect to get. So I am ...
I’ve always enjoyed using Nick Gravelyn’s exception handling in all of my games. You’re always going to encounter those unhandled exception that your players are going to ferret out and having a method to display them rather than just crashing to the dashboard is definitely more of an elegant solution. But the other day I got to thinking…what if we could do more? What if instead of just displaying the error, we could encourage the players to send us the error. So I started playing with that an expanding ...
For those of you who missed the chat today, here is the raw transcript. By raw, I mean that I copied and pasted the discussion without any edits. This is divided into two parts, the top part is the answers from the Microsoft Experts and the bottom part is the questions from the audience. Answers from Microsoft: Karel Danihelka [MS] (Expert)[2010-3-30 12:2]: Hi everyone, my name is Karel Danihelka and I am developer in partner response team. Sing Wee [MS] (Expert)[2010-3-30 12:2]: Hi, I'm Sing Wee, ...
In this post, we are going to look into implementing lists into our twitter application and also about enhancing the data grid to display the status messages in a pleasing way with the profile images. Twitter lists are really cool feature that they recently added, I love them and I’ve quite a few lists setup one for DOTNET gurus, SQL Server gurus and one for a few celebrities. You can follow them here. Now let us move onto our tutorial. 1) Lists can be subscribed to in two ways, one can be user’s ...
In this post, we will look at implementing the following in our twitter client - displaying the profile picture in the home page after logging in. So to accomplish this, we will need to do the following steps. 1) First of all, let us create another field in our Global variable static class to hold the profile image url. So just create a static string field in that. public static string profileImage { get; set; } 2) In the Login.xaml.cs file, before the line where we redirect to the Home page if the ...
In this Issue: René Schulte, Jeremy Likness, Hassan, Victor Gaudioso, SilverLaw, Mike Taulty, Phani Raj, Tim Heuer, Christian Schormann, Brad Abrams, David Anson, Diptimaya Patra, and Daniel Vaughan. Shoutouts: Last week, Koen Zwikstra announced Silverlight Spy at MIX10 Anand Iyer announced this for students on the Windows Team Blog: Be a Windows Phone 7 “Rockstar” Justin Angel blogged that Silverlight Isn't Fully Cross-Platform ... let him know if you think it's a yawn or important. On behalf of ...
So I blatantly got this idea from the MIX 10 event. At MIX they held a rockband talent competition type thing (I’m not quite sure of all the details). But the interesting part for me is how they collected votes. They used Twitter (what else, when you have a few thousand geeks available to you). The basic idea was that you tweeted your vote with a # tag, i.e #ROCKBANDVOTE vote Richard How cool…. So the question is how do you write something to collate and count all the votes? Time to press the magic ...
[Did I overdo the use of FREE in the title? :-)] April 12th to 16th is Microsoft Tech Days – 5 days of sessions on Visual Studio 2010 through to Windows Phone 7 Series. Many of these days are now full (Tip - Thursday still has room if rich client applications is your thing) but the good news is the development community in the UK has pulled together an awesome series of “fringe events” during April in London and elsewhere in the UK. There are sessions on Silverlight, SQL Server 2008 R2, Sharepoint ...
Today, I released LINQ to Twitter v2.0.8. Besides normal maintenance, this release includes the Twitter Geo API and the Suggested Users API. LINQ to Twitter is hosted on CodePlex.com: http://linqtotwitter.codepl... In addition to new functionality, I've made much progress toward LINQ to Twitter documentation; primarily in the Making API Calls area: http://linqtotwitter.codepl... There's also a discussion forum where you can ...
ASP.NET MVC 2 Features ASP.NET MVC 2 adds a bunch of new capabilities and features. Some of the new features and capabilities include: § New Strongly Typed HTML Helpers § Enhanced Model Validation support across both server and client § Auto-Scaffold UI Helpers with Template Customization § Support for splitting up large applications into ‘Areas’ § Asynchronous Controllers support that enables long running tasks in parallel § Support for rendering sub-sections of a page/site using Html.RenderAction ...
Message Buffer is WCF queue in the cloud (although currently it does not provide all features of WCF queue). With on-premise WCF, you can take advantage of MSMQ, so that a message is sent to MSMQ by one endpoint, and another endpoint can get the message in a later time. The message is usually a SOAP message so that you can generate a client proxy and invoke the service operations just as invoking a normal WCF operation. Message Buffer is similar, but it also provides a REST API for you to work with ...
Windows Azure Diagnostics Managed Library: The new Diagnostics API enables logging using standard .NET APIs. The Diagnostics API provides built-in support for collecting standard logs and diagnostic information, including the Windows Azure logs, IIS 7.0 logs, Failed Request logs, crash dumps, Windows Event logs, performance counters, and custom logs. Variable-size Virtual Machines (VMs): Developers may now specify the size of the virtual machine to which they wish to deploy a role instance, based ...
Topic: nServiceBus is mature and powerful open source framework that enables to design robust, scalable, message-based, service-oriented architectures. Latest improvements in the configuration API enables developers to quickly get started and build a working simple system that uses messaging infrastructure. The goal of this session is to give a jump start with the framework, introduce basic concepts such as message handlers, Sagas, Pub/Sub, Generic Host and also create a working demo application ...
Another March, another MIX. For the fifth year running now, Microsoft has chosen to put on a conference aimed less at software development, per se, and more at the products, experiences and designs that software development can generate. In all four prior MIX events, the focus of the show, its keynotes and breakout sessions has been on Web products. On day 1 of MIX 2010 that focus shifted to Windows Phone 7 Series (WP7). What little we had seen of WP7 had been shown to us in a keynote presentation, ...
Right now they are ‘free’ but it is clear what the path forward is: 4.3 Advertising. The Service currently does not include advertising in the maps images. However, Google reserves the right to include advertising in the maps images provided to you through the Service, but will provide you with ninety (90) days notice prior to the commencement of advertising in the maps images. Such notice may be provided on relevant Google websites, including but not limited to the Google Geo Developers Blog and ...
One of the biggest questions I routinely get asked is how scalable Commerce Server is. Of course the text book answer is the product has been around for 10 years, powers some of the largest e-Commerce websites in the world, so it scales horizontally extremely well. One argument however though is what if you can't predict the growth of demand required of your Commerce Platform, or need the ability to scale up during busy seasons such as Christmas for a retail environment but are hesitant on maintaining ...
I always thought that the NUnit test runners and the test assemblies need to reference the same NUnit.Framework version. I wanted to be able to run my test assemblies with the newest GUI runner (currently 2.5.3). Ok so all I need to do is to reference both NUnit versions the newest one and the official for the current project. There is a nice article form Kent Bogart online how to reference the same assembly multiple times with different versions. The magic works by referencing one NUnit assembly ...
In this post we'll look at the AlphaBlend() api and how it can be used for semi-transparent blitting. AlphaBlend() takes a source device context and a destination device context (DC) and combines the bits in such a way that it gives a transparent effect. Follow the links for the msdn documentation. So lets take a image like, and AlphaBlend() it on our window. The code to do so is below, (under the WM_PAINT message of WndProc) HBITMAP hBitmap=NULL, hBitmapOld=NULL; HDC hMemDC=NULL; BLENDFUNCTION bf; ...
Quick Links Adding Volcanos and Options - Earthquake Locator, part 2 Live Demo Source Code The recent wave of earthquakes (no pun intended) being reported in the news got me wondering about the frequency and severity of earthquakes around the world. Since I’ve been doing a lot of Silverlight development lately, I decided to scratch my curiosity with a nice little Bing Maps application that will show the location and relative strength of recent seismic activity. Here is a list of technologies this ...
Identify early adopters Pick a small project with a small(ish) team. This can be a legacy application or a green-field application. Strive to find a team of early adopters that will be eager to try something new. Get the team on board! Research Research the tool(s) that you want to use. Some tools provide all of the features you would need while some only provide a slice of the pie. DBVCS requires the ability to manage a set of change scripts that update a database from one version to the next. Ideally ...
The .NET community, unlike the Java and python community do not provide Data Mining solutions outside the framework of their RDBMS MS SQL Server. In my quest to integrate Data mining into an existing ASP.NET enterprise solution running on MySQL, i was faced with quite the task! In attempting to review existing solutions, i followed the following criteria: Open-source and free (not necessarily the same thing!) GUI for interactive data mining and exploration Concise, accessible and well documented ...
A colleague asked me how GPSAPI.lib is built and makes it into the SDK. So we found ourselves in a long discussion which included a massive flow diagram on a whiteboard. In this article, I am going to try to reproduce what we ended up with on the whiteboard, but frankly on the whiteboard it was easier to draw. My colleague had tried to build GPSAPI by opening a build window and running build in the GPSAPI folder. What he did was: In doing so, he built some source code in the public tree, and the ...
Last week, I needed to call the SQL Reporting Services Web Service to export reports as Excel, PDF, and Word formats. I could have used the [Add Web Reference...] as the MSDN Documentation Accessing the Report Server Web Service Using Visual Basic or Visual C#, but I decided to use [Add Service Reference...]. If you are wondering what the difference is between Web Reference and Service Reference, please read this blog post by Andrew Tokeley. Goal Create a common library project which I could reuse ...
Remember the Process Viewer that we worked on a few months back? I was wondering how to display the applications icons, the way task manager does. A small icon beside the application name gives it a pleasant look. So how do you extract the icon from an executable? Well, there's an API for that (pun). ExtractIconEx() is the function we use to get a handle to the applications icon. It's a simple API, just give it the full path to the executable and it returns an HICON (icon handle). So I went back ...
After working with FluentNHibernate and seeing examples of registries in StructureMap, I started craving the same thing for my registrations with Windsor. Our registrations often look like the following: public static void Register(IWindsorContainer container) { container.Register(Componen... container.AddComponent<I... Foo>(); ... } There are a few things I don’t like about this approach: Passing a container around through static methods is a hack. ...
This is the second guest post from Gil Zilberfeld who works at TypeMock and kindly agreed to do a couple of guest posts on Mocking . The first was an Introduction to Mocking. Typemock Isolator – Much more than an Isolation framework In my last post, I showed how to fake a dependency. But this involved doing a couple of things. First, it involved changing the original method. Then, I had to write wrappers (a real wrapper and the fake wrapper) and finally, I had to inject the fake object in the test. ...
New Visual WebGui Rich Ajax Applications Platform versions released. 6.3.14 includes some additional stabilization fixes for the on-going support for 6.3. A new beta1 version c of the cutting-edge Visual WebGui 6.4 was also released with a large set of features and a much more complete set of compatibility with the WinForms API and the enhanced developer/designer interfaces and new customization capabilities such as jQuery support. All downloads are free via this link ...
Reflection has always fascinated me. Here a small reusable API to invoke methods dynamically. This uses local caching for optimization and takes care of multithreading as well.. You can use this class in a dll or a webservice..... Pass this method the following parameters.. 1. dllPath : The path to the dll. 2. className : The type to load dynamically 3. methodName : The method to invoke 4 pInput[] : The input parameters if any. private static Hashtable AssemblyHash = new Hashtable(1024); private ...
I'm actually somewhat amazed that there are only 16 downloads (or so CodePlex says) for the 1.0 release of AutoFixture. I had heard about it a while ago, but due to lack of time didn't actually get a chance to try it out until today. Please, PLEASE don't make the same mistake in delaying getting and using it for as long as I did, because frankly, it rocks. I won't go into details on what AutoFixure is, except say that it will help you write better, cleaner unit-tests and also because I wouldn't do ...
To download the source code please click here Introduction Claim-based authorization is a new model of authorization introduced in Windows Communication Foundation. This model addresses more scenarios than the popular role based security model (IIdentity, IPrincipal). This is useful when an application requires complex and fine grained control on expressing access control decisions. Role based security model may not be powerful or flexible enough and is often too coarse when we reach complex scenarios ...
The Twitter Search API returns an XML Atom formatted feed. So, in LINQ to Twitter, I've created an Atom object, which I return when someone performs a search. The problem with the results is that the ID of the Status is mangled with other information. To solve this problem, you need to extract the status ID from the number following the last colon of the ID from the search Entry. Here's some code to show how it's done: private static void SearchAndUseStatusTwitterDe... twitterCtx) { ...
In our new project, we've decided to use FitNesse with slilm. All in all, slim is an improvement over fit. The thing I like most is the error messages when running tests. These are now much clearer than with fit. The fixtures are now plain old objects (that's poo -- you can call them pojo, poco or even pono for all I care). So no dependency anymore on fit. Slim is also supposed to run faster, but right now our project is not really big enough to notice the difference. There's two things I don't like ...
This article is a two-part series regarding the LinqToWikipedia provider. The first article covers the basic concepts of Linq as well as the client usage of this particular provider while the second article covers the inner workings of the LinqToWikipedia provider to give you an understanding of what it takes to create your own IQueryable provider. NOTE: You should download the latest build from Codeplex so you can follow along with the code samples. Creating your own IQueryable provider First off ...
Previously - Fun with menus - Part I A few days back I set about trying to get radio items into menus. This is helpful if you want only one of the items in the menu to be active at a time, say, for e.g. a "Select Level" popup menu which has "Level 1", "Level 2" and "Level 3" subitems and only one of them needs to be shown as active or currently selected. You get the idea. No? Here, this pic should help, A bit of searching led me to the CheckMenuRadioItem() API, and I thought, this is simple. I just ...
In this post, we will get ourselves familiar with one of the popular Twitter API – Twitterizer & the famous Facebook SDK which was recently released by Microsoft. We will be using them in quite few of our up coming project will be doing in the near future. Go to these pages and make sure you download the packages and have the DLLs ready. “Twitter”izer This is very famous .Net library to enable easy communication with Twitter. The official Google Code page for this is - http://code.google.com/p/tw... ...
We are excited to announce that Visual WebGui 6.4 client is going to adopt jQuery as its client engine in order to provide better support for cross browsers, enhanced UI behaviors and most important provide a familiar API to write Visual WebGui extensions such as custom controls and utilizing different protocols such as JSON and REST. jQuery is a lightweight open source JavaScript library (only 15kb in size) that in a relatively short span of time has become one of the most popular libraries on the ...
2010 is going to be a busy year for me. The latest release of Commerce Server 2009 (Codenamed "R2" ) scheduled to be released at some time this year, and the CTP's are literally "flying" out of the product team's office and on to the Internet – with some great enhancements around deployment, and the Commerce Foundation API. I'll write a post about the updates and changes later this week, however one of the major enhancements is the removal of the dependency of Commerce Server assemblies to be present ...
For me one of the coolest new features added in Silverlight 4 is support for capturing video and audio using webcams and microphone. As we’ve seen during Scott Guthrie’s keynote demonstration it is now possible to capture image frames from video stream and apply some interesting effects to it. On top of that we can even process the video and audio streams directly on the client (i.e. inside the browser). Because Silverlight 4 Beta was already available at PDC I could try the webcam support right ...
Back when I was an Application Architect working with UK ISVs I spent a lot of time helping companies understand how to architect multi-tenanted applications. However, I have never pondered about the challenges (and opportunities) of doing this with Windows Azure and SQL Azure. Until now. What sparked it off was a fairly simple question from a UK ISV that I ended up copied on. The question in essence was “What is the recommended approach to building a multi-tenancy solution on Windows Azure and SQL ...
I talk to Hadi Hariri about the differences between Behavior Driven Development (BDD) and Test Driven Development - and why Hadi chooses BDD every time. Hadi wrote an article on BDD for the December 2nd 2009 UK MSDN Flash newsletter: “Test Driven Development (TDD) is about design, not about testing first. We use unit tests and testing frameworks to drive out the design of our API and validate its usage. Think of TDD as an approach to defining the specification of our application. However the true ...
[Updated 23/12/2009: You might also want to check out my colleagues Mike and Mike who did the same] For fun I thought I would have a look at which of my posts in 2009 were my most popular. The results were quite surprising. By number of pageviews (which tends to favour 1st half of year): Entity Framework 4.0 Resources – documentation links, best blog posts and more: Posted in September and also known as 101 links on Entity Framework 4.0. Received a large update in December. 5% of my traffic! How ...
In this Issue: René Schulte, Mike Hodnick, ITLackey, Glenn Block, David Anson, ChristophDotNet, Micah, Adam Kinney, Joel Cochran, Andrei Alecu, Jesse Liberty, and Gill Cleeren(2). Shoutout: Jeff Paries shared the 2009 Silverlight Christmas Card from Waggener Edstrom ... pretty cool, thanks Jeff! From SilverlightCream.com: World# - Real Time 3D Augmented Reality with Silverlight Please note coments made here are sometimes made to be humorous or poike fun at myself, as I tried to do with this one. ...
The next version of Entity Framework has many new features, many of which are enabling it to catch up with features previously available in other frameworks like LINQ to SQL. One of these new features is the updated stored procedure support. In previous versions of EF, working with stored procedures was quite limited and really only usable with CRUD operations that were mapped to already defined entities. With EF 4, you can start with your stored procedure and have the designer automatically generate ...
In this Issue: Corrado Cavalli, Davide Zordan, Braulio Diez, David Anson, Jeff Prosise, Jesse Liberty, Koen Zwikstra, Giorgetti Alessandro, John Bruin, Colin Blair, Radenko Zec, and Gill Cleeren(2). Shoutouts: Have you seen this for Visual Studio? Visual Studio Theme Generator .. very nice! Jeff Barnes has his slide deck and projects up for a Silverlight presentation he gave: Silverlight 4 – Presentation and Code Samples My Advent Candle seems to have a problem, but could answer why I'm having trouble ...
Technorati Tags: Application Architecture and Design Strategies,Silverlight,Para... Programming,Tutorials The MSDN Southern Fried Roadshow is a developer/architect training through the southeast, presented by technology evangelists Chad Brooks, Glen Gordon and Brian Hitney with Microsoft. Dec. 8 2009. Introduction to ADO.NET Data Services The new wave of Web applications are built on AJAX and Microsoft Silverlight. We learn how ADO.NET Data Services enables applications to expose data as a REST-based ...
In this Issue: Damian Schenkelman, Zoltan Arvai, Deborah Kurata, David Poll, Fredrik Normén, Victor Gaudioso(2), Adam Kinney(2, 3), Karl Shifflett, and Gill Cleeren(2). Shoutout: Jeremy Likness has a great post describing how to Host WCF as Windows Service without Installing Bea Stollnitz announced her new site/venture: Zag Studio’s web site... good luck Bea, and I hope you keep blogging good stuff! From SilverlightCream.com: Will Silverlight 4 ICommand support simplify using commands in Prism? Damian ...