23 posts categorized "Web/Tech"

01/01/2014

A Happy New Year 2014!

1987..2013..2014

Years with 4 different digits :-)

Dreamstime_s_35588139_happy2014

In the year 2013 the first blog of the year was about

  • Many new Windows Store apps
    • Yes, there are many more Windows Store apps. Probably some you are wishing for are not here, yet. Probably others don't have the same features as on other platforms. But definitely, there are many more Windows Store apps! Which one are you missing?
  • Faster updates for Windows, Windows Phone, Visual Studio
    • Yes, updates are coming a lot faster. We have Windows 8.1, Visual Studio 2013 (there have been 4 updates for Visual Studio 2012), and more updates are on the way.
  • C++11 and TypeScript
    • Yes, C++ is active again. C++11 brought great new features. Now, C++14 is on its way for some more changes. TypeScript reached the Beta stage on 5-Dec-2013 (Version 0.9.5). It's nearing the first release.

What I'm expecting from 2014?

Of course it's out of question that cloud usage will increase, and it will become the norm to create apps for mobile devices first. However, here I would like to take a look at some specific Microsoft technologies.

C# 6

Mads Toergesen already talked about the Future of C#. At the NDC London conference he introduced some great features of the upcoming C# language. With Roslyn in the home stretch, it should become easier to add language features. C# 6 doesn't seem to have a feature as big as generics, LINQ or async, but many smaller ones that come very handy, such as

  • Primary Constructors
  • Readonly auto properties
  • Exception filters
  • Static type using statements
  • Property Expressions
  • Method Expressions
  • Params for enumerables
  • Monadic null checking
  • Constructor type parameter inference
  • Inline declarations for out params

It's not clear yet what and when it's really coming. But for sure there are some great C# enhancements in the time to come. A list of these extensions with comparisions how to write code today is described in the blog post of DaminG. Mads Torgersen himself gives some great information about C# and Roslyn at .NET Rocks.

M#, Between C++ and C#

Let's continue with C#. There are other talks about a new language (code name M#) that is based on C#. It just sits between C++ and C#: C# for Systems Programming with safety and productivity similar to C# and performance like C++. Joe Duffy has a blog post of this new language and its goals. Some highlights:

  • Aggresively stack allocate objects, deterministically destruct...
  • Elements of C++ const (with safety), immutability, isolation
  • Async programming at scale
  • Type-safe system programming, easily carve out sub-arrays and sub-strings without allocating
  • Modern error model with fail-fast as the default prolicy, exceptions for rare dynamic failure, typed exceptions only when rich exceptions are needed 

Project Midori

The language M# was developed together with the operating system Midori. First from Microsoft Research, it was quiet for some years now around this new operating system. Now Mary Jo Foley has some information about Midori. If parts of it can be found in the next Windows system, or it takes a completely different roadmap, it's interesting in any case.

Microsoft "Mod"

Mary Jo also writes about Microsoft Mod as Microsoft applies for a trademark. I'm not sure about this name (does it really sound good in your language?), and as Mary mentions, "Microsoft applies for many trademarks it never ends up using commercially or publicly". However, it's interesting what's behind this, and there's already an ongoing discussion about Office as Windows Store apps. Of course, Microsoft Office is available on Windows RT as a desktop application. OneNote is already available as a Windows Store app, and it's great, using it a lot. I'm expecting other parts of Office to be available as Windows Store apps as well.

Microsoft Project Siena

A Microsoft Windows Store app that is already available in the store is Microsoft Project Siena. This allows easily creating Windows Store apps. Is this the new Visual Basic? This app shows some more ways what's all possible with Windows Store apps. I'll try to create a real app using data offered by the Menu Card app very soon.

Windows Azure

The Menu Card app just mentioned makes use of several Windows Azure features: Mobile Services, SQL Azure, Storage, and the source code is managed with Visual Studio Online. The least year many new features were added to Windows Azure. I expect enhancements in a similar fast pace in 2014. Waiting for some cool new features with Mobile Services :-)

Build Windows

Let's see what new things we'll see at Build 2014 in San Francisco, the annoucement from Steve Guggenheimer mentions news about Windows, Windows Phone, Windows Azure, Windows Server, Visual Studio and much more :-) 

 

With all this to come

 

I wish you all

A Happy New Year 2014!

Live long and prosper!

Christian

 

06/27/2013

Tiles, Toasts, and Notifications in Windows Store Apps

Samples for my sessions from TechEd North America and TechEd Europe! I hope you enjoyed the session!

This sample shows tiles, toasts, badges, secondary tiles:

Tiles and Toasts Sample

And here are the sample to show different versions for push notifications:

Push Notifications

Christian

Watch this space for more information on developing Windows Store apps with Windows 8 and Windows 8.1!

01/01/2013

A Happy New Year 2013!

2013 – the first year with 4 different digits since…. since 1987!

My previous blog article was about 2012. What can we expect from 2013?

German Version

image

Windows 8 was the start in a new era. Applications are becoming easier, specialized for a feature. Touch is an important aspect of the new applications. Focusing them to specific features makes them easier to use. However, with such smaller apps, communication between apps is becoming more and more important.

The new Microsoft design not only influences Windows Store apps, but also desktop apps (btw, desktop apps can be found by the Windows Store, and Windows Store apps can be installed without the Windows Store by using sideloading).

Windows 8 is becoming a cool operating system only with its apps. For 2013 I’m expecting many new apps; not only consumer apps but also LOB apps. Some of the LOB apps were already shown at the last Build conference, e.g. apps from SAP, Citrix, Hyland, Greenway Medical, and others. With the start of developing LOB apps for Windows 8, I’m expecting to see many new usability ideas. This is for accounting apps as well.

It will take some time before the desktop can be fully replaced by Windows RT. The year 2013 will bring some progress to this, but of course the desktop will stay important in 2013. Talking more time, the new UI will win. In reality, many users nowadays don’t need more than Windows RT. With more apps, Windows RT is becoming the future.

Many new Windows Store apps in 2013

Windows Blue was already discussed. What’s really behind Windows Blue we’ll see in 2013. No matter what this code really means, I believe in faster update cycles. Windows Azure is a front-runner with this to bring new features every quarter. Visual Studio is running with a faster update pace as well since the release of Visual Studio 2012. Windows should deliver faster updates, as well.

Last year, Microsoft introduced Windows Phone 8. With this phone update, the operating system for the phone is similar to the one for the desktop. In reality it’s not the same, but became more similar. With Windows Phone apps some features from Windows Store apps are still missing. I’m missing JavaScript project templates in Visual Studio, and some small parts like the HttpClient class (namespace System.Net.Http). I’m expecting some updates for Windows Phone in 2013 as well.

Faster updates for Windows, Windows Phone, Visual Studio

Continuing with development, at Microsoft Windows Store apps have a major focus – of course. I’m expecting updates for libraries, many new features, and features in regard to LOB apps.

JavaScript is becoming more and more important. JavaScript is not only used for client-side development, but on the server as well. Using table and blob storage with Windows Azure Mobile Services can be done using JavaScript – with the help of Node.js. Issues of JavaScript are solved with TypeScript.

image

C++ is becoming more important again. For 2013 I’ve already requests for C++11 workshops Smile

image

C++11 and TypeScript

Let’s make a move to hardware. Microsoft Surface Pro is available soon.

image

I’m already using a Microsoft Surface RT, running several Windows Store apps on this device. For development with Visual Studio I need a larger touch device. Hardware manufactures were not delivering powerful devices in 2012. Now some cool devices are nearby.

One powerful device is the Lenovo Thinkpad X1 Carbon Touch

image

another option the HP Spectre XT TouchSmart

image

Microsoft Surface Pro or a powerful device such as Lenovo Thinkpad X1 Carbon Touch or HP Spectre XT TouchSmart?

In 2012 I completed the book Professional C# 2012 and .NET 4.5. For 2013 I’m hoping it sells well – and I’m already working on another book. However, the time is not right to talk about this Winking smile

image

Professional C# 2012 and .NET 4.5

A Happy New Year 2013!

Live long and prosper!

 

Christian

CN innovation

12/31/2012

A Happy New Year 2013!

2013 was a year of several Microsoft product releases: Windows 8, Windows Server 8, Office 2013, Windows Phone 8, Visual Studio 2012, SQL Server 2012, Microsoft Surface… What can we expect from the year 2013? Let’s start with a look back to 2012.

A personal look back to 2012

With my workshops, I had a huge demand for WPF workshops (that’s similar to 2011). This year also ASP.NET MVC and HTML5 was in demand – I also had some workshops to develop Windows Store Apps. Parallel Programming was a hot topic in 2012 as well.

With my own Websites, I moved to Windows Azure in 2012. http://www.kantine.at and http://www.cninnovation.com is hosted by Windows Azure Websites. Besides Azure Websites, I’m also using SQL Azure and Blob Storage for these sites.

image

image

My first Windows Store apps are in the store:

Picture Search is used for searching images via Bing Search – and sharing images, as well es doing slide shows:

image

Kantine (only available in Austria) shows menus of the week. The restaurant opens again on 7-January, so the next menus will be shown that day.

image

What can be expected from 2013? Let’s wait for the first blog entry of 2013. 

I wish you all the best in the New Year!

Christian

CN innovation

03/24/2012

HTML 5 in Stockholm

Next week I’m giving a 2-day seminar on HTML 5 in Stockholm, covering not only semantic extensions of HTML 5 but also:

  • Geolocation
  • Video and Audio
  • Canvas
  • Messaging
  • Web Workers
  • Web Storage
  • Indexed DB
  • Offline Apps
  • Files API
  • Drag & Drop
  • Networking
  • HTML 5 Forms

This will be 2 fun days Smile

Code Samples for Download

Christian

09/13/2011

jQuery und ASP.NET MVC Workshops

19. September und 20.-21. September gibt es in Kooperation mit Global Knowledge offene Kurse zu jQuery und ASP.NET MVC in Wien:

jQuery

Rasant erobert jQuery Web-Applikationen. jQuery ist u.a. bei Amazon, Twitter, Dell, IBM im Einsatz. Bei Microsoft Tools ist jQuery bereits Bestandteil von Web Applikations-Templates Visual Studio. Für Visual Studio wird dabei gleich integrierte Dokumentation angeboten.

Dass jQuery die Web-Welt im Sturm erobert hat auch seinen Grund. Mit jQuery geht es ein vielfaches einfacher als nur mit JavaScript Web-Seiten zu gestalten, manipulieren, und zu animieren. Und dabei ist Browser-Unabhängigkeit gleich integriert.

In diesem Workshop gibt es einen 1-Tages Einstieg zu jQuery, Selectors, DOM, Animationen, jQuery Utility Funktionen, und auch einen Einstieg in jQuery UI. Kenntnisse von JavaScript sind vorteilhaft.

ASP.NET MVC 3

ASP.NET Web Forms oder ASP.NET MVC? Nach 10 Jahren ASP.NET Web Forms ist es Zeit für eine neue Technologie, wobei ASP.NET Web Forms sicher nicht obsolete ist. Hier haben wir zwei unterschiedliche Herangehensweisen an die Programmierung von Web Applikationen. Während es bei ASP.NET Web Forms die Zielsetzung gibt dass der Entwickler Web Applikationen möglichst ähnlich zu Windows Forms programmieren können soll, Methoden und Properties von (server-seitigen) Controls verwendet die den Windows Forms controls möglichst ähnlich sind, und HTML sowie JavaScript nicht anzugreifen braucht (was sich dann aber oft doch anders herausstellt), gibt es bei ASP.NET MVC eine konträre Zielsetzung. HTML und JavaScript (siehe auch jQuery) haben in ihrer Bedeutung wieder gewonnen, mehr Kontrolle über HTML ist oft wünschenswert. Mit C# wird server-seitige Funktionalität programmiert. Mit der Struktur die von ASP.NET MVC vorgegeben wird ist es auch gleich viel einfacher Unit Tests für die Applikation zu erstellen.

In diesem 2-Tages Workshop gibt es einen Einstieg in ASP.NET MVC 3, mit Controllers, Views, Routing, Razor und vieles mehr.

Für den 19. und 20.-21. September gibt es noch ein paar freie Plätze. Bei Interesse bitte office@cninnovation.com kontaktieren.  Firmenworkshops sind natürlich auch möglich.

Christian

CN innovation

Mehr Informationen zu meinen Web-Workshops

09/05/2011

Taking advantage of Windows 7 with Web Pages

The Windows 7 taskbar is one of the great improvements of Windows 7. Users can pin applications to the taskbar so the application is fast accessible. The application need not to run, the application is accessible with the click of a button and thus replaces the quick launch. With the task bar the application can also offer some tasks that can be accessed from the user directly, instead of starting the application first and accessing the specific feature of the application. The .NET 4 version of WPF got an improvement that integrating the application with the task bar becomes an easy task. Starting with IE9, this is also an easy task to do with Web applications as this article demonstrates.

First, I’m adding a custom icon to the Web application. This icon is shown with IE9 in the taskbar and with the address link as the following figure shows.

image

If the Web application is pinned to the taskbar, the icon is displayed on the left side as well, and the back and forward buttons are colored. There’s a way to specify the color of the back and forward buttons. If the color is not specified, the color is taken automatically from the icon.

image

The icon can be specified in the header section of the HTML page with a link to an icon as shown. The meta elements named application-name, msapplication-tooltip, msapplication-starturl, and msapplication-window are used to configure the settings for the taskbar.

<link href="/Content/Icons/favicon.ico" rel="Shortcut Icon" type="image/x-icon"/> <meta content="CN innovation" name="application-name" /> <meta content="Information about CN innovation" name="msapplication-tooltip" /> <meta content="http://www.cninnovation.com" name="msapplication-starturl" /> <meta content="width=1024;height=768" name="msapplication-window" />

Selecting the context menu of the application pinned to the taskbar you can see information about the application as well as some links for fast access as the figure below demonstrates. This is the jump list.

The icon of the application is shown in the lowest section above the unpin and close options. These options as well as the menu to start in private browsing cannot be changed with IE9. The name of the application that was set with the application-name meta tag is shown beside the icon. With the application here I’ve also added two tasks for fast access which are Training and Books, and a custom section that lists the latest blog entries. How this is done is shown next.

image

Adding tasks to the task list is just a matter of adding meta tags msapplication-task. The content of this tag lists the name that is shown in the jump list, the link that should be opened on activating the item, and the icon.

<meta content="name=Training;action-uri=http://www.cninnovation.com/Home/Training;icon-uri=/Content/Icons/training.ico" name="msapplication-task" /> <meta content="name=Books;action-uri=http://www.cninnovation.com/Home/Books;icon-uri=/Content/Icons/books.ico" name="msapplication-task" />

The items that should appear above the task list can have custom section names. I’ve created a Blog section and display titles of the last five blog entries that link to these. Adding such items to the jump list is done with JavaScript. First it is verified if the Window is pinned. This can be done with the function window.external.msIsSiteMode. If it is not, and if the site is opened from a different browser, the script doesn’t need to run. A new section is created with the function msSiteModeCreateJumpList. Items to the jump list are added with msSiteModeAddJumpListItem. The parameters of this method are the name that should be displayed with the jump list, the URL that should be opened, and the link to the icon that should be displayed.

<script type="text/javascript"> try { if (window.external.msIsSiteMode()) { ext = window.external; ext.msSiteModeClearJumpList(); ext.msSiteModeCreateJumpList("Blog"); ext.msSiteModeAddJumpListItem("Sharing Assemblies between Silverlight and .NET", "http://weblogs.thinktecture.com/cnagel/2011/07/sharing-assemblies-between-silverlight-and-net.html", "/Content/Icons/blog.ico"); ext.msSiteModeAddJumpListItem("Real World .NET 4 and C#", "http://weblogs.thinktecture.com/cnagel/2011/08/real-world-net-4-and-c.html", "/Content/Icons/blog.ico"); ext.msSiteModeAddJumpListItem("BASTA! 2011 in Mainz", "http://weblogs.thinktecture.com/cnagel/2011/08/basta-2011-in-mainz.html", "/Content/Icons/blog.ico"); ext.msSiteModeAddJumpListItem("WPF ListBox Postioning using a Canvas", "http://weblogs.thinktecture.com/cnagel/2011/08/wpf-listbox-postioning-using-a-canvas.html", "/Content/Icons/blog.ico"); ext.msSiteModeAddJumpListItem("Reserve the date! Developer Day 2011", "http://weblogs.thinktecture.com/cnagel/2011/09/reserve-the-date-developer-day-2011.html", "/Content/Icons/blog.ico"); ext.msSiteModeShowJumpList(); } } catch (exception) { } </script>
In my site the JavaScript function is created dynamically by using server-side ASP.NET code to create items that reference the last five blog entries.

It will be interesting to see what features Web applications will get from Windows 8. This taskbar feature from Windows 7 is limited in the way that there is not enough place for all my important applications. Let’s see how Windows 8 changes this using Metro, and what other features Web applications can use from Windows 8.

Christian

CN innovation

How to use WPF 4 to integrate in the Windows 7 taskbar is shown in my book Professional C# 4 and .NET 4.

Information on programming Web applications in my Web programming workshop.

08/23/2011

BASTA! 2011 in Mainz

Bei der diesjährigen Basta! in Mainz gibt es von mir gleich 4 Vorträge!

basta_speaker_button_128x128

Umstieg von ASP.NET Web Forms auf ASP.NET MVC

Dienstag, 9:30

Dabei gibt es für ASP.NET Web Forms Entwickler Foundations zu ASP.NET MVC, welche Vor- und Nachteile MVC hat, wie Websites umgestellt werden können, und wie auch ASP.NET Web Forms und MVC gemeinsam verwendet werden kann.

The Secrets of Delegates

Dienstag, 17:15

Bei dieser Sessions wird einiges von Delegates aufgedeckt: delegates & events, asynchrone Features von delegates, Probleme und Lösungen zu strong references, anonyme methoden, Lambdas, Closures….

Storage mit Windows Azure

Mittwoch, 10:15

Relationale Daten oder… Diese Session gibt Einblicke neben dem Speichern von relationalen Daten in die Funktionsweise und Features von Azure Table, Blob, Queue, und Drive Storage.

C# und Dynamic

Mittwoch, 15:45

Mit C# 4 gibt es das dynamic Keyword. Hier wird dynamic im Einsatz mit COM, Reflection, der Integration zu JavaScript und Python gezeigt. Weiter geht’s mit ExpandoObject, DynamicObject…..

 

4 unterschiedliche Themen! Welche Session ist für dich am interessantesten?

 

See you in Mainz!

Christian

CN innovation

07/12/2011

Sharing Assemblies between Silverlight and .NET

Writing WPF, Silverlight, and WP7 applications it could be useful to share assemblies between these technologies. Since Silverlight 3 and .NET 4 it is indeed possible to not only share source code but share the same binary assemblies. While this wasn’t very intuitive to do with Visual Studio 2010 and Silverlight 3 and 4, now there are separate Portable Library Tools that make this process easier. This article describes how to share assemblies with these different technologies, and the limitations.

Sharing Assemblies

With Silverlight 3 and .NET 4 the format of assemblies is the same with these two technologies. However, of course there’s a difference between the Silverlight and the .NET assemblies. To limit the download sizes that are an important aspect of Silverlight, Silverlight assemblies are reduced in functionality compared to the .NET Framework. The .NET assemblies of Silverlight not only have fewer types included, but the types also have fewer members. For example, a simple core type such as the Enum class offers GetNames and GetValues methods to access all the names and values of an enumeration. These methods are not available with the Silverlight assemblies. A .NET programmer knowing the full-blown .NET environment switching to writing applications with Silverlight soon finds out some limitations. Writing assemblies that should be used with both Silverlight and WPF are restricted to the functionality available with both technologies.

To create shared assemblies between Silverlight and WPF it is possible to create a Silverlight class library.

image

Using this assembly from WPF is simply a matter of referencing the assembly. However, a project reference doesn’t work. A reference to the file is needed. Sharing entities or some algorithms can now be easily done with this library.

However, there’s an important limitation. Using assemblies within this shared assembly is limited to this list (for Silverlight 4 and .NET 4):

  • Mscorlib
  • System
  • System.Core
  • System.ComponentModel.Composition
  • Microsoft.VisualBasic

Information on this list is found here: http://blogs.msdn.com/b/clrteam/archive/2009/12/01/sharing-silverlight-assemblies-with-net-apps.aspx

By default a Silverlight class library has some more assemblies referenced. If, for example the type XmlWriter from the assembly System.Xml is used within the Silverlight class library, the code runs fine from a Silverlight application. With a .NET application compilation is successful as well; however running the application a FileNotFoundException is thrown as the System.Xml assembly cannot be found.

image

So using this feature to share assemblies between Silverlight and WPF with Visual Studio 2010 out of the box a lot of care needs to be taken for not using types or members that are not available across the different platforms.

Portable Library Tools

With the Portable Library Tools a solution to these issues is available. With these tools project settings are available to define what technologies the assemblies should be shared with, and warnings are given if types or members are used that are not available with all options.

The Portable Library Tools can be downloaded from the Visual Studio Gallery

http://visualstudiogallery.msdn.microsoft.com/b0e0b5e9-e138-410b-ad10-00cb3caf4981/

and requires Visual Studio SP1 as prerequisite.

Creating a shared assembly, after the Portable Library Tools are installed, the project template to create a Portable Class Library is available.

image

With the project properties the library can be configured to define the target frameworks that should be used.

image

Depending on the selected target frameworks only a subset of assemblies is available that can be referenced.

image

The list of assemblies that is available with this tool is bigger than the list shown earlier.

  • Mscorlib
  • System
  • System.Core
  • System.Xml
  • System.ComponentModel.Composition
  • System.Net
  • System.Runtime.Serialization
  • System.ServiceModel
  • System.Xml.Serialization
  • System.Windows

However, the add reference doesn’t allow adding references to all these assemblies. This depends on the selection of the target frameworks. Changing the target frameworks to include just .NET Framework 4 and Silverlight 4, which can be done from the project properties,…

image

…the System.ComponentModel.Composition assembly is available as well for reference.

image

 

Summary

With the support of the Portable Library Tools sharing assemblies between different frameworks becomes easy. Just select the target frameworks, and the assemblies that can be used by the shared library is dealt with by the tool. This way it is easy to create entity assemblies and assemblies implementing algorithms that could be used across different frameworks.

Christian

CN innovation

More information in my Silverlight workshops

06/20/2011

Integrating Twitter Feeds in Web Applications

After launching my Website now running with ASP.NET MVC3 instead of ASP.NET Web Forms I’ve been asked how a twitter feed can be integrated within a Web page. With ASP.NET Web Helpers this is really an easy task. This blog post demonstrates how the twitter feed can be integrated with ASP.NET Web Pages and also with ASP.NET Web Forms.

Twitter Feed with ASP.NET MVC

Let’s start with an ASP.NET MVC Project using Razor. After the project is created, the ASP.NET Web Helpers Library can be added to the project from the context menu Add Library Package Reference. From the Add Library Package Reference select the ASP.NET Web Helpers Library as shown in the screenshot.

image

Within the view where the twitter feed should be displayed, the Twitter API can be used as soon as the namespace Microsoft.Web.Helpers is imported.

The Profile method of the Twitter class is used to display the twitter feed. This method is defined using optional parameters as shown in the following screenshot. It’s just necessary to pass the twitter profile name, but it’s also possible to specify if the twitter feed should be continuously refreshed, the number of tweets to be shown, and the colors of the background, tweets, links…

image

The full code of the view to display the twitter feed is shown in these few lines.

1 @using Microsoft.Web.Helpers 2 @{ 3 ViewBag.Title = "Twitter Sample"; 4 } 5 6 <h2>Twitter Sample</h2> 7 8 @Twitter.Profile("ChristianNagel")

Running the application a nice formatted twitter feed is shown:

image

More Features from the Twitter Helper

Other than showing a profile, the Twitter class offers several other features. For example, it is possible to display a list from a user. The next figure shows my Formula 1 list.

1 @Twitter.List("christiannagel", "F1")

image

 

A search is possible as well. With the next sample I’m searching for tweets containing the tag for the Build Windows conference.

1 @Twitter.Search("#bldwin")

image

A follow me button can be done easily as well.

1 @Twitter.FollowButton("christiannagel")

image

A tweet button to tweet about something specific from a Webpage can also be placed on a site. The parameters of the TweetButton method can easily be understood with the information about the Tweet button on the twitter site.

Using this code

1 @Twitter.TweetButton(url: "http://www.cninnovation.com", 2 userName: "christiannagel", 3 tweetText: "attended a cool workshop")

shows this button

image

Clicking on the button the twitter dialog pops up:

image

Twitter Feed with ASP.NET Web Forms

If your are still running an ASP.NET Web Forms application, twitter feeds can be integrated as well. The library package reference with the ASP.NET Web Helpers Library can be added in a similar way to Web Forms as was done with ASP.NET MVC. However, as the library package dialog lists no dependencies for this item, there’s still a dependency. It’s just that ASP.NET Web Pages and ASP.NET MVC have referenced this dependency be default, with ASP.NET Web Forms it is necessary to add the assembly System.Web.WebPages to the project. Don’t forget to change the property to copy the assembly locally with the properties of the reference settings.

With the directives of the ASP.NET Web page, the namespace and assembly references can be added to use the Twitter class:

1 <%@ Assembly Name="Microsoft.Web.Helpers" %> 2 <%@ Assembly Name="System.Web.WebPages" %> 3 <%@ Import Namespace="Microsoft.Web.Helpers" %>

 

Now the Twitter class can be used within the ASP.NET Web Forms page in the same way you’ve seen it earlier.

1 <%= Twitter.Profile("christiannagel") %>

Summary

Web helper classes such as the Twitter class are a great extension to make it easier to create Web applications. The Twitter class defined with the ASP.NET Web Helpers library makes it easy to integrate with all the twitter features. And it can be used with all the Microsoft ASP.NET technologies such as ASP.NET MVC, ASP.NET Web Pages, and ASP.NET Web Forms.

More information in my trainings.

Christian

CN innovation