Just so you know… when you’ll notice a Father Christmas sitting on a chair
in the local mall, it might have never crossed your mind that is’t a hard and
dangerous job of many people that leads to these short moments of joy and
happiness that you and your children experience.
Fortunately the Woodpecker Film has taken
the risk and the courage to document the process for you. But beware!
Precautions must be taken…
The challenge - The site that we will be coding will have its pages tagged with episerver categories. Implement a control that will list all the pages tagged with a specific category.
The control aspx code seems looks pretty straightforward and is derivative of some other controls that are defined in the EPiServer sample site:
The wirst thing you will notice after looking at the code is that PageList is pretty much a standard ASP.NET reinvented and rehashed. GREAT! Sounds like we can use the Data binding, right? That’s also true:
EPiServer is an Interesting technology we’ve started working on recently. I will try to blog my impressions and the progress over the course of learning the solution.
Since I just seem unable to learn by reading docs I chose to build an email obfuscating (antispam) control and a paged search as an exercise and a way to learn the guts of the EPiServer.
A couple of loose thoughts for a start…
Translation
I am not sure I fully appreciate the way the translation is performed for the parts of the system that is editor independent . The translation is done by means of xml files stored on the disk in the /lang folder.
Basically what that means is that it’s much more prone to missing translations and thus is not as translation friendly as it could fairly easily be.
For the content I can always fall back to the e.g. english version and look what’s the original value there. not so much for the framework translations. Is there a tool for that? I will investigate that later as we’ll probably want to create a number of controls for the website we’ll be working on soon, and that will need to be translated to many languages. And not just that but also the original template files - we will need much more than what’s available originally in EPiServer.
So once you define your control’s content:
Most of us here use Pandora for the listening to the music with their headphones.
The keyboards we have at the office do not have any sound volume adjusting keys.
It’s mildly annoying that you need to take off your headphones every time someone talks to you or click the system tray every time the musinc is too quiet or too loud. But hey! What do we have CodeProject and Visual Studio for?
Quick investigation on CP allows to determine that there is a way for a DotNet app to both control the system volume and hook the keyboard events fairly easily.
Half an hour later…
We have a little tray application for adjusting the system volume control
The only visual indication of the app running is a tray icon. While it is running you can:
I’ve done some research about Visual studio plugins recently, just so that I can close the tabs and move on here are some links that I cound to contain some useful information:
1PerformanceCounterpc=newPerformanceCounter("System","System Up Time"); 2 3//Normally starts with zero. do Next Value always. 4pc.NextValue(); 5 6TimeSpants=TimeSpan.FromSeconds(pc.NextValue()); 7 8MessageBox.Show(Environment.MachineName+ 9" has been up for \n\n"+10(ts.Days<1?"":ts.Days+" days, ")+11(ts.Hours<1?"":ts.Hours+" hours, ")+12(ts.Minutes<1?"":ts.Minutes+" minutes ")+13" and "+ts.Seconds+" seconds.");
[Edit: I’ve posted it on CodeProject and there are some greatl people commenting on it that did the investigation on ho to wrap it in a STA Thread and make it a part of your ASP.Net solution - really cool stuff!]
An interesting use case. Darek (our beloved sys admin - we all bow to him and worship his skills) has recently asked if it’s possible to write a .net application to make a thumbnail of a website. Which is pretty trivial with Windows forms actually.
All you really need to do is drop a WebBrowser on your form and once it’s loaded the page call:
go ahead and try it! I’m writing this article in it! As cool as WordPress is, it’s writing editor sucks. I don’t tend to write often, but when I start, my articles usually take more than a page and if in the process I accidentally press the shortcut for the browser go-back… I’m crying! I also wonder if you’ve ran into the 1000 miles long line bug in the WordPress editor? It seems to sometimes make all spaces in the line non breakable, there is a solution to this, which is to press enter and then go back to the line again and delete and re-insert all the spaces again… which makes me cry some more! I am also just not a big fan of Web interfaces for something so interactive as creating documents or calculations (hint, hint Google). I think Web is more suited for presentation whereas desktop is for creation.
The new project is really exciting. Not that we didn’t expect that, the number of new technologies we get to explore is incredible.
I’ve just finished setting up an automatic build and deployment (of a desktop application) environment consisting of SVN+Nant+CruiseControl+ClickOnce. The system is centered around CruiseControl which detects any commit in the trunk in the SVN repository and every time it’s changed, it calls Nant to pull source code from our SVN, at which point it compiles the source into binary artifacts and put them up on our release server. This means that every time you change anything and commit it to the repository - a minute or two later - any tester can get a working copy of your build to look at, without any intervention on your part, but there’s more…
I’m about to help a few guys here with their transition from Java to .Net, namely to C#.
I thought it may actually be a good idea to gather a few helpful links together for you. Stuff I found useful while I was phasing into the joys of the .Net framework a while ago.
The official stuff
First and foremost C# is an ECMA regulated standard. And as such is pretty well documented. ECMA allows you to download PDF e-books regarding the standardized part of the language: