change account type button is not enabled even as administrator user Results


Sponsored Links:



With the release of Windows Phone 8, a few new developer API endpoints were made available that allow third-party applications to change the device lockscreen image. In this article, I am establishing the infrastructure and building a mobile application that provides the ability to choose from a number of dynamic image sets, from which images can be selected and then cycled as lockscreen wallpapers.
What do you need

You will need to download and install ASP.NET MVC3 to work on the web frontend and Windows Phone 8 SDK to work on the mobile applications. An Azure Mobile Services account will be necessary, and of course don’t forget to download and install the Azure Mobile Services client libraries. All three components are available at no additional charge.
NOTE: Without the Azure Mobile Services SDK installed on the development machine, the compilation process will fail for the Windows Phone application.
Setting up The Data Store

First we need to establish the general design of the application and organize the workflow. The application will provide two ways to assign the dynamic lockscreen:

With the help of custom image sets that are provided by the service;With the help of self-created image sets, aggregated from images provided by the service but ultimately managed by the end-user.
Let’s talk about the general data model. Every image belongs to a certain category and to keep track of each we need a table with two columns—category ID and category name. We also need another core table containing the image references themselves, with the following columns: image URL, descriptive name, and the category ID to which it belongs. The overall structure looks like this:

Now to the Windows Azure Management Portal and creating a new Mobile Service.

Once created, you need to specify database information, just like you would with a standard SQL Server database:

As the database is being created, you can easily integrate it with SQL Server Management Studio. You will need the server address, which may be obtained in the Azure Management Portal. To login, use the credentials that you set when creating the core database.
Create the two tables mentioned above, with the following column configuration:
Categories

ID - intName – varchar(100)
Images

ID – intURL – varchar(500)Name – varchar(100)CategoryID – int
You can create these tables either in the SQL Server Management Studio or through the Azure Management Portal. However, you will need the Management Studio to create the column structure, as the Azure Management Portal does not offer this functionality right now.
By default, the id column will be created automatically. To add the Name column to the Categories table, run this query:

ALTER TABLE c4flockscreen.CategoriesADD Name VARCHAR(100)To add the missing columns to the Images table, simply execute this query:

ALTER TABLE c4flockscreen.ImagesADD URL VARCHAR(500),Name VARCHAR(100),CategoryID INTNow that the database is ready, we’ll proceed to working on the web layer, which will effectively be the administrative portal for the service.
Creating the Web Portal

There should be a way to easily manage images and constantly expand the collection of possible lockscreen wallpapers. One way to do this is create a basic management portal that can carry basic CRUD operations.
Start by creating an empty project:

If you are not yet aware of the Model-View-Controller (MVC) development pattern, here is a good read explaining the fundamentals.
Create a new controller in the Controllers folder, named HomeController. This will be the only controller created in this project. For now, add an ActionResult-based function that will return the main view:

using System.Web.Mvc;namespace Coding4Fun.Lockscreen.Web.Controllers{ public class HomeController : Controller { public ActionResult MainView() { return View(); } }}Having the controller without the proper views is pointless, so create a new view in Views/Home and name it MainView. For now, do not focus on the visual layout of the page, but rather on the functional aspect of the web frontend. If you run the application now, you will most likely get a 404 response. That is because the associated home view is by default not found. Open App_Start/RouteConfig.cs and make sure that the default view is set to MainView instead of Index.

routes.MapRoute(name: "Default",url: "{controller}/{action}/{id}",defaults: new { controller = "Home", action = "MainView", id = UrlParameter.Optional });The core is created and now if running the web application you will see a basic HTML page:

We now need to handle data from the Azure Mobile Services database. Out-of-the-box, there is no ASP.NET SDK available, but the database can be easily accessed through a REST API. But before that, we need to define the data models for the Categories and Images table. Begin by creating two classes in the Models folder:
Category.cs:

public class Category{public int? id { get; set; }public string Name { get; set; }}Image.cs:

public class Image{public int? id { get; set; } public string URL { get; set; }public string Name { get; set; }public int CategoryID { get; set; }}Each of the properties is tied to the associated column in the database we created earlier. Notice that the ID values are nullable. This is introduced because the index will by default be automatically assigned. When new instances of Category or Image are created, I will not explicitly set the id property, so keeping it null instead of at a potential default value of 0 will ensure that it is properly set on the backend.
Let’s now create the connectivity engine that will allow us to query the content of the data store. For this purpose, I created a DataStore folder and a DataEngine class inside it. We will need a unique API key for each of our requests, so open the Azure Management Portal and obtain it from there:

In order to keep consistency between projects, and to be able to re-use the same Azure Mobile Services API key and core URL, I created an AuthConstants class in the context of the Coding4Fun.Lockscreen.Core project. It carries three static fields:

public static class AuthConstants{ public static string AmsApiKey = "YOUR_KEY_HERE"; public const string AmsUrl = "https://c4flockscreen.azure-mobile.net/"; public const string AmsTableUrl = AmsUrl + "tables/";}Back in the ASP.NET project, the query operations are carried with the help of HttpClient initialized in the class constructor, which also includes the key used to authenticate the requests via the X-ZUMO-APPLICATION header:

private HttpClient client;public DataEngine(){ client = new HttpClient(); client.DefaultRequestHeaders.Add("X-ZUMO-APPLICATION", KEY); client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json")); }This is the basic data harness. I also implemented two core methods in order to get all existing categories:

public IEnumerable GetAllCategories(){ var result = client.GetStringAsync(string.Concat(CORE_URL,"Categories")).Result; IEnumerable categories = JsonConvert.DeserializeObject(result); return categories; }And images:

public IEnumerable GetAllImages(){ var result = client.GetStringAsync(string.Concat(CORE_URL, "Images")).Result; IEnumerable images = JsonConvert.DeserializeObject(result); return images; }For each of these, a basic request is made with the table name appended to the base URL (represented by the CORE_URL constant). Since JSON.NET is now bundled with ASP.NET, I am able to easily deserialize the returned JSON data array to an IEnumerable. There is one problem, however, with the GetAllImages approach. It implies that even if I want to use LINQ to query the existing image collection, I have to first download the entire set locally.
Fortunately, the Azure Mobile Services REST API provides an endpoint with filtering, and that’s what I am using in GetCategoryById and GetImagesByCategoryId:

public Category GetCategoryById(int id){ string composite = string.Concat(CORE_URL, "Categories?$filter=(id%20eq%20", id.ToString(), ")"); var result = client.GetStringAsync(composite).Result; IEnumerable categories = JsonConvert.DeserializeObject(result); return categories.FirstOrDefault();}public IEnumerable GetImagesByCategoryId(int id){ string composite = string.Concat(CORE_URL, "Images?$filter=(CategoryID%20eq%20", id.ToString(), ")"); var result = client.GetStringAsync(composite).Result; IEnumerable images = JsonConvert.DeserializeObject(result); return images();}Notice the ?$filter= parameter, in which the conditional is URL encoded and is wrapped in parentheses. For the category query, I am checking the id value, and for the image I’m checking CategoryID.
In the Views/Home folder, create a new view and name it Images. It will be used to list existing images that are associated with one of the selected categories. You also need to adjust the controller code to handle the incoming data:

using Coding4Fun.Lockscreen.Web.DataStore;using System.Web.Mvc;namespace Coding4Fun.Lockscreen.Web.Controllers{ public class HomeController : Controller { DataEngine engine; public HomeController() { engine = new DataEngine(); } public ActionResult MainView() { var categories = engine.GetAllCategories(); return View(categories); } public ActionResult Images(int categoryId) { var images = engine.GetImagesByCategoryId(categoryId); if (images != null) { return View(images); } return View("MainView"); } }}For the main view, I am getting the list of categories and passing them as the bound model. For the Images view, the category ID is passed as an argument that will later enable the engine to return a list of all images that have CategoryID set to that value. In case the returned list is not null, the view is shown. Otherwise, the main view is the terminal point.
In its current state, I’ll be able to use the frontend to list existing categories and images, but not to add, remove, or update items. Adding a category and an image is a matter of modifying an HttpClient request, with the help of HttpRequestMessage. For example, here is how I can add a category through my DataEngine class:

public HttpStatusCode AddCategory(Category category){ var serializedObject = JsonConvert.SerializeObject(category, new JsonSerializerSettings() { NullValueHandling = NullValueHandling.Ignore }); var request = new HttpRequestMessage(HttpMethod.Post, string.Concat(CORE_URL, "Categories")); request.Content = new StringContent(serializedObject, Encoding.UTF8, "application/json"); var response = client.SendAsync(request).Result; return response.StatusCode;}JSON.NET capabilities are used to serialize the object that needs to be inserted. The POST request is executed against the standard table URL, with the UTF8 encoded JSON string. Since the client is already carrying the basic authentication header, all that needs to be done is calling the SendAsync function.
Updating a category follows the same approach, though a PATCH method is used for the request and the URL contains the index of the category that needs to be updated:

public HttpStatusCode UpdateCategory(Category category){ var request = new HttpRequestMessage(new HttpMethod("PATCH"), string.Concat(CORE_URL, "Categories", "/", category.id)); var serializedObject = JsonConvert.SerializeObject(category); request.Content = new StringContent(serializedObject, Encoding.UTF8, "application/json"); var response = client.SendAsync(request).Result; return response.StatusCode;}To delete a category from the data store, one simply needs to pass a parameter to it that identifies the index of the category that needs to be removed:

public HttpStatusCode DeleteCategoryFromId(int categoryId){ var request = new HttpRequestMessage(HttpMethod.Delete, string.Concat(CORE_URL, "Categories", "/", categoryId)); var response = client.SendAsync(request).Result; return response.StatusCode;}For images, the same methods can be used, with the Images table passed as the name for the target in the composite URL. Let’s now get back to working on some of the views. A static category list is not fun, so let’s create a way to add new categories. Right click on the Views/Home folder and select Add View:

A great thing about the view creation process in Visual Studio is the fact that you are able to use a basic scaffold template for a strongly-typed view. In this case, I am associating it with a Category class and using the Create template. I now need to modify the controller code to process requests to AddCategory. I need to handle two types of requests, GET and POST, because the view will be displayed to both add an item and submit an item:

public ActionResult AddCategory(){ return View(); }[HttpPost]public ActionResult AddCategory(Category category){ if (ModelState.IsValid) { engine.AddCategory(category); return RedirectToAction("MainView"); } return View();}For a GET request, I am simply returning the view. For a POST view, I am adding the category that was defined by the bound model through the local DataEngine instance, after which the user is redirected to the main view. But we also need to add an ActionResult for the MainView to obtain the list of items that are currently in the Categories table:

public ActionResult MainView(){ var categories = engine.GetAllCategories(); return View(categories);}The DataEngine instance will return all categories in an IEnumerable form that are passed as the model for the main view. The layout of MainView.cshtml can be as simple as a table:

@{ ViewBag.Title = "Coding4Fun Dynamic Lockscreen"; }Coding4Fun Dynamic Lockscreen - Categories

ID Category Name @p.id @p.Name @Html.ActionLink("Images", "Images", new { categoryId = p.id }) @Html.ActionLink("Edit", "EditCategory", new { categoryId = p.id }) @Html.ActionLink("Delete", "DeleteCategory", new { categoryId = p.id }) @Html.ActionLink("Add Category", "AddCategory")The ActionLink helper allows me to invoke a view and, if necessary, pass specific parameters to it (e.g., when I need to identify the category that needs to be deleted or edited). Some of the views listed here are not yet created, but I can easily use placeholder names in any case.
The ultimate result for the main page will look like this:

Notice that you are also able to add new categories now by clicking on the Add Category link on the bottom. This will redirect you to the AddCategory view that we created:

Let’s see how to implement the category editing in the web frontend. First of all, create a new view in Views/Home and name it EditCategory. Use the Edit scaffold template. Like AddCategory, EditCategory needs to be handled in two separate ways for GET and POST requests in the controller:

public ActionResult EditCategory(int categoryId){ Category category; category = engine.GetCategoryById(categoryId); if (category != null) return View(category); return View("MainView");}[HttpPost]public ActionResult EditCategory(Category category){ if (ModelState.IsValid) { engine.UpdateCategory(category); return RedirectToAction("MainView"); } return View();}For a GET request, we need to identify the category that needs to be added by its index, so we are using a categoryId argument passed to the view, which is later used by the DataEngine instance to retrieve the category from the data store. For a POST action, the implementation for UpdateCategory from above is used, where a PATCH request is run with the serialized object bound to the view.
For the Delete action, no additional view is necessary but the controller still needs a handler, so we can use a snippet like this:

public ActionResult DeleteCategory(int categoryId){ engine.DeleteCategoryFromId(categoryId); return RedirectToAction("MainView");}You can use the same approach to add, delete, and edit items in the list of images. For adding images, however, you might want to pass the category identifier. When images are listed after the category has been selected, it is necessary to provide a way to identify the category to which new entities should be added. To do this, we can. in the main controller. pass the category index to the view when the Images action is being triggered:

public ActionResult Images(int categoryId){ var images = engine.GetImagesByCategoryId(categoryId); if (images != null) { ViewData["CID"] = categoryId; return View(images); } return View("MainView");}Afterwards, the categoryId value can be obtained by using the CID key for ViewData inside the view itself.
Let’s now take a look at how images are represented for each category. I created a custom view to list all the images associated with the Images category. If you look above at the controller code, you will notice that I am passing the category ID, through which the image set query is executed, and the returned collection is set as the bound model:

public ActionResult Images(int categoryId){ var images = engine.GetImagesByCategoryId(categoryId); if (images != null) { ViewData["CID"] = categoryId; return View(images); } return View("MainView");}When an image needs to be added, call the AddImage view. In HomeController.cs, it carries implementations for both GET and POST requests:

public ActionResult AddImage(int categoryId){ Image image = new Image(); image.CategoryID = categoryId; return View(image); }[HttpPost]public ActionResult AddImage(HttpPostedFileBase file, Image image){ if (file != null && file.ContentLength > 0) { var fileName = Path.GetFileName(file.FileName); var path = Path.Combine(Server.MapPath("~/Uploads"), image.CategoryID.ToString(), fileName); string dirPath = Path.GetDirectoryName(path); if (!Directory.Exists(dirPath)) Directory.CreateDirectory(dirPath); file.SaveAs(path); string applicationUrl = string.Format("{0}://{1}{2}", HttpContext.Request.Url.Scheme, HttpContext.Request.ServerVariables["HTTP_HOST"], (HttpContext.Request.ApplicationPath.Equals("/")) ? string.Empty : HttpContext.Request.ApplicationPath ); image.URL = Path.Combine(applicationUrl, "Uploads", image.CategoryID.ToString(), fileName); } if (ModelState.IsValid && image.URL != null) { engine.AddImage(image); return RedirectToAction("Images", new { categoryID = image.CategoryID }); } return View();}When a GET request is executed against the AddImage endpoint, I pass the category ID as the flag, signaling which category the image should be included in. When a POST request is executed, it can go two ways—either the user is passing an existing link to a hosted image or the user is uploading his own image to the local server. When an upload is inbound, HttpPostedFileBase carries the content that needs to be pushed to the server.
The upload component on the view itself is done by creating a form with a file input:

Or you could upload your own file:

@if (Model != null){ using (Html.BeginForm("AddImage", "Home", FormMethod.Post, new { enctype = "multipart/form-data", image = Model })) { @Html.HiddenFor(model => model.CategoryID); }}If there is no file selected, the system assumes that the user just decided to add an existing URL.
It’s important to mention that the upload workflow relies on the availability of the Upload folder. It is created by default when the project is deployed to the server, but you also need to make sure that the ASP.NET user on the machine where IIS is located has the appropriate write permission for the folder.
The Windows Phone 8 Application Foundation

Create a new Windows Phone 8 application and add a reference to Windows Azure Mobile Services Managed Client. It should be available in the Extensions section if you installed the Windows Azure Mobile Services SDK as I mentioned at the beginning of the article:

In App.xaml.cs you need to create an instance of MobileServiceClient that will be used as the central connection point to the database. Notice that I am using the predefined AMS and API KEY string constants:

public static MobileServiceClient MobileService =new MobileServiceClient(AuthConstants.AmsUrl, AuthConstants.AmsApiKey);The mobile application should also carry the data models for both the categories and images. That said, we can reorganize those a bit for a more convenient data binding layout. To ensure that we can reuse the classes from different application components, I am once again using the Coding4Fun.Lockscreen.Core project.
Create a new folder called Models and add a new class called Category:

using System.Collections.ObjectModel;namespace Coding4Fun.Lockscreen.Core.Models{ public class Category { public Category() { Images = new ObservableCollection(); } public int? id { get; set; } public string Name { get; set; } public ObservableCollection Images { get; set; } public override string ToString() { return Name; } }}We are still relying on a nullable index value, but now there is an ObservableCollection for images. The reason for using this specific collection type is because with an ObservableCollection, binding updates are performed automatically when new items are added or removed, therefore cutting the need to implement the notification mechanism.
The ToString function is overridden to simplify data extraction on binding. When a collection with categories will be hooked to a list, for example, I don’t have to create a converter or a property link.
For the Image model, create a new class called Image in the same Models folder:

namespace Coding4Fun.Lockscreen.Core.Models{ public class Image { public int? id { get; set; } public string URL { get; set; } public string Name { get; set; } public int CategoryID { get; set; } }}Application Workflow & Storage

Let’s talk about how image categories will be handled in the application. On application startup, the database is queried for the available categories and each of them is listed on the home screen. If the user taps on one of the categories, the database is queried for the images that are associated with the category index.
However, the user should also be able to create his own custom categories that will only be available in-app. Those categories can carry images from multiple other categories, if necessary, with the default reference set to the internal storage.
Since we are working with local storage, let’s create a helper class called LocalStorageHelper in the Coding4Fun.Lockscreen.Core project in the Storage folder. This class will carry basic read and write functions, allowing us to store data internally:

public static class LocalStorageHelper{ public async static void WriteData(string folderName, string fileName, byte[] content) { IStorageFolder rootFolder = ApplicationData.Current.LocalFolder; if (folderName != string.Empty) { rootFolder = await rootFolder.CreateFolderAsync(folderName, CreationCollisionOption.OpenIfExists); } IStorageFile file = await rootFolder.CreateFileAsync(fileName, CreationCollisionOption.ReplaceExisting); using (var s = await file.OpenStreamForWriteAsync()) { s.Write(content, 0, content.Length); } } public static async void ClearFolder(string folderName) { var folder = await ApplicationData.Current.LocalFolder.GetFolderAsync(folderName); if (folder != null) { foreach (IStorageFile file in await folder.GetFilesAsync()) { await file.DeleteAsync(); } } } public static async Task ReadData(string fileName) { byte[] data; StorageFolder folder = ApplicationData.Current.LocalFolder; StorageFile file = await folder.GetFileAsync(fileName); using (Stream s = await file.OpenStreamForReadAsync()) { data = new byte[s.Length]; await s.ReadAsync(data, 0, (int)s.Length); } return Encoding.UTF8.GetString(data, 0, data.Length); } }Notice that I am using the newly-introduced StorageFolder/StorageFile capabilities. If you worked with Windows Store application development, you are probably already familiar with them. Application.Current.LocalFolder gives me direct access to the local directory. which can be modified from within the application itself. It works in a manner similar to IsolatedStorageFile in Windows Phone 7, but with more flexibility when it comes to creating new folders and files and well doing file sweeps.
As I mentioned above, there will be internal data stored as XML. For this purpose, I need a class that carries serialization and deserialization routines, and I can simplify this task by using the Coding4Fun Toolkit Serialize.Save and Serialize.Open capabilities. Calls to these functions allow flexible serialization, where by default the static class is not aware of the serialization type, but is instead able to dynamically infer it from the incoming data. Once the byte layout is obtained for the content, I use the LocalStorageHelper class to write it to a file.
As there are multiple UI items that need to be bound to collections and object instances, I have a CentralBindingPoint class in my main project that is my main view model (it implements INotifyPropertyChanged). It implements the singleton pattern, so that the main instance is created on initialization and is subsequently re-used as necessary:

using Coding4Fun.Lockscreen.Core.Models;using System;using System.Collections.ObjectModel;using System.ComponentModel;namespace Coding4Fun.Lockscreen.Mobile{ public class CentralBindingPoint : INotifyPropertyChanged { static CentralBindingPoint instance = null; static readonly object padlock = new object(); public CentralBindingPoint() { Categories = new ObservableCollection(); CustomCategories = new ObservableCollection(); } public static CentralBindingPoint Instance { get { lock (padlock) { if (instance == null) { instance = new CentralBindingPoint(); } return instance; } } } private ObservableCollection _categories; public ObservableCollection Categories { get { return _categories; } set { if (_categories != value) { _categories = value; NotifyPropertyChanged("Categories"); } } } private ObservableCollection _customCategories; public ObservableCollection CustomCategories { get { return _customCategories; } set { if (_customCategories != value) { _customCategories = value; NotifyPropertyChanged("CustomCategories"); } } } private Category _currentCategory; public Category CurrentCategory { get { return _currentCategory; } set { if (_currentCategory != value) { _currentCategory = value; NotifyPropertyChanged("CurrentCategory"); } } } public event PropertyChangedEventHandler PropertyChanged; private void NotifyPropertyChanged(String info) { if (PropertyChanged != null) { System.Windows.Deployment.Current.Dispatcher.BeginInvoke( () => { PropertyChanged(this, new PropertyChangedEventArgs(info)); }); } } }}On the main page, I create a Pivot-based layout to have an easy way to transition between the web collections (categories) and the local ones:

For each of the collection types, there is a ListBox with a custom DataTemplate assigned for each item. The items are obtained from the Categories collection for web sets and the CustomCategories collection for local sets, both in the CentralBindingPoint view model.
The categories are loaded with the help of the DataEngine class that I added in the Data folder in the main application project. It is a wrapper for the Azure Mobile Services data operations, allowing me to aggregate the list of categories and images, given that I know the category index:

public class DataEngine{ async public Task GetCategoryList() { IMobileServiceTable table = App.MobileService.GetTable(); List data = await table.ToListAsync(); return data; } async public Task GetImagesByCategoryId(int categoryId) { IMobileServiceTable table = App.MobileService.GetTable(); List data = await table.Where(x => x.CategoryID == categoryId).ToListAsync(); return data; }}When the main page loads, I use the local DataEngine instance to call GetCategoryList and obtain a List collection that is subsequently transformed into an ObservableCollection through one of the default constructors:

async void MainPage_Loaded(object sender, RoutedEventArgs e){ CentralBindingPoint.Instance.Categories = new ObservableCollection(await dataEngine.GetCategoryList()); }When a category is selected in the web sets list, I assign the selected item as the current category and navigate to the ImageSetPage.xaml page that will display the associated images:

async void ListBox_SelectionChanged_1(object sender, System.Windows.Controls.SelectionChangedEventArgs e){ var box = (ListBox)sender; if (box.SelectedItem != null) { Category selectedCategory = (Category)box.SelectedItem; selectedCategory.Images = new ObservableCollection (await dataEngine.GetImagesByCategoryId((int)selectedCategory.id)); CentralBindingPoint.Instance.CurrentCategory = selectedCategory; NavigationService.Navigate(new Uri("/ImageSetPage.xaml", UriKind.Relative)); }}Notice that the images are not loaded at the same time as the categories; rather, they’re loaded only when a category has been selected, hence the GetImagesByCategoryId call on selection.
For a custom set, the procedure is pretty much the same, the only difference being the fact that image references are already present since those were deserialized from the local storage:

private void lstCustomSets_SelectionChanged_1(object sender, SelectionChangedEventArgs e){ var box = (ListBox)sender; if (box.SelectedItem != null) { Category selectedCategory = (Category)box.SelectedItem; CentralBindingPoint.Instance.CurrentCategory = selectedCategory; NavigationService.Navigate(new Uri("/ImageSetPage.xaml", UriKind.Relative)); }}In ImageSetPage.xaml I use a ListBox with a WrapPanel in the ItemsPanelTemplate, which ensures that I can have only two images in a row and any additions will be wrapped, with a fixed row length. You can get that control from the WPToolkit (formerly known as Silverlight Toolkit for Windows Phone, available on NuGet).

Here is the basic XAML layout:

Now that we have a basic skeleton for the incoming data, let’s see how it can be transformed into a live lockscreen, on which wallpapers can be cycled. In the ImageSetPage.xaml page I have a button in the application bar that allows me to set the current category as the source for the switching wallpapers.
Currently, each Image instance carries an image URL and the images can be located anywhere outside the application. This can cause problems with the wallpaper setting process, however, since the API only allows local images to be set as background. This means that I need to download each image to the local application folder:

private async void btnSetStack_Click_1(object sender, EventArgs e){ var isProvider = Windows.Phone.System.UserProfile.LockScreenManager.IsProvidedByCurrentApplication; if (!isProvider) { var op = await Windows.Phone.System.UserProfile.LockScreenManager.RequestAccessAsync(); isProvider = op == Windows.Phone.System.UserProfile.LockScreenRequestResult.Granted; } if (isProvider) { downloadableItems = new List(); fileItems = new List(); foreach (var image in CentralBindingPoint.Instance.CurrentCategory.Images) { downloadableItems.Add(image.URL); fileItems.Add(Path.GetFileName(image.URL)); } SerializationHelper.SerializeToFile(fileItems, "imagestack.xml"); LocalStorageHelper.ClearFolder("CurrentSet"); DownloadImages(); grdDownloading.Visibility = System.Windows.Visibility.Visible; }}First of all, I need to make sure that the application can set a lockscreen background and is registered in the OS as a provider. The application needs to state its intent to be able to access the wallpaper by adding this snippet to the WMAppManifest.xml, right after the Tokens node:

downloadableItems is a collection that represents the download queue. fileItems contains the local file names for each image that is about to be downloaded and will be serialized and used in the background agent to iterate through the category files. Whenever the download process is started, an overlay becomes visible to notify the user that the image acquisition process is in progress.
Also, notice the fact that I am calling LocalStorageHelper.ClearFolder, passing the name of the folder as the first argument. I do not want to keep images for sets that are not active, therefore when a new set is selected, the currently stored images are deleted from the CurrentSet folder and replaced by the ones that are about to be downloaded. The implementation of the ClearFolder function looks like this:

public static void ClearFolder(string folderName{ if (store.DirectoryExists(folderName)) { foreach (string file in store.GetFileNames(folderName + "*.*")) { store.DeleteFile(folderName + "" + file); } }}Once the file names are stored in imagestack.xml, the image contents are downloaded via DownloadImages:

void DownloadImages(){ WebClient client = new WebClient(); string fileName = Path.GetFileName(downloadableItems.First()); client.OpenReadAsync(new Uri(downloadableItems.First())); client.OpenReadCompleted += (sender, args) => { Debug.WriteLine("Downloaded " + fileName); LocalStorageHelper.WriteData("CurrentSet", fileName, StreamToByteArray(args.Result)); downloadableItems.Remove(downloadableItems.First()); if (downloadableItems.Count != 0) DownloadImages(); else { grdDownloading.Visibility = System.Windows.Visibility.Collapsed; LocalStorageHelper.CycleThroughImages(); //ScheduledActionService.LaunchForTest("LockscreenChanger", TimeSpan.FromSeconds(5)); } };}Here you can see that I am making a call to LocalStorageHelper.CycleThroughImages—a function that reads the file that contains the current set and picks the first image, assigning it to be the current wallpaper and then pushing it to the back of the list, making the succeeding image the next in line for the wallpaper:

public static void CycleThroughImages(){ List images = Coding4Fun.Phone.Storage.Serialize.Open("imagestack.xml"); if (images != null) { string tempImage = images.First(); Uri currentImageUri = new Uri("ms-appdata:///Local/CurrentSet/" + tempImage, UriKind.Absolute); Windows.Phone.System.UserProfile.LockScreen.SetImageUri(currentImageUri); images.Remove(tempImage); images.Add(tempImage); Coding4Fun.Phone.Storage.Serialize.Save("imagestack.xml", images); }}You might be wondering why I’m not using Queue for this. After all, Enqueue and Dequeue would make things a bit easier. The problem is that a Queue instance cannot be directly serialized without being transformed to a flat list. Therefore, I am sticking to minimal resource processing by manipulating a List instance instead.
The recursive image download method runs until the download queue is emptied, after which the overlay is hidden.
Background Agent

At this point, we have the images locally stored and listed in an XML file. If the user accepted the system prompt, the application has also been registered as a lockscreen background provider, but there is not yet a single piece of code that would actually set the wallpaper cycle. For that, create a new Background Agent project in your solution. I named mine Coding4Fun.Lockscreen.Agent.
The OnInvoke function in ScheduledAgent.cs is executed at 30-minute intervals. This is a time limit defined by the PeriodicTask background agent type that we’ll be using here. You need to add the following snippet to it:

protected override void OnInvoke(ScheduledTask task){ var isProvider = Windows.Phone.System.UserProfile.LockScreenManager.IsProvidedByCurrentApplication; if (isProvider) { LocalStorageHelper.CycleThroughImages(); } NotifyComplete();}As with the download snippet, I am ensuring that before I attempt to change the wallpaper the application is a registered provider. Otherwise, an exception will be thrown and the background agent will crash. The bad thing about periodic tasks crashing is the fact that once two consecutive crashes occur, the task is removed from the task queue and the backgrounds will not be changed.
If the application is a provider, call CycleThroughImages to set the new background and push the old one to the end of the list. To make sure that a different image is selected each time, the original deserialized list is modified, where the first image now becomes last, switching the stack up, after which it is serialized back into imagestack.xml.
The background agent needs to be registered in the WMAppManifest.xml. Inside the Tasks node, add an ExtendedTask:

Also, when the application starts, you need to ensure that the task is registered, and register it if it isn’t yet. Use the Application_Launching event handler for this task:

private void Application_Launching(object sender, LaunchingEventArgs e){ string taskName = "LockscreenChanger"; var oldTask = ScheduledActionService.Find(taskName) as PeriodicTask; if (oldTask != null) { ScheduledActionService.Remove(taskName); } PeriodicTask task = new PeriodicTask(taskName); task.Description = "Change lockscreen wallpaper."; ScheduledActionService.Add(task); LoadCustomCategories(); }Here, LoadCustomCategories will deserialize the existing custom categories, so that those can be shown in the main page after the application starts:

private async void LoadCustomCategories(){ try { CentralBindingPoint.Instance.CustomCategories = (ObservableCollection)await SerializationHelper.DeserializeFromFile( typeof(ObservableCollection), "customcat.xml"); } catch { Debug.WriteLine("No customcat.xml - no registered custom categories."); }}Now the backgrounds will automatically change based on the web sets that you will activate every 30 minutes.
Working with Custom Categories

Let’s create some custom sets. To manage user input, I leverage the CustomMessageBox control available in the Windows Phone Toolkit. It has enough flexibility to let me choose between adding a TextBox control, to have the user create the new category or use a ListPicker to show the available custom categories in a consistent UI layout.
When the user decides to create a new category, he taps the plus button in the application bar on the main page:

The implementation for the call is simple:

private void btnSetStack_Click_1(object sender, EventArgs e){ TextBox textBox = new TextBox(); CustomMessageBox box = new CustomMessageBox() { Caption = "Add Custom Category", Message = "Enter a unique name for the new category.", LeftButtonContent = "ok", RightButtonContent = "cancel", Content = textBox }; box.Dismissed += (s, boxEventArgs) => { if (boxEventArgs.Result == CustomMessageBoxResult.LeftButton) { if (!string.IsNullOrWhiteSpace(textBox.Text)) { var categoryCheck = (from c in CentralBindingPoint.Instance.CustomCategories where c.Name == textBox.Text select c).FirstOrDefault(); if (categoryCheck == null) { Category category = new Category() { Name = textBox.Text }; CentralBindingPoint.Instance.CustomCategories.Add(category); Coding4Fun.Toolkit.Storage.Serialize.Save( "customcat.xml", CentralBindingPoint.Instance.CustomCategories); } else { MessageBox.Show("Add Custom Category", "This category name was already taken!", MessageBoxButton.OK); } } } }; box.Show(); }When the message box is dismissed, I check which button is pressed to take the appropriate course of action. Let’s assume that the user decided to add the new category—we need to check and make sure that there isn’t already a category with the same name in the existing collection. If there isn’t one, a new Category instance is created, added to the collection in the main view model, and serialized to customcat.xml.
The user also needs to be able to add images from any category to another custom category. To do this, I decided to give the user the option to carry across the image name and URL when he taps on an image in the ImageSetPage.xaml.
Remember, if there are no current custom categories registered, the user should be informed that he should create some first, so the alternative route for the dialog with custom category name selection should be a message box alert:

Here is the snippet that does this:

private void lstImages_SelectionChanged_1(object sender, SelectionChangedEventArgs e){ if (CentralBindingPoint.Instance.CustomCategories.Count > 0) { if (lstImages.SelectedItem != null) { ListPicker picker = new ListPicker() { Header = "Custom category name:", ItemsSource = CentralBindingPoint.Instance.CustomCategories, Margin = new Thickness(12, 42, 24, 18) }; CustomMessageBox messageBox = new CustomMessageBox() { Caption = "Add To Custom Category", Message = "Select a registered custom category to add this image to.", Content = picker, LeftButtonContent = "ok", RightButtonContent = "cancel" }; messageBox.Dismissing += (s, boxEventArgs) => { if (picker.ListPickerMode == ListPickerMode.Expanded) { boxEventArgs.Cancel = true; } }; messageBox.Dismissed += (s2, e2) => { switch (e2.Result) { case CustomMessageBoxResult.LeftButton: { if (picker.SelectedItem != null) { Category category = (from c in CentralBindingPoint.Instance.CustomCategories where c.Name == picker.SelectedItem.ToString() select c).FirstOrDefault(); if (category != null) { category.Images.Add((Coding4Fun.Lockscreen.Core.Models.Image)lstImages.SelectedItem); Coding4Fun.Toolkit.Storage.Serialize.Save( "customcat.xml", CentralBindingPoint.Instance.CustomCategories); } lstImages.SelectedItem = null; lstImages.IsEnabled = true; } break; } case CustomMessageBoxResult.RightButton: case CustomMessageBoxResult.None: { lstImages.SelectedItem = null; break; } } }; messageBox.Show(); } } else { MessageBox.Show("Add To Custom Category", "Tapping on an image will prompt you to add it to a custom category" + Environment.NewLine + "Seems like you don't have any custom categories yet.", MessageBoxButton.OK); }}Once the category is selected from the list, the image is added to the Images collection in the Category instance, and the category list is serialized to preserve the changes. There are no restrictions as to which categories can fetch images to other categories—we can even select images from custom categories and include them in other categories. The image can be added multiple times to the same category as well.
Conclusion

With Azure Mobile Services and a managed SDK available for Windows Phone, as well as an open REST API, it is fairly easy to build connected applications on multiple platforms at once without major logic and code base modifications.

More...





Windows 7 Forums recommends Auslogics BoostSpeed to repair Windows errors. Get it now.
May 1st, 2012: 25% off. Use coupon code: WINDOWS7FORUMS

Optimize every aspect of Windows 7 with the System Advisor or manually.Repair corrupt registry entries and defragment the registry.Disable and enable services based on how you are using your computer.Adjust and edit hundreds of settings to fix your computer in a few easy clicks.Includes File Recovery (undelete) free of charge.

Other Auslogics software:

Auslogics Antivirus
Auslogics File Recovery
Auslogics Disk Defrag Pro

Auslogics BoostSpeed 5 is quite possibly the best overall system maintenance tool of the year. Having received 5 stars from CNET, they also receive a 10/10 full endorsement from Windows7Forums.com. BoostSpeed isn't just about making your computer fast: It's about making preventative maintenance manageable through one application. While the market calls for a typical system scan to attract buyers, that scan is entirely legitimate, and does correct serious registry problems in a way that far exceeds industry expectations. CCleaner, for example, can hardly hold a candle to this utility.

Looking closer at the System Advisor, we can determine whether or not the Internet connection can be automatically optimized. This is done with BoostSpeed through a manual or automatic setting in the Auslogics Internet Optimizer. Auslogics Registry Defrag will let you know that you can reduce registry access time and increase overall system performance by running this tool. This is a very delicate task that most freeware applications will not take on. Defragmenting the registry involves significant risk if there is a failure and that is why Auslogics BoostSpeed 5 comes with a Rescue Center, which can literally allow you to backup the changes that have been made within the program. The program will even automatically create these restore points before adjusting your system for perfect fine tuning.

If the Disk and Registry Maintenance options weren't enough, Auslogics BoostSpeed 5 comes with in-depth ways to determine and modify your System Status and Privacy. If that weren't enough, the System Tweaks area allows you to optimize your Windows services around how you use your computer. This can be so useful in a work environment, as most system services continue running unabated, even when they will never be used!

Control over startup items and installed software has never been easier. Needless duplicate files found on a system can be deleted and disks can be explored to discover what is eating up all of that storage space. The System tweaks area is where Auslogics BoostSpeed really shines. It contains management options for the User Interface, Start Menu, Taskbar, Windows Explorer, System Security, Startup and Shutdown, System, Internet Explorer, Microsoft Office, and numerous additional Software Tweaks.

"Hi, I’m Jessica Dolcourt from CNET Download and this is a first look at Auslogics BoostSpeed. This is a top rated program that attempts to defrag, tweak, and otherwise optimize the computer where its most likely to get bogged down. Looking at the clean launch interface, you might never guess that there are 18 tools bundled into one app. The main pane is dominated by shortcuts for testing the health of the system. One Button Checkup will scan for issues and attempt to fix them. For instance, Disk Cleaner’s job is to find and remove junk files. With most scans you run, you’ll have the opportunity to take a closer look at the files, and to back them up before you change anything. Since the goal of the program is to optimize performance, BoostSpeed often frames problems in terms of how much space you would free if you deleted the loose files. On the left, the system tools are organized by activity: Computer, Cleanup, Optimization, Privacy, Settings, and so on. When you click the task category, you’ll see the available tools and a brief description of what they do. Clicking the tools launches it in a separate window, so that you can return to this main interface at any time. Most tools are easy to work their way around, and most changes can be undone in Auslogics Rescue Center, which you can get to from individual tool interfaces or from the settings on the BoostSpeed panel interface. In the Rescue Center, you’ll see a list of the changes you’ve made. You’ll be able to see full details for each entry and view archive backups as well. Which system files BoostSpeed will back up, and which it will leave alone, are things you can specify in the program settings, under the tab that says Rescue Center. We’re fans of Auslogics BoostSpeed for its comprehensive system maintenance and nicely packaged interface. Some of the app’s component parts are offered as stand-alone freeware products, such as the Disk Defrag…" - Courtesy CNET Review of Auslogics BoostSpeed

Under User Interface:
Disable AeroMake menu bars and window frames opaque instead of translucentDo not animate windows when minimizing and maximizingSlow the window animations when holding Shift keyDisable 3D Window SwitchingAdd context menu to activate Flip 3DTurn off Aero PeekTurn off Aero SnapTurn off Aero Shake
Under Visual Effects:
Hide window contents while draggingDo not drop shadows under icons on the desktopDo not use translucent selection rectangleShow Windows version in the desktop bottom right cornerSelect how you want the arrows displayed on shortcuts
Under Animation:
Do not allow window animationDo not use smooth scrolling for list boxesDo not animate drop-down listsSelect tooltip animation types
Menu:
Do not use menu fading animation effectsHide shadows under menusHide underlined letters for keybaord navigation until ALT is pressedMenu animation effects optionsDelay before displaying submenus (in milliseconds!)Full font smoothing optionsExtended ClearType and Standard font smoothing options
Start Menu:
Hide "Log Off" from the Start MenuHide the "Run itemHide "Set Program Access And Defaults" ("Default Programs" in Vista)Hide the "Help and Support" itemHide the "All Programs" menuHide "Administrative Tools"Hide the list of frequently used programsHide the list of pinned programsHide the "See more results" link
Under Folder options determine whether to hide individual items, show them as a link, or show them as a menu easily

Effects:
Do not highlight recently installed programsDo not show partially installed programs in grayDo not sort the "All Programs" menu by nameDisable the context menu and drag itemsDisable the "Start" button tooltipExpand menu when you hover the mouse pointer over an itemEnable small icons in the Start menu
Taskbar:
Show notification areaDo not display tooltips in the notification areaDo not hide unused icons in the notification areaDo not display the network activity icon in the notification areaDo not display the sound settings icon in the notification areaDo not display the battery icon in the notifications areaAuto-hide taskbarDo not slide taskbar buttonsAllow moving or rearranging taskbar itemsGroup similar buttons: Do not group, Group when full, Always group and hide tagsButtons: Configure advanced settings for taskbar application buttons
Explorer:
Show hidden filesShow file extensionsuse Windows classic foldersDisplay checkboxes to help select multiple filesAlways show the menu bar in Windows ExplorerDisable file and folder pop-up descriptionsDisplay folder size in the folder tooltip
Thumbnails:
Disable thumbnail cache creationDo not display thumbnails in network foldersThumbnail quality - 0-100%Thumbnail size in pixelsShow address bar folder path autocompleteShow address bar folder path autosuggestShow address bar maximized as a drop-down listInclude variable "PATH" into search pathDisable automatic replacement of a blackslash to a forward slash
Context Menu:
Show "Open Command Prompt"Show "Send To"Show "Copy to Folder..."Show "Move to Folder..."Show "Run as administrator"Show "Take ownership"Show "Search..."
Options:
Restore open Explorer windows when you restartDisable CD burning functions in Windows ExplorerRun Desktop and Explorer tasks as seperate processesRun each Explorer window as a seperate processAutomatically restart the shell if a shell error occursDisable the option to search the Internet when you open a file with unknown extension
Explorer items:
Display encrypted and compressed files and folders in a different colorDrive letter is displayed after disk labelDrive letter is displayed before disk labelDrive letter is displayed before disk label for network driveDrive letter is not displayed!
Autoplay:

Disable autorun for:
Removable drives (Floppy, flash-drive, etc)Non-removable drives (hard disk, etc)Optical disk drives (CD, DVD, etc)Temporary memory disk (RAM-disk)Network drivesUnknown drive types
Command Prompt:
Enable advanced modeEnable delayed expansion of environmental variablesEnable quick editingFile names autocomplete hotkeyFolder names autocomplete hotkey
System Security:
Disable User Acount ControlSet all UAC options including advanced options only found in registry
Privacy Policy:
Wipe page file on computer shutdownClear the "Recent documents" list on logoffDo not create the "Recent Documents" listDo not store your logon password on the diskDisable hidden sharesDisable user trackingEnable encrypt/decrypt options in ExplorerDisable Faster User Switching
For anonymous users:
Access is allowed with the default settingsTransfer of accounts and SAM names is prohibitedAccess is denied if permits are not specified
Windows Defender:
Disable Windows DefenderDisable heuristic scanningDisable archive scansDisable removable media scansDisable e-mail scansDisable real-time protectionDisable real-time protection promptsDisable downloads checkupDisable executable files checkupDisable definition updates through alternate download locationsCheck for new signatures before scheduled scansDo not log unknown detectionsDo not log known good detections
Startup and Shutdown:
Disable Windows startup soundDisable parsing AUTOEXEC.BATDisplay information about previous logons during user logonDisable Ctrl-Alt-Del before logonRun logon scripts simultaneouslyOptimize system files placement on the diskSpecify time to wait before running Check Disk (chkdsK) in seconds
Event Logging:
Do not log any eventsLog standard events onlyLog all startup and shutdown events
Legal Notice:
Write any legal notice you want during startup of Microsoft Windows
Automatic login:
Use autologin and set credentials, including username, password, and domain
System:

OEM Info:

Configure Windows OEM attributes, such as the manufacturer's logo and support information that appears in the System Properties window.

This includes:
ManufacturerModelSupport URLWorking HoursPhone120x120 pixel logo
Application Start:
Disable "Program Compatibility Assistant"Disable "Program Compatibility Wizard"Disable running 16-bit applicationsRun 16-bit programs as a separate processAdd checkbox "Run in seperate memory space" for 16-bit applications
Error Handling:
Disable sound when errors occurAutomatic restart in case of a critical errorSend error reportsShow error notification in windowDon't save reports on your computerDon't send additional information in a reportDon't write error information into system log
If an error occurs:
Ask user consent to send a reportAutomatically include only basic information in the reportAutomatically include all but personal data in the reportAutomatically include all data in the report
Internet Explorer:

Interface:
Disable visual-styled controls in Internet Explorer pagesDisable page transitionsDisable Clear Type fontsDisable smooth scrollingDisable autoamtic updatesAlways show menusDo not show extended error messagesDo not show the welcome text for new opened tabsDo not show warning messages when closing tabsDo not send bug reports via the InternetAlways ask before downloading filesPlace the menu above the address bar
Behavior:
Let Internet Explorer decide how pop-ups should openAlways open pop-ups in a new windowAlways open pop-ups in a new tab
Specify how Internet Explorer displays a web page when it's launched from another program:
Opens in a new windowOpens in a new tab in the current windowOpens in the current tab or window
Connections
Speed up web browsing in IE by using more concurrent Internet connectionsIncludes anywhere from 1-20 connections (Default is 4)
Options:
Default file download directoryHome PageCaption string that is displayed after the page title
Microsoft Office:
Do not track document editing timeBlock updates from the Office Update SiteDisable Customer Experience Improvement programDisable error reportingDisable logging Microsoft Office activityDisable Office DiagnosticsDisable clipboard dialog boxPrevent Office Help from resizing the application window
Microsoft Word:
Do not check spelling as you typeDo not check grammar as you typeDo not use background printingDo not auto-save background printingDo not auto-save documents in the backgroundDo not use translucent selectionDo not check if MS Word is the default HTML editor
Microsoft Excel:
Show Formula bar in Full ViewCache spreadsheetsCache PivotTable reportsUndo steps: Set from 0 to 100
Software tweaks (The ones we can see so far)

Skype:
Disable file transferDisable loading language filesDisable publishing Skype status on the WebDisable Skype Public APIDisable checking for updatesDisable listening for TCP connectionsDisable UDP communications
Windows Media Player
Disable auto-updatesDisable automatic codec downloadsDisable Windows Media Digital Rights Management (DRM)Disable video smoothingDisable CD and DVD Media information retrievalDisable music file media information retrievalDisable media file sharingDisable script handling in media filesHide the "Privacy" tab in the settingsHide the "Security" tab in the settingsHide the "Network" tab in the settings
Adobe Reader:
Disable splash screenDisplay PDF in the browser windowDisable Purchase Acrobat item in the menu
Firefox:
Disable link prefetchingDo not reduce memory when minimizedDo not download favorite icons (favicons)Disable blinking elementsForce frames to be reesizableUse old style for opening tabsShow all images / Block all images / Load images from the requird site only and block images from othersClose Tab Button full range of optionsHow long Firefox waits for the web page data before it displays the page (From 0 to 1 sec)
System Information includes everything:
OverviewGeneralHardwareCPUMotherbaordMemory ModulesVideoStorageIO DevicesInput DevicesModemsNetwork AdaptersResourcesProblem DevicesOperating SystemProgramsNetworkApplication ErrorsDevice ManagerMemory UsagePerformance
Tasks show Applications, processes, services, and locked files. You can unlock locked files, change the status of services, end processes, and modify application data.

Auslogics Disk Explorer will show what folders are taking up the most space and allow you to delete empty folders on your system.

File Recovery allows you to undelete files.

Speed Up Internet includes:
Automatic tuningAuto HeuristicsDefault TTLGlobal Max TCP WindowMax MTUTCP Window SizeMax Connections Per 1_0 ServerMax Simultaneous HTTP ConnectionsFirefox Max ConnectionsFirefix Max Connections Per Server
TCP/IP
1323 OptsACK FrequencyARP Cache LifeARP Cache Min Reference LifeARP Cache SizeAuto HeuristicsAuto TuningCongestion ControlDefault TTLDel ACK TicksDisable Task OffloadECN CapabilityEnable PMTU BH DetectEnable PMTU DiscoveryFin Wait DelayGlobal Max TCP Window SizeInitial RTTIPv6 over IPv4Keep Alive InternalKeep Alive TimeMax Connect RetriesMax Data RetransmissionsMax Dup ACKsMax MTUNum ConnectionsReceive-side ScalingSACK EnabledTCP Window SizeSYN Attack ProtectTimed Wait DelayUse RFC1122 Urgent Pointer
Winsock:
Default Receive WindowDefault Send WindowLarge Buffer SizeMedium Buffer SizeNon Blocking Send Special bufferingSmall Buffer SizeTransmit Worker
Workstation:
Request Buffer SizeUse Raw ReadUse Raw WriteUse Write Raw Data
Dns Cache:
Adapter Timeout TimeHash Table Bucket SizeHash Table SizeMax Entry TTL LimitMax SOA Entry TTL LimitNegative SOA TimeNegative TimeNet Failure Time
Internet Explorer:
DNS Cache EnabledDNS Cache TimeoutKeepAlive TimeoutMax Connections Per 1_0 ServerMax Connections Per ServerReceive TimeoutServer Info TimeoutSocket Receive Buffer LengthSocket Send Buffer LengthTCP Autotuning
Firefox:
Disable IPv6DNS Cache EntriesDNS Cache ExpirationHTTP Connect TimeoutKeepAlive TimeoutMax ConnectionsMax Connections Per ServerMax Persistent Connections Per ServerMax Persistent Connections Per ProxyPipeliningPipelining Max RequestsPrefetch NextProxy PipeliningUse KeepAliveUsing Proxy KeepAlive
(Auto-optimization is based on Over 1Mbps / 1Mbps or lower (default that Windows assumes) / or 128kbps or lower)

The built-in System Advisor determines (THESE ARE JUST SOME):
Can the Internet connection be optimized?Is the registry fragmented?Can Windows shutdown be sped up?Can incorrect drivers be updated? (It updates them in Auslogics Device Manager)
Quick Tasks allow you to:
Erase browser historyErase Windows historyCleanupt emporary filesOptimize memory
Privacy allows you to shred files and wippe entire disks.

Let's check that one again:
Disk MaintenanceFree Up SpaceRemove DuplicatesExplore diskDisk cleanupDisk defragmentDisk repairSoftware ControlSystem TweaksService OptimizationDisaster RecoveryFile RecoveryRescue CenterRegistry MaintenanceRegistry RepairRegistry DefragmentSystem StatusSystem InformationSystem TasksSystem ServicesLocked FilesComputer PrivacyErase Computer HistoryShred FilesWipe disksSpeed Up InternetInternet OptimizationMemory Optimization
It is quite probable that Auslogics BoostSpeed is the best program on the market for system repair and optimization EVER. Even if you don't know how to use the options listed above, that is why this program is great. It really DOES it for you. It really does repair your registry, with money behind it that went into big time research and development.

Their previous freeware products have been used regularly by IT professionals, but this product includes absolutely everything. There is nothing missing in this program, and updates are absolutely frequent. It is the one application I would recommend to every member of Windows7Forums.com without hesitation. Even if you do not know what these settings mean, this program will optimize and repair your system without any doubt. Today, there are so many programs that "claim" to do this and do that. When we saw Auslogics offering a commercial solution I had to start offering it on my website after I saw what it could do. I had to make a video about it. I had to find a way to provide a discount to members.

I have recommended it to my mother, my grandparents, and I will bring it up to a client I am currently working with tomorrow who is asking for Windows XP. This is the program that you need to automatically manage your system and keep it up-to-date, speedy, and performing in top condition.

Windows 7 Forums Rating: 10/10 Stars

Don't take my word for it. CNET gave them 5/5 stars too!

Watch our YouTube video for an exclusive discount offer.




These words below are mine.I created them,I wrote them.Even though Engel
uses them nearly everywhere.I just do not like somebody to copy and paste
them,to use them fully because these words are NOT created by him. I am angry.

I just post to everybody know and understand who these words belongs to.
They belongs to me...:-)

And a question :
Is there a way to stop and prevent him from coping these words fully ?!

MALWARE REMOVAL INSTRUCTIONS

Follow them carefully and step-by-step.
All cleaning actions should be done
without internet connection

1. Download the necessary software

@ SpyBot Search and Destroy
http://www.safer-networking.org/microsoft.en.html

@ Ad-Aware SE Personal
http://www.lavasoftusa.com/software/adaware

@ Microsoft Antispyware (only for genuie Windows versions)
http://www.microsoft.com/athome/secu...s/default.mspx

@ CWShredder
http://housecall.trendmicro.com

@ Antivirus software (if you still do not have)

Panda Titanium 2005
http://www.pandasoftware.com/microsoft

Specific
If you are non-XP user and still do not have firewall,
you should get free one from he
http://www.microsoft.com/athome/secu...s/default.mspx

Optional
There are some malwares that can destroy the internet connection
when you try to remove them.That's why you may get that program
that could restore your internet connection.
I haven't tried it but lots of people like them.

Win Sock XP Fix
http://www.spychecker.com/program/winsockxpfix.html

2. Create a back-up of all your critical information
This is just an option.
You should check it for viruses later.

3. Run a Firewall

Windows XP
has integrated firewall -
Internet Connection Firewall (ICF) for SP1 and
Windows Firewall (WF) for SP2

Windows versions different from XP
They do not have integrated firewall ,they have to use software firewall.

!!! Use only 1 firewall !!!

4. Windows Updates
Connect to internet and
download all the security updates - Critical updates with Express install.

Start - Windows Updates
or
http://windowsupdate.microsoft.com

5. Install and Update

SpyBot Search and Destroy
Ad-Aware SE Personal
Microsoft Antispyware
CWShredder

6. Delete all the Internet Explorer's temporary stuff

Start - Settings- Control Panel - Internet Options

There ,on the General Tab you will see where you can delete
internet temporary files
cookies
history
Delete them all.

7. Delete all Temporary files

| Windows XP users (all new versions) |

The path is :
C:Documents and SettingsUSERLocal SettingsTemp
Delete all files from this folder
and also
C:WindowsTemp

| Windows 98 users (all old versions) |

The path is :
C:WindowsTemp

8. Remove any unwanted programs

Boot in Safe Mode (see how below)
Then ,in Safe Mode, Start - Settings – Control Panel – Add /Remove programs
See if you have any unknown /unwanted software
installed- toolbars and/or known spy programs.
Remove them with the REMOVE button.
Also check for tracks of these programs in
C:Program files and delete,if any.
Then restart with booting in Normal Mode .

9. Run Disc Clean up

Start - Programs - Accessories - System Tools - Disc Cleanup

Make sure you have checked :
Downloaded program files
Temporary Internet files
Temporary files
Recycle bin
Web Client/Publisher content

10. Remove viruses /worms /trojan horses

@ Scan with Microsoft Windows Malicious Software removal tool

http://www.microsoft.com/malwareremove

@ Scan with

Panda Software free Active Scan,where you can check your
PC for ALL TYPES of security threats and clean viruses and worms

http://www.pandasoftware.com/product..._principal.htm

@ Install the antivirus software

Boot in Safe Mode and install the antivirus software
In Safe Mode,because there are viruses
that have the ability to damage an antivirus while installing it

How to boot your computer in Safe Mode

Do this by repeatedly typing F8 while Windows is starting before
Windows logo appears.
Then you'll open the BIOS menu where you can choose to boot
the hard drive in SAFE MODE

(If you are XP user ,find more about Safe Mode
in Help and Support Center ; Start-Help and Suport)

@ Update the antivirus and scan with it

Boot in Normal Mode and update it.
Make sure you have all functions ON
(scanning all files,heuristic,disinfect,scanning for other threats...)

Perform a full scan in Normal Mode first
Then boot in Safe Mode and also perform a scan

@ While still in Safe Mode,scan with these

SpyBot S&D
Ad-Aware SE Personal
Microsoft Antispyware
CWShredder

and remove the junk
!!! They must have already been updated !!!

When the scan is finished,
DO NOT restart ,if you have Win XP or ME

System Restore (for XP and ME only)

Because of the fact malware is a program,
System Restore also stores all malware tracks and when restarting,it can
replicate some infected system stuff and the malware will be back !!!
So you need to delete all the restore points before restarting :

Right click on My Computer-Properties-System Restore
Check Turn off system restore.Click OK

Restart the in Normal mode.

11. For better performance ,it is advisable to check your hard drives for
errors
Open My computer .
Then right click on the hard drive you want to check - Properties - Tools
In the error-checking area ,click "Check now" to start the process.

At the end (when the system is malware-free)
again Right click on My computer-Properties-System Restore
Uncheck Turn off system restore ,so you'll have your Restore function ON.

After these,your computer should be clean !
If you do not understand something,you can post again and ask for
information
If the instructions seems difficult to you,you can take your computer to
a computer store where IT specialist would help you wipe out the junk!
Don't be shame.

--- Useful pages ---

http://www.microsoft.com/athome/secu...s/default.mspx
different kinds of free or trial security software.

http://www.pandasoftware.com/about/r...ldren_internet
Because of the campaign "Children and the Internet"
Panda Software offers 90 day free trial version of one of the best security
software
Panda Platininum Internet Security 2005 awarded with many prizes

http://www.pandasoftware.com/protected/tips.htm ;
useful tips for protecting computers

http://www.pandasoftware.com/product..._principal.htm
Panda Software free Active Scan,where you can check your
PC for ALL TYPES of security threats and clean viruses and worms

http://housecall.trendmicro.com
Trend-Micro free online scanner HouseCall where you can scan for
Viruses and Spywares and clean them. CWShredder is also available here

http://www.kaspersky.com/virusscanner
Kaspersky free online scanner
and checker for suspicious files.If you have issues with suspicious
file,here is the right place!

http://www.f-prot.com/virusinfo/submission_form.html
Send F-prot AV suspicious files for fast analyze and and it is all for FREE

http://www.microsoft.com/malwareremove
Microsoft Windows Malware Removal Tool

http://www.microsoft.com/windowsxp/u...nfectedpc.mspx
Microsoft MVP Charlie Russel's article about Dealing with malware
Really good and detailed

http://support.microsoft.com
Free Microsoft support and suggestions (for genuie clients)

Now ,when you have cleaned your computer,you need to think about your
security!
Microsoft
suggests 3 + 1 general steps how to protect
your PC and the infomation stored on it,
your privacy and your family
1.Use an internet firewall
2.Enable Automatic Updates for your PC
3.Use an antivirus software
4.Use antispyware software

Goto http://www.microsoft.com/athome/security and learn more
Check the Security Essentials for your OS and also have a look at all
sections!

Panda_man
" Let's beat malware black and blue"
" No new epidemic of all kind of malware - Panda TruPrevent"

| SETTING UP A COMPUTER |

When you first turn on your computer
it is adviseable to first have a look at its setings.

** If you use Windows XP **

1 .Create as many computer accouts as you need

If your computer is going to be used from more than one person
(family members,friends,colleagues ,etc...) ,
make others limited users and you - Administrator
So that you'll have full control of the PC,but they would only be
able to change their files and few settings only !

If you are a parent and would like your children to access the internet,
create the limited user accounts.More about the parental control below

!!! Windows XP has hidden built-in administartor account
accessable and visible only in Safe Mode.
Get into Safe Mode and password protect it.
In Safe Mode,goto Control Panel -User accounts and click on the name
of that hidden account,called Administrator !!!

| How to boot your computer in Safe Mode |

Do this by repeatedly typing F8 while Windows is starting before
Windows logo appears.
Then you'll open the BIOS menu where you can choose to boot
the hard drive in SAFE MODE

(If you are XP user ,find more about Safe Mode
in Help and Support Center ; Start-Help and Suport)

2. Password-protect your account and your files

Make strong password,
with numbers,letters and at least one special character
Start - Settings - Control Panel - User accounts

When you decide to password protect your account,
after creting a password Windows should ask you if you want
to protect your files also.Click YES

or
Click on the folder you want to password-protect-Properties
Click on Sharing tab -Make this folder private

** All Windows Versions **

Start - Settings - Control Panel
or My computer -Control Panel

3. Have a look at

Display settings
Date and time Settings
Mouse and Keyboard settings
Power Options
Regional and language settings
Sound settings
Start Menu Settings

4. I do not recommend any user to install programs like

WinAmp ,Real Player
or WinZip (in Win XP )
Because of the fact Windows has integrated Windows Media Player ( 2 versions)
plus (Zip archiver in XP ) ,it is pointless to install such programs

5. Do install programs like

Adobe Reader / Acrobat because it is useful and with it
you can read PDF files which become more wide-spread everyday
http://www.adobe.com

6. If you do not have Microsoft Office

Download
1. Open Office
http://www.openoffice.org

2.Microsoft Word viewer / Excel viewer / Power Point viewer
http://www.microsoft.com ; ,click on Office

Open Office is free as well as Microsoft viewers.
Open Office is not as good as MS Office but would do the basics

| THINK ABOUT INTERNET |

1. After you go on-line,upgrade to the newest Service Pack available for
your OS .
http://windowsupdate.microsoft.com
Learn more about the SP in Microsoft web-site and read the preparation steps !

2. Also download all critical updates with Express install.

I recommend you to use only Internet Explorer as an internet browser
as well as Outlook Express for your mail program
Many people may think them as not as secure as other but that is not true.

| PARENTAL CONTROL |

Internet is useful for everybody and even for the children
They can search information for school project,listen to music,play on-line
games
and even talk to friends
But it is even dangerous
What I recommend is to talk to your child/children and to explain them about
the activities they don't have to do while online

Then,do not trust your children fully.Install a good software/s/ to help
protect your PC and your family's privacy

So....
1. Create your children limited user accounts in Windows XP

So they will have their own My documents folder
but will not be able to access PC settings
Limited users can download everything but cannot install anything
,so they cannot install any spyware/virus in the family's computer.

Children limited account should NOT be password-protected !!!

Parent administartor account should be password-protected !!!

2. Turn on Internet Explorer's Content Advisor

It would help your children not to open pornographic pages
and pages with bad content
Start- Settings - Control Panel - Internet Options - Content tab
and then enable it and check the settings

2.1 MSN toolbar
This toolbar become more useful everyday
It has either pop-up blocker and also Anti-Phising filter
Recently Microsoft had established this Anti-phishing filter
as an add-in for the Toolbar
http://toolbar.msn.com to get the toolbar
http://toolbar.msn.com ; click on Add-ins and search for the Anti-Phishing

Antiphishing would help to protect your family from online fraud

3. Microsoft has made a component to help protect a computer
that is used by many people.It prevents limited users from access to
^chosen by the admin user^ programs and files and also prevent them
from downloading files and other things
It is easy to use and can be configured to meet everybody's needs
It is called Share access tool

http://www.microsoft.com/windowsxp/s...ccess/faq.mspx

/example : A parent with Administrator rights can prevent a children
with limited account to use a chat program or download a new one /

4. When a child uses the internet ,
the computer should have an antivirus software ON + firewall always ON

http://www.pandasoftware.com/about/r...ldren_internet
Because of the campaign "Children and the Internet"
Panda Software offers 90 day free trial version of one of the best security
softwares
Panda Platininum Internet Security 2005

Please,go through the additional steps below.............

| PROTECT YOUR COMPUTER
AND THE INFORMATION STORED ON IT |

Microsoft suggest 3 +1 steps general steps to help protecting your
computer.Here they are plus some additional !

1. Firewall ON

It is very important to know that you REALLY SHOULD
use only one firewall (to prevent software conflict ) !!!

Firewall is a protective barrier between your PC and the outside world.
It protects you from hackers and other intruders from gaining
remote access to your PC and also from viruses and network worms (like
Sasser).
It also makes your PC invisiable for hacker softwares and
even if hackers find your PC it will block the attack.
Firewalls scans all your incoming (or outgoing) traffic and
immediately block it if it is unsolicated.

** Windows XP **

has integrated firewall -
Internet Connection Firewall (ICF) for SP1 and
Windows Firewall (WF) for SP2

Windows Firewall (for SP 2)
is full firewall ,suitable for all kind of users and connections.
Windows Firewall is designed especially for home users with
not very big computer literacy and that's why it works almost
automatically,asks rarely !

When using it,check the Exception list .
If you are home user and do not want to play network games,exchange files
over chat
or you are connected to internet via none/less secure server, you can check
" Don't allow exception "
This guarantees you maximum protection!

Start - Settings - Contol Panel - Windows Firewall .See its settings.

Users with no Service Pack or with SP 1 you should upgrade to SP 2
because ICF is partial firewall made for direct internet connection only

** Windows versions different from XP **

They do not have integrated firewall and they are not protected
from hackers and intruders,network viruses and etc.
They MUST use software firewall.So choose one firewall

You may get Zone Alarm personal (free) from :
http://www.zonelabs.com

2. Windows Updates ON

Windows Updates can protect your PC from different OS vulnerabilities and
security threats.

** Windows XP and ME **

| Critical updates |

Automatic Updates ON
Right click on My computer - Properties - Automatic Updates -
Download updates automatically but let me choose when to install them

** Different form XP and ME **

| Critical updates |

Automatic updates are not offered
Manually download critical updates
Start – Windows Update or http://windowsupdate.microsoft.com

** All Windows Versions **

| Optional updates |

Because of the fact Automatic updates downloads only critical updates (they
are the most important),
regularly visit http://windowsupdate.microsoft.com
and download some of the optional software and hardware updates available.

3. Virus Protection ON

Antivirus Software can protect you from viruses,worms,trojans and other
security threats

Always use the latest version of your program and update it at least every two days.
The more often you update it ,the higher protection for new threats you have.

Make sure it has real-time scanner which is enabled

Make sure all security settings are turned ON

(e.g. scanning All files,scanning compressed files,mail scanning,
disinfecting, heuristic scan,behaviour analyze
or detecting spyware,hacking tools, jokes and so on…..)

Use only 1 av software .More than one may cause your PC
problems because of the permanent protection ! ! !

Other : List with all Microsoft Anti-virus partners
http://www.microsoft.com/security/pa.../antivirus.asp

| PROTECT YOURSELF AND YOUR PRIVACY |

1. Spyware protection ON

Spybot Search & Destroy
http://www.safer-networking.org/microsoft.en.html

Ad-Aware SE Personal
http://www.lavasoftusa.com/software/adaware

Microsoft Antispyware
http://www.microsoft.com/athome/secu...s/default.mspx

These 3 programs(all free) are the most famous
in the world and ,of course,are the best.
Using two of them guarantees you very ,very good protection !

Microsoft Antispyware is the only one from these above that has
real-time protection,which is very important for dealing with spy junk

2. Manage your Internet Settings

Start-Settings-Contol Panel-Internet Options

| On the General tab |
Delete all temporary internet files,cookies,history ( often do this)

| On the Security tab |
Make sure the Internet level is Medium.Check other levels

| On the Privacy tab |
Make sure the level is Medium High.

| On the Content tab |
Goto Auto complete
Delete(clear) forms and passwords and check the settings

3. Use a pop-up blocker

Internet Explorer 6 with XP SP 2 has integrated pop-up blocker

However ,if you are not XP SP 2 user ,or you are without IE 6
get the Free MSN Tool Bar that has pop-up protection
http://toolbar.msn.com

3.1 MSN toolbar
This toolbar become more useful everyday
It has either pop-up blocker and also Anti-Phising filter
Recently Microsoft had established this Anti-phishing filter
as an add-in for the Toolbar
http://toolbar.msn.com to get the toolbar
http://toolbar.msn.com ; click on Add-ins and search for the Anti-Phishing

4. Other

4.1
( Depending on your mail program - this below is for Outlook Express )
Open Outlook Express
Tools - Options - Security
Make sure you have checked these:
` Warn me when...
` Do not allow...

4.2
Create free web-based mail
Lots of free web-based mail accounts exist.
You may create one in Hotmail , Yahoo , Gmail or Mail.RU

They are all for free with a lot of space and intergrated SPAM and Virus
protection
Yahoo.co.uk and Mail.ru offer free POP 3 / SMTP /HTML access
so you may use them with Outlook Express

4.3
Think first , then click !!!

Nothing can protect the computer from its user.
Even though you could have firewall,av software,
antispyware software and all updates downloaded,
you are not protected 100 %.NOTHING guarantees you 100 % protection.
So if you don't know what exactly to do and when to do it,you'll probably
fall a victim
of a virus , spyware or hacker.
You can find it ridiculous,but it is true! :-)

BE CAREFUL which sites you visit
BE EXTREMELY CAREFUL what you install,especially free or shareware software.
ALWAYS check everything you download from internet with AV and AS software.

4.4
Be aware of SPAM messages and especially PHISHING !!!
Spam messages are unsolicated mail.You really do not want them !
In most cases SPAM is just annoying,however PHISHING is a type of spam that
is
is really dangerous.Someone unknown sends you a messages,which is
trying to get personal information,such as bank account number
and passwords ! That's why :

NEVER give your email and/or passwords to strangers.
Don't post your mail or passwords in forums and chats.
NEVER read email messages from people you don't know. Just delete
them!!!
NEVER answer to strangers or even open the attachments,if any !!!
Delete the mail !
NEVER follow links in email from stranger and in mail that you
doubt and do not trust !

For more info about SPAM / Phishing visit
http://www.microsoft.com/athome/security ; - Email section

4.5
Regularly :
Run Disc clean-up (with all checked)
Start - Programs - Accessories - System Tools - Disc Clean-up

Check all hard drives for errors
Back-up all your information (at least montly)
Defragment all hard drives
Scan all your computer with antivirus and antispyware software
(should be twice a week)

--- Useful pages ---

http://www.microsoft.com/athome/secu...s/default.mspx
different kinds of free or trial security software.

http://www.pandasoftware.com/about/r...ldren_internet
Because of the campaign "Children and the Internet"
Panda Software offers 90 day free trial version of one of the best security
software
Panda Platininum Internet Security 2005 awarded with many prizes

http://www.pandasoftware.com/protected/tips.htm ;
useful tips for protecting computers

http://www.pandasoftware.com/product..._principal.htm
Panda Software free Active Scan,where you can check your
PC for ALL TYPES of security threats and clean viruses and worms

http://housecall.trendmicro.com
Trend-Micro free online scanner HouseCall where you can scan for
Viruses and Spywares and clean them. CWShredder is also available here

http://www.kaspersky.com/virusscanner
Kaspersky free online scanner
and checker for suspicious files.If you have issues with suspicious
file,here is the right place!

http://www.f-prot.com/virusinfo/submission_form.html
Send F-prot AV suspicious files for fast analyze and and it is all for FREE

http://www.microsoft.com/malwareremove
Microsoft Windows Malware Removal Tool

http://www.microsoft.com/windowsxp/u...nfectedpc.mspx
Microsoft MVP Charlie Russel's article about Dealing with malware
Really good and detailed

http://support.microsoft.com
Free Microsoft support and suggestions (for genuie clients)

Now ,when you have cleaned your computer,you need to think about your
security!
Microsoft
suggests 3 + 1 general steps how to protect
your PC and the infomation stored on it,
your privacy and your family
1.Use an internet firewall
2.Enable Automatic Updates for your PC
3.Use an antivirus software
4.Use antispyware software

Goto http://www.microsoft.com/athome/security and learn more
Check the Security Essentials for your OS and also have a look at all
sections!

Thanks very much !!!
Panda_man

" Let's beat malware black and blue "
" No new epidemic of all kind of malware - Panda TruPrevent "




http://www.linuxworld.com/story/47536.htm

Linux Opinion: An Open Letter to a Digital World
"The Windows platform is not just insecure - it's patently,
blatantly, and unashamedly insecure by design"
December 18, 2004
Summary
As a Linux desktop user himself, system administrator Chris
Spencer did not relish having to clean up his wife's
infected Windows PC after it had become compromised. By the
time he'd solved the immediate problem, Spencer had become
so fed up with spyware, trojans, viruses, and spam, that he
decided it was time to write a letter to the world. It's a
simple message: it's time to switch from Windows to Linux.
"The letter serves as a guide," Spencer explains, "taking
you through some of the history of Microsoft right up to
this present day."

To Anyone Who Will Listen,
Recently I was reading an article from Wired magazine
talking about the Windows spyware problem [1]. It was
unbelievable to me that people would choose to use programs
that they know make all their personal information
available to companies. It turns out that 80% of Windows
users suffer from spyware [2]. I read many articles like
these but always thought that these people have problems
just because they aren't careful. Maybe they don't run
anti-virus, they don't use a firewall, or they browse seedy
sites and download applications for seedy activities. It
turns out though that is not the case.

My wife discovered that her computer had been infected by
spyware and trojans despite the anti-virus, regular Windows
updates, having the good sense not to open attachments,
using a firewall, and avoiding any type of seedy activities
online. As best we can tell someone exploited IE
transparently while she searched for medical information to
help our nephew.

The clean up from these types of infections is great fun. I
spent not less than 5 hours running about every spyware
prevention program known to man. Each one searching for
those pesky files and registry settings. The worst thing of
all was that, once I cleared them off the disk, simply
starting Internet Explorer would reinfect the whole system.
Seriously, it was great fun and I did, eventually, have the
satisfaction of beating the problem. That's right - a
system administrator for 10 years with a degree in computer
science and a RHCE CAN clean up a single spyware infection
in 5 hours.

I hope you see what I am really saying here. How on this
earth are people that aren't trained in Information
Technology going to do it? As a Linux desktop user, I had
never been exposed to this type of problem. Having now
battled with spyware, I am finally motivated to speak up
and say something to the world. I want to get a single
message across:

It's time for anyone running a Windows PC to switch to Linux.

You see, the Windows platform is not just insecure - it's
patently, blatantly, and unashamedly insecure by design and
for all the lip service to security it's really not going
to get better, ever. To make matters worse, it's more
expensive and gives you fewer necessary applications right
out of the box than Linux. Everyone, even Microsoft, knows
this - they are just too afraid to say it. The tide is
coming in. Nothing on this planet can stop it.

Whew. I said it. I am so happy to get that off my chest,
however, for me to stop here would be unfair. I haven't
really proved it to you. So if you will entertain me a bit
longer here is the rest of the story.

Microsoft started conducting a "Get the Facts" [3]
marketing campaign against Linux. This signaled that they
have correctly assessed that their competition is Linux and
that they need to fight it with all they have. It even made
it into their 10K filing. [4] It's really an interesting
read to note that Microsoft sees Linux as a major threat
It's a big enough threat to their monopoly that they say:

"The Linux open source operating system, which is also
derived from Unix and is available without payment under a
General Public License, has gained increasing acceptance as
its feature set increasingly resembles the distinct and
innovative features of Windows and as competitive pressures
on personal computer OEMs to reduce costs continue to
increase."
If Microsoft thinks this then that alone is more than
enough reason to give a fair look at Linux. Of course it's
just as likely that they are preparing the lawsuits to
attack Linux because it is a real competitor. I am not sure
which distinct and innovative features they are
referencing. Perhaps it was the whole GUI concept that
Apple sued them for stealing from them. Perhaps it was the
Microsoft Office-like functionality that Open Office has
that Microsoft took from Word Perfect. It's hard to tell
and it gets me off topic to delve into it.

Alright, let's talk about the "Get the Facts" marketing
campaign. What happened is that Microsoft and vendors that
make money on Microsoft products have all come together to
tell us that we us why we should use their products. As a
consumer and something of a student of history, I always
question people that are highly motivated to protect their
jobs and money. Did big tobacco say their products were
safe long after they knew it wasn't true? Might Microsoft
be inclined to say that their products provide better total
cost of ownership (TCO) and security than another product
despite knowing it wasn't true?

It turns out they have done something strikingly similar
before. [5] When IBM OS/2 had just taken off and become
"the best selling retail software product in America" then
"sources close to Microsoft" leaked word to a columnist for
the UK edition of PC Magazine, who dutifully reported both
the rumor and source." - Computerworld, March 20, 1995,
page 118. From there it was all downhill for IBM. Despite
everything indicating that OS/2 was doing great the press
just kept printing the Microsoft party line. In the almost
10 years since that happened, have things changed? Are they
kindler, gentler, and friendlier to work with or do they
still spin, bully, and use talking heads?

Carrying on in their history we see that, empowered by
their victory over IBM, just 4 years ago Microsoft was
ordered to be split in two by Judge Thomas Penfield Jackson
because they were convicted of abusing their monopoly
market position. Then 3 years ago Judge Colleen
Kollar-Kotelly reversed the decision to split them and a
much lighter penalty was imposed. Unhappy with the results
the EU took up the case and just this year Microsoft was
convicted in the EU. Since then Microsoft has paid billions
of dollars to the companies that were aligned against them.
One by one settling the differences. Most of the companies
had little choice but to accept the money they were
offered. Because they have been so badly beat. Now they
stand with billions of dollars in the bank and a patent
portfolio that is rapidly expanding.

I don't know about you but when a convicted monopolist that
has been shown to use those monopoly powers against their
competitors says that Linux is a competitor but that it's
not as secure or cost-effective, well then I take note.
Because I know there is a good chance that a half truth was
spoken.

Maybe Linux is shoddy code just hacked together by a
college student. However, according to the four-year
analysis by five Stanford researchers [6] Linux contains
only "0.17 bugs per 1,000 lines of code" and most all of
those bugs have been fixed. Given that an earlier study
from Reasoning, Inc [7] had already shown that the Linux
TCP/IP stack had a 0.013 per 1000 lines of code defect rate
back in 2001, it is hardly astonishing that the entire
Kernel is also relatively low in defects compared to your
average commercial software application To put that in
perspective the average code seems to have anywhere from 2
to 30 bugs per 1000 lines of code. That makes the Linux
kernel between 11 times and 176 times better than your
average product. So it's certainly not shoddy software by
any stretch of the imagination.

Considering that many Linux distributions are free, it is
hard to believe that it would be more expensive than
Microsoft where a simple upgrade costs $100 and their
Office application costs hundreds more. Call me crazy but I
am having a hard time finding any truth in the "facts" as
reported by Microsoft. However, Microsoft studies the TCO
to show that other factors make Linux more expensive. Yet,
the studies that I have read seem to make crazy assumptions
like saying it takes more money to train users to push a
button on Linux than it does to push a button on Windows.
They also tend to ignore the costs associated with viruses,
spyware, and trojans that prompted me to write this.
Perhaps most unfortunately for Microsoft they also ignore
that wildly varying labor costs directly affect TCO. [8]
That means it wouldn't just be a poor decision it would be
a completely moronic decision for a government to use the
Windows platform in the third world if it wasn't absolutely
necessary. To be honest, for a long time I have wanted to
see a case study that took these types of issues into
account. I was, for this reason greatly disappointed, when
I heard about a study from Cybersource [9] that ignored
these things but still found Linux, even Red Hat Enterprise
Linux, to be at least 19% less expensive. So much for
Windows being better value, they can't even win when the
whole thing is tipped in their favor.

Maybe I missed something? Maybe Microsoft just happens to
be truly better at security than Linux? For this I had to
get dirty and dig. On the surface it did seem like Windows
had fewer security issues. Looking at Seconia, a security
research company, I discovered Windows 2000 Server has had
only 76 Advisories in all of 2003 and 2004. [10] Red Hat
Enterprise Linux 3 on the other hand has 101 Advisories
[11] and it wasn't launched until November and looking at
Red Hat Enterprise Linux 2.1 I found a whopping 145
vulnerabilities. [12] That looks pretty bad, right?

I am sure that is what Microsoft would like us to think. If
we would just ignore the elephants in the closet then we
would come to their happy conclusion. I'm not going to do
that though.

Microsoft Windows is but one component in a much larger
Windows platform. What good is the operating system without
remembering productivity software, anti-virus software,
instant messengers, media players, software to burn CD and
DVDs, and the list goes on and on? These are all things
that Red Hat and every other Linux distribution includes as
part of the package. Usually they go so far as to include
multiple applications for each function. It would be,
therefore, completely unfair if we didn't compare a
comparably equipped Windows platform to a comparable Linux
platform. How do you add it up though? Whose products do
you pick and whose products do you ignore? It's a horrible
can of worms. I tried to do it. To build the comprehensive
list so that we could compare a Microsoft Windows that's
fully equipped like a Linux distribution and I was able to
exceed the number of advisories. I just felt dirty doing it
and in the process of doing it. Besides, I came to the
realization that the bug count isn't what really mattered.

What really matters is that the bugs are getting fixed so
you aren't online without protection and that the updates
were easy to track and install. Both of which Microsoft is
in serious trouble with.

With Linux all of the updates for all of the different
types of applications come through a single path and in an
automated way. It is a process very much like the Windows
Update service. The key here is that one update service
covers all of the products. On the Windows platform you can
get the Windows updates this way but what about all of the
third party applications we needed to have the same
functionality as Linux? Each of those need to be searched
for or are hidden inside the application themselves.

In my research I found one particularly nasty Microsoft bug
that really emphasizes this point. I am talking about the
GDI+ buffer overflow with JPEG processing [13]. They put
out a security bulletin and they released a patch for each
of their affected products but they never identified who
put the SDK library in their products and each of those
products linked to it individually. Not only did this mean
users had to be experts that researched the update on their
own, but they also had to manually install it in each
location. You have to admit, that sure isn't as nice as the
centralized updating that Linux has. It seems more like a
tidal wave to me.

Then there are the issues related to actually fixing the
bugs that are known. Again, Secunia makes it really easy to
see. Of the 76 advisories Microsoft 2000 Sever still had a
whopping 20% outstanding and one of them was rated "Highly
Critical". Red Hat Enterprise Linux had fewer than 1%
outstanding and it was rated only "Moderately Critical". So
much for fewer security updates meaning you are more secure
and let's not even talk about the Internet Explorer Web
browser. Because it is so insecure that the United States
government, through the Computer Emergency Readiness Team,
had to issue a warning to use any browser besides IE. [14]
Yet, to use Windows Update you have to use IE. It's just
not fair.

Then there is the issue of design. Linux was designed to be
in a hostile Internet centric world. As people were
programming it they knew this and it no doubt played a role
in the designs of their products. With Linux you will find
that firewalls are enabled by default, users rarely login
as administrators, server applications run as users that
have limited rights, etc. In Windows these obvious things
were an afterthought. Finally put into Windows XP with the
creation of SP2, well mostly. I think it's because of the
mindset that Windows is for end users on either private
networks or no network at all that Microsoft has been hit
so hard by security issues. It's of course equally possible
that the issue is entirely different. Maybe they don't fix
the security holes because it's considered a feature. I
know they said as much about the Windows Messenger Service
[15] even though it was being actively used to send banner
advertisements to desktops around the world.

Perhaps Microsoft is finding that the standard software
wisdom about bugs [16] being less expensive to fix before a
product ships is true because after several years of having
security as the number one focus they are as plagued or
more plagued by security issues than ever before. Maybe
pouring money on the problem won't fix it? I mean come on
Even before Windows XP [17] - we knew these things but it
still shipped with the stupid default settings and we STILL
have 20% of their advisories unfixed. How can anyone feel
safe running on a Microsoft platform?

Linux provides a better paradigm. It costs less, it is more
secure, and perhaps most importantly of all it isn't
controlled by a single vendor. While Red Hat is the largest
distributer of Linux and does provide a comprehensive
support system and legal protections for their customers,
they aren't alone. Major companies like IBM, HP, and Novell
are all deeply involved with Linux but none of them are in
control of it.

Because of Linux, the future of computing is commodity. By
the year 2000, Linux already represented billions of
dollars worth of development effort [18] and it's owned
collectively by each one of us. The savings will follow and
you can count on getting what you pay for or there will be
someone else that is there for you on the terms that you
want. The tide has turned and Microsoft is going to get
wet. From my perspective they already are all washed up.

It's all an issue of attitude. Linux follows the share and
share alike [19] mindset where as Microsoft seems to have
the greedy mindset of it's all mine and I want to get paid
for it now [20]. Well Bill, Steve, and talking parrots,
that's not very nice. As I have shown there are good
reasons for using Linux as the better alternative to
Windows. Give my friends at Red Hat a call. I am sure they
could comp. you a copy. Anyway.....

Like I said: It's time for anyone running a Windows PC to
switch to Linux.

I really appreciate you taking the time to read my letter
and I hope that it gets you motivated to make the switch
or, if you already have, that it just makes you feel all
warm and fuzzy inside.

Sincerely,

Chris Spencer
chris at digitalfreedoms dot org