Wednesday, November 20, 2013

From concept to reality in 6 weeks - part 4

This morning I need to check on a couple of things. First thing I need to check on progress being made and the time left. It may seem that 6 weeks is a lot of time but that is essentially 30 working days. I have finished 3 days so I have 27 days left. Not enough time but I have to make due with what I have.

  • Day 1 - setup laptop
  • Day 2 - get development environment working
  • Day 3 - get Bing Maps working
Speaking of Bing Maps, I need to check on my usage after one day of testing maps. I ran a report on the Bing Maps Portal and turns out I must be getting free usage as it said "No Data to Report", so I guess that is a good thing. Maybe it was a bargain and I get the first day free!

I have a choice to make this morning as I could explore Bing Maps further to figure out why I could only get one of the GPX files to work as all of the others failed miserably by crashing the test app. That would be good to know and if I could get multiple files to work then I could load them all at the same time and see if Bing Maps is still responsive with thousands of poly-lines and points on the map at the same time. This would simulate the actual case I will encounter soon. For now I need to leave that for another day as today I must get the real geographic location data from the server as that is still a big unknown. A lot of things are unknown at this time but at least I have a sense for what needs to be done now. Last week I explored the Windows 8 Metro UI components and after using several apps, I see how the app should work.

Before going further I need to set up SkyDrive on my Mac so in the future I can find files on my Mac, then save them to my SkyDrive and see them on my Windows 8 laptop as that will save me time. I noticed when I went to the SkyDrive site yesterday that a message at the bottom of the window offered a free app to help me do just this. This should be interesting as I already have DropBox, Google Drive and now I get a Microsoft way of doing the same thing. The good news is that I am predicting a quick install and no reboot required as opposed to what I have been seeing the last 3 days. Just as I expected. What is so strange about this for me is that Microsoft can create an easy install and setup on a Mac and yet make some things so painful on their own computers. After just a couple of minutes I see the blue clouds in my Dock and open the drive and I see my GPX files I was working on yesterday. Now I can search for example code on my Mac using my nice 27" thunderbolt display and store it in the SkyDrive.

I immediately go to the Windows 8.1 app samples and start looking for my perfect example of accessing a server to retrieve JSONP. I see so many hopeful examples so I go back to my laptop into the folder where I downloaded all of the Windows 8.1 samples. It is so tempting to open the DirectX and Direct3D apps as the names look so interesting and I am so curious, but I resist the temptation and skip over them (there are tons of them so as I scroll thru them I have to constantly ignore so many fun things), but then I see tons of HTML and JavaScript examples which I also must resist and keep going until I find the Json Sample. After double clicking on the project file and clicking on F7 to build the project, then F5 to run the project in the debugger I see a window to enter JSON at the top and the bottom has the parsed results and I can do the other way as well. That is pretty nice. Now I have to look at the code to see how it all works... Actually it is easier to read on the Thunderbolt display as I can browse the source code on line for the JSON example.

I accidentally hit the Windows key on my laptop and I just cannot figure out how to get back to the JSON app. This is not the first time this has happened to me. I right click on the menu bar and see the app running in the Task Manager and I can select the app in the list and it comes back up on the screen. There must be a way to cycle thru apps. Right, now I remember it is Alt-Tab on Windows. That is one annoying problem solved. I should have recalled that one, but Windows 8 is so different from Windows/XP that I used for many years that I just don't assume things I used to know still work.

Time to take a quick C# refresher as the first thing I encountered that I don't remember what it means is "jsonObject^ jsonObject" which I assume means a pointer, but I have to check on the Wikipedia summary article for C#. At least C# supports a goto statement so that is an advancement back to when I first saw a computer 35 years ago! Similar to Objective-C, you can use "C" in C# so I get structs and enums. Good news, I don't have to worry about adding a "@" as in Objective-C to create a Objective-C string so it is different from a "C" string, so C# is less confusing in that regard for strings. I also don't have to force boxing as in Objective-C by adding "@" to convert a int to an Integer, so C# has already helped me twice as it auto boxes. Unfortunately the Wikipedia article did not mention the syntax I was looking for, so now I have to find the explanation on the official C# page. It turns out that it is harder to find that I expected. After looking up pointers in C# I finally realized I was looking at C++ code. But it did not hit me until I looked at the actual code I was using in VSE and saw it was different from what I was looking on on the web site. I missed the tabs on the left hand side, which defaults to C++, so I switched it to C# and now I feel better about what I am seeing. It is amazing how much easier it is to read C# and C++, but then again maybe it is because I have never done C++.

Then I move onto to understanding the XAML file. Unfortunately for the example code I am looking at, the Metro UI elements are dynamically filled in at run-time so the visual C# editor does not help me understand what is going on. I don't miss the days of XML so that it going backwards for me. I am going to grin and bear it as XAML is THE way to do visual layout in C#. It reminds of the in-house XML based tool I used a couple of years ago to generate iOS iPad/iPhone screens which was built using XAML principles for grid layout and relative sizes. It was a precursor to the XML that Apple created which is behind the iOS storyboards. The big difference is that I never need to know or see the XML for iOS storyboards.

Now this is something I guess I never knew about Windows. To bring up the global find dialog in VSE, you have to type the shortcut of Ctrl-Shift-F or so the EDIT menu says. But I have to actually type Shift-Ctrl-F. I guess I just never realized or cared to know that the sequence of keys clicked matters. I really still believe it so I have to try it several times by clicking on different places in VSE to select the different views. Sure enough only Shift-Ctrl-F ever works. I still think this has to be a bug in VSE or a mode problem that I need something selected or not selected for the find to work. Anyway, I finally found how the "S1_ParseAndStringify" XAML file is loaded as that is in the partial class "Constants.cs" - that was odd and hard to follow how the XAML file was loaded in the "MainPage.xaml" but now the mystery was solve by using the global find dialog. I think that is enough learning about C# to get me going.

I need to get back to figuring out to transfer data from a remote server. Good news, I found an example where I can enter my remote server URL and get the data. That sounds like a perfect place to start so I load the Background Transfer example in VSE. Now I am losing the little of confidence in VSE that I had. In the example, there was a URL that I wanted to change to the secure remote server URL. I kept trying to find ways of editing the Visual C# view and then I tried editing the XAML file but nothing happened. VSE would not let me edit either one. I then searched the web to find an explanation of how to do this simple task and found an explanation of how to edit XAML. That just does not seem right that I have to read how to edit a file. Turns out you have to launch another tool called Expression Blend. This is the kind of product fragmentation that I thought was way too over kill when I first used Visual Studio over 8 years ago. Apparently that was not fixed and has gotten worse over time. Maybe my Visual Studio Professional will fix everything for me. One more slip like that and I am going for broke and start using Pro! I save the changes in Expression Blend and then close it and go back to VSE. I see a message telling me the file I am looking at was changed and it asked me if I want to reload the file with the changes. Of course I say yes. Then I see the visual part of the XAML file did not change. I did not think about it and hit the F7 key to build the project. Then magically the view changed to match the XAML file I saw had my changes. I looked at the file in VSE and see a lock in the tab and hovering over the icon I see the full path to the file and "(Read Only)", so that explains everything. Then guess what? It worked like a charm when I ran it, wait I cannot use that word as it means something else in Windows 8. Now all I have to do is find the file on the file system somewhere. I quickly go to Windows File Explorer hoping that it can help me and search for "DownloadedFile.txt" on "This PC" and finally near the end of the search it found the file for me! It was located in "C:\Users\Rick\Pictures". When I looked at the code behind I thought that is where it would be as I saw this line:

destinationFile = await KnownFolders.PicturesLibrary.CreateFileAsync( 
                    destination, CreationCollisionOption.GenerateUniqueName);
I doubled clicked on the file in Windows File Explorer and the file was loaded into Notepad and I saw the correct contents. Now we are in business as I know how to connect to a remote RESTful service and get my data.

I want to check on one last tricky part that is required for the final prototype, since I want to explore all of the most difficult parts of the app at the very beginning. After geographic maps and getting data from a secure remote server, I need a range slider which I don't think is part of the standard Metro UI elements. I either need to make sure it does not exist already or be able to find one publicly available that I can easily use. When search for "Windows 8 Metro UI" in Google, the first match is quite amusing as it explains how to get rid of Metro on Windows 8. The second link I clicked on was CSS to convert Twitter Bootstrap to look like Windows 8 Metro. Once I added "MSDN" to the start of that search then I started finding interesting things, like the Font-Awesome equivalent for Windows 8 Metro called Seqoe UI Symbol font. I will need that later one for sure. That reminds me I need a way to render SVG files on the map so I need to check on that today also. I found an example that draws a path at a GPS point, so that will work just fine - this example uses Silverlight but should be easy to replicate in C# as I just wanted to make sure it was possible.

I have searched and researched and found no such slider component. I then recalled using Infragistics many years ago and low and behold they are still in business; however, they did not have the dual range slider component I was looking for. I then reverted to using StackOverflow and found a page that listed useful 3rd party components for .NET development. Component Factory was WindowsForms so not what I need to use at all. Telerik has some nice looking components but not what I needed. ComponentOne has tons of great looking components, but still not the one I needed.
Peter Blum's site had many components but nothing that looked worthwhile comparing to the others already mentioned. I am definitely seeing a trend as viblend has several of the components I had seen previously with the Calendar being the most common shared one among them all. The last one was DevExpress and it sure was proud of all of their awards and they listed them as huge images at the top of their page. Unfortunately they also brag about their $499.99 price tag and that is pretty scary to me. I like their list of components and they have a Spark Range Selector that matches what I need. What I really need that I am missing is a Date Picker and Range Slider. Maybe I am not searching for the right text. If I search in Google for "Spark Range Selector" then I find tons of Adobe Flex 4 Spark components that match what I want. That brings back memories from 5 years ago when I wrote Flex components for an app and now I remember that "spark" was the name for the version 4 UI components Adobe delivered. Not going to help me now. I go back to Ms. Google and search for "windows 8 range selector" and find that Telerik has the exact one I need as well. My sticker shock is increasing as their Windows 8 .NET UI Control Suite is $999. Hey, if I want all of their components it would normally cost $7,739 and I can get them all for the bargain price of $1,999. I think I need to find another solution quickly. I found a free one I am going to try that I found using Google called Perpetuum Software as they have the dual range slider I need. I keep searching and found what $399 would buy me from Syncfusion. I am going to give up and try the Perpetuum components since they are free without support. Now I am loosing confidence since I could not down their components on Windows as the sign up form never appeared! I go to my Mac and access the same page in Safari and it works. I downloaded the license and the standard version of their components and put them on my SkyDrive. How odd is that? If I can get the Range Slider then I will put up with such foolishness. My folder never showed up on Windows 8, so I just moved the files out into the main Documents folder and they still up. I guess I was not patient enough as they finally showed up after I had already moved the files out of the Downloads folder. I extracted their files and when I tried to load the package in VSE I got an error so time to give up for the day. I tried to chat with Perpetuum but it said the chat service was not available so I sent them an email. Maybe tomorrow I will come to work and everything will be fully explained in the reply email - at least I can hope but I seriously doubt that will happen.

Tuesday, November 19, 2013

From concept to reality in 6 weeks - part 3

Last night I went by BestBuy to buy an HDMI cable so I can test my apps on the 1080p TV at work to simulate the actual device that the app will have to run on that I am building. Those cables are common and come in all lengths and quality of connectors. I choose the 8 foot rocket fish brand since it was the cheapest. I also asked if there was any non-Apple computer sold at BestBuy that could drive a Cinema or Thunderbolt display. The response was shocking to me Apple tuned ears. The sales person took me over to the Windows Surface 2 and showed me the mini display port. This morning I had to look that up to see how Microsoft marketed it in the on-line brochure.

That was a side note as today's task is to get a Windows 8 app built. This totally acceptable since it is early in the project and this change of direction is to be expected and embraced. Now if that happens a couple of weeks before the product release then I will not be nearly as happy. It is good news for me since I looked at the Visual Studio Express device menu and the choices are very limited. I see 4 different devices in the emulator none of which are close to 1080p. The choices are "WVGA 512MB", "WVGA", "WXGA", and "720p". I am happy to move to building native Windows 8 apps, so I must find some example code for maps as my first working code in VSE for today.

Since I already have VSE installed and working, I just need a different SDK loaded on my laptop. I also found another useful page on the MSDN portal. In my initial exploration, I seem to always find two pages that describe the same thing in two different ways on Microsoft web sites. In this case, the later page had the link to the latest Windows 8 SDK dated 17 October, 2013. As before the initial download was very small and the actual SDK is 1.6 GB in size, so I quickly connected an ethernet cable in hopes it would make this go a bit faster.

Then I find out that they are many Visual Studio Express products. Thank you Microsoft for helping me easily develop the same product on multiple platforms. I must now download Visual Studio Express for Windows as I have Visual Studio Express for Windows Phone working on my laptop. This is definitely not what I expected. When I click on the correct download link, somehow the form filled in my email address and nothing else. I have to retype my "Full name", select my "Country/Region". I just entered this stuff two days ago and already it has forgotten me. Maybe if I paid for the Ultimate version then it would remember me! Wait they have a 90 day free trial for all of their products and I cannot find the cost anywhere on the web site. I am supposed to be done in 6 weeks so I could actually use any of them, if only I could figure out what is different from Visual Studio Ultimate, Premium, Professional or Test Professional. Only Visual Studio Express has the distinction of a Web, Windows, and Windows Desktop versions so maybe they would help me one day. I did learn that Microsoft also has a special program called BizSpark which is for startups to get 3 years free software and support. As I open the accordions on the Visual Studio page as quickly see from the first paragraph what each offers and the Professional version allows me to create all different apps in a single IDE. I am going to keep going with Express for now until I see a need to get a more complex product as I am sure the Professional version will have all kinds of things I don't need and will not use.

When I download the VDE for Windows, this time I went out on a limb and signed up for a personal account (https://attentive2design.visualstudio.com). As the download was working, a form popped up on my screen asking for a project name, description and let me connect to either "Team Foundation Version Control" or "Git". Wow, that is a really hard choice. I can use Git and the GitHub client I installed on the laptop of figure yet another Microsoft tool for version control, that probably easily integrates into Visual Studio. So Git it is. Then I get another important choice for a "Process template", none of which are really appealing to me: "Microsoft Visual Studio Scrum 2013", "MSF for Agile Software Development 2013", or "MSF for CMMI Process Improvement 2013". I can definitely say the last one is scary but maybe because I have no clue what it means. I could look it up but I have zero interest in knowing. I have done scrum before but not I do Agile so I will pick that just for fun. Now I see what it is doing. It is creating a Visual Studio Online account where I can share task progress with other people - it is another Kanban board with management tools. I am going to skip that and leave that for another day for now.

Wait, the VSE download finished so I have to launch it and then answer a bunch of questions. Today is my lucky day as I get to into my Microsoft account and password twice in two sequential screens. I thought I was logging in once and then up pops a second login screen to get my developer license. The good news is that it showed me my developer license will expire on 18 December, 2013. Probably the day I am trying to get serious work done and that will be the day I switch to using Professional.

Now I need to find some Windows 8 example code include some maps. Now things have really changed as native Windows 8.1 apps use Bing Maps instead of the phone apps that use Nokia HERE.com maps. I guess I now get to switch to Bing Maps, well that is a bad description as I hardly knew anything about the Nokia maps except what I read in my downtime when software was loading on my laptop. Using the Bing Maps API is only temporary until I get the working Windows version from our mapping partner. After the download and installer completed, a message popped that I had to restart VSE. I then noticed that the different versions of VSE have the same icon but different colors. The VSE for Phone is read and the VSE for Windows 8 is blue. While relaunching I read the Bing Maps download page and it order to use it I have to get a license key. Again I can get a 90 free trial, which is more than enough for what I need. If I am still using Bing Maps in 90 days then I will probably be fired as it will be a complete failure on my part. When reading the license page, I see I only get 10,000 billable transactions, so I have to go read about that. After all of that I want to see if I can use Nokia HERE.com maps for Windows 8.1 apps. I went ahead and signed up for a Nokia developer account and then logged into that account. When I clicked on the link within the developer portal to get an evaluation key, then I was had to click on a link in an email to activate my account. Once I signed in then I had to go back to the main developer site as I was stuck on a page with no menus at all - that clearly is not the way to win partners. On the first screen I see I am now hosed as the choices under "Application platform" do not include Windows, but only Windows Phone. Plus the "Solution" choices don't match I need to do either. OK, time to go back to Bing maps...

Once I logged into my Microsoft account, and answered several questions in many forms I was logged into the Bing Maps Account Center. From past experience I knew I need a map key, so I clicked on "Create of view keys". In the text above the form I see a curious link labeled "TOU", and when I click on it then I see just about the worse fine print text you can imagine where I have to read a terms of use document to understand what is going on - for the sack of time I give up as that is the smart thing to do. I am definitely confused now as I see a text box labeled "Application URL". Am I supposed to make that up? I am just happy I now have a key so I should be able to create a simple Windows 8 app with a Bing map. I had to quickly read a bit more before getting started on how to use the Bing maps first. I have an example to work thru to make sure the Bing maps are setup correctly and working as expected. My first major road block of the day - I installed "Bing Maps SDK for Windows 8.1 Store apps", then restarted VSE for Windows and do not see the Bing Maps reference to add it to my VSE project. Bummer. I am going to try a different tactic by downloading all of the Bing Map samples. The download was easy and then I extracted all of the files and when I tried to open one of the project files, then bad error messages started appearing as these examples were built for VSE for Windows 8 and not 8.1. I tried to following the directions to retarget the solution but that did not work. I tried to build the app and nothing I tried helped as VSE kept fussing about the missing Bing reference. It looked like the name was incorrect as it was referring to an older version of Bing Maps. I deleted the reference from the project along with the missing Visual Studio C++ Runtime package. I then had to look up how to add a reference to my project and followed the directions by right clicking on "References" in the "Solution Explorer" and clicking on "Add Reference...". On the left hand side, I opened "Windows" and selected "Extensions" and clicked on "Bing Maps..." entry but that did nothing. Then I went back in and realized the first column was a checkbox that I had to select. Then clicking on OK actually did something and automatically added the matching C++ Runtime library. My project built and when I tried to run it, I got a bunch of Watch windows up and when I closed all of them, I saw the message in the status bar saying "This item does not support previewing". Now I have to figure out how to run a Windows 8.1 app as it just did not work like I wanted it to - apparently wishful thinking does not help when working with VSE.

Just when I get going I have to read some articles and when I go back to my laptop is has become very dim and nothing I do changes the brightness. At first I went Settings and the brightness is already set to 100%. I then have to figure out where the automatic brightness is being set. I search for "display settings" hoping that will be my ticket to brighter days. It was not under "Display" in the "PC and devices" screen that appeared. I thought of where I might find this on my Mac and I immediately went to "Power and sleep" and it was the first item under "Brightness" named "Adjust my screen brightness automatically". Problem solved.

Back to my map issues. I accidentally tried to repair my VSE and so I am waiting yet again for the VSE install process to complete. I realized Windows 8 is new but somethings just never change - waiting for installers and reboots is a way of life on Windows not matter how new it looks like on the surface - pun intended. Now I am beginning to think I need Visual Studio Professional just when my computer started rebooting. I read up on IE 11 and they found just about the most geeky name for what every other browser called the Web Inspector - Microsoft picked the name of F12 Tools. Another unfortunate thing happens every time my laptop is rebooted is that the HDMI display does not work. I have to go into the menu and automatically detect the display. Now I have my map display correctly on my laptop. I thought I could just drag my VSE to the 1080p TV and then restart the app and it would display on that device. Again, I am just taking too much for granted. Now I have to figure out how to run the app on the TV. I found the article and it I learned I have to use Windows logo key + Shift + Right Arrow to move the app to another monitor. The good news is that I have a Bing Map displayed on the 1080p TV and it looks pretty good. I zoomed into a traffic problem in Carrollton, WI and turned on the Aerial view and the stop light turned on. The road problem is dashed red and white lines on the road so they jump out when zooming around on the map. Then I had to look up how to stop an app, as it is easy to disconnect the app from the VSE debugger or to stop debugging, but closing a full screen app with no windows controls gets interesting. So interesting in fact that Microsoft wrote an article on how to do it - you drag the app to the bottom of the screen!

A little about Bing Maps - the first example I tried was the Pixel to Location Sample, which each tap and hold results in a point being added to the map. It just was not intuitive to tap and hold as that is not an obvious behavior for me. Now I must be in a roll as I have 4 Bing Map examples running. Each one has the same problem of being an older version of VSE so each must be re-targeted, then I have to delete the 2 missing libraries and then add Bing Map back in. In all cases I have to use my Bing Maps key by editing the MainPage.xaml file where the text "INSERT_YOUR_BING_MAP_KEY" text appears and the apps just work. The only real exception is the "GPX Route Viewer Sample" as that one is really special. It is under version control and not the Git kind so I have to respond to 3 dialogs fussing that I don't have that plugin in VSE. Once I get past the warnings that my changes will not be under source control and that I need to extra careful and I cannot connect to the Microsoft version control system, then I am fine. Maybe it is a marketing ploy to get me to use it - sorry that is just not going to work. The reason why I picked this example is that I found sites that have large GPX routes that I can download. The first one I tried is a long distance walk across the southern part of England. The second gem I found was a site that has data for each state so I naturally went to the NC section. I picked 3 of them, 309 airports, 8961 churches, and mother of them all of 12,875 water features. I tried downloading them locally on my laptop and also use Microsoft's SkyDrive, but I could not get them to show up every time in the Windows 8 file chooser for the Bing Map app sample. I was able to get the England walking path to load and to animate so that is pretty fine for today. It turns out that the SkyDrive thing is not as simple as I thought. On my laptop all I have to do it know where to go instead of using the web site since the files got saved as XML instead of the required GPX file extension when I used my Mac to upload the files. it turns out that location is C:\Users\Rick\SkyDrive, so I just downloaded the files on my laptop and then moved them into that folder and it then worked. Then I realized it was there all of the time in the Windows Explorer left side bar! Besides my SkyDrive problems, the NC files crash the Windows 8 app so there is something in there that is does not like. I then found the final gem of the day as a site that has GPX files for Nepal Himalayas treks.


How NOT to get customer support

Yesterday as I was trying to get information from the SONY support site, I clearly found the wrong way to ask for product information. Typically when trying to find support, the desire to put up with a bad site to solve the problem at hand is very different from a shopping experience. In my case I bought my product at BestBuy but the only way for me to get help is on the SONY site as this is a brand new product and Ms. Google did not offer me any advice. Let's walk thru what I mean.

I went to sony.com and found the support site, besides the fact that side-pull menus are bad this is the menu path to the support site:


I just happened to have my product model number but the main support site is so colorful that my eye is drawn to the 6 boxes in the middle, none of which help me. The good news is that the bright orange  "GO" button also draws my eye and so I enter my model number of "SVF14N13CXB" and click on the "GO" button.



It takes me right to the correct place with every thing I need, or so I thought. Turns out I need some individualized help so I try the "Chat Now" link.


I see they have automatically filled in the model number, which is really nice:


The customer experience is just as I expected and is just about as simple as it can be. I find entering my email address a bit suspect but over the past few days I see how it is helpful in saving the chat transcript for later reference so I over look that part.

This is NOT what happened to me yesterday as I had to walk thru a horrible process of entering my product number is huge hierarchy of existing SONY electronic products. I wonder what prompted them to fix the form and allow a free form model text box entry? Too many customers complain or did someone in customer support try to help a customer and saw and reported the problem? It was definitely not useful. I saved the screens to show just how bad it can be...

Instead of a text box I have to select from a hierarchy:


After scrolling thru the manageable list, I find "Personal Computer" and click on it to see my choices under it:


At first the list appears to be alphabetically sorted, but when I see products starting with "V" followed by some starting with "S" I realized I have to take my time and look for my model number in the whole list. I finally find my model number at the bottom and then realize this list is ordered by historical release date from oldest at the top to newest at the bottom, so my model is near the bottom:


Then I see that it has filled my selections into a very interesting looking drop down menu in the chat form:


Fully expecting to be done with the torture form, I am then presented with a set of choices that are just not the best way to build customer confidence in your site:


Besides the fact that it did not help me, having a bunch of identical links definitely appears to be a bug. I give up and try the "Chat Now" button and then I am presented with yet another form:

It is kind of sad that I have spent so much time so far and gone thru three different screens and still not gotten any personalized help. The last screen makes sense as the support team wants to know the specific model number when the process of going thru the product hierarchy only filtered the model down to a family of products.

This perfectly illustrates the current solution to this for customers is to allow them to enter a model number and verify it after they entered it as it is so much easier.

Monday, November 18, 2013

From concept to reality in 6 weeks - part 2

Now that I have a Windows 8.1 Pro machine setup with all of the patches, the next step is to get the Windows Phone 8 development environment up and running. Hopefully this is easier than the day I spent on get my new Windows laptop running.

First thing is to get the Windows Phone SDK 8.0. The first decision of the day is to figure out which Microsoft page to use. We have the main download center Windows Phone SDK 8.0. There is also the developer center for Windows Phone SDK 8.0. I choose the one on the development center page as it has an update to support new emulators since SDK 8.0 was released on 30-Oct-2012. I found that date on the main Microsoft download site and realized that it is a year old. That is good for me as that means I am not on the bleeding edge of Windows development, which for me is somewhere I never want to be. The download link is an installer, which was only 1 MB in side so it downloaded quickly. It comes with a Visual Studio Express 2012 Edition. On the developer site it states that the actual download is 1.6 GB, which is the size of the download that the install retrieves I assume. I immediately went ahead and downloaded the SDK 8.0 Update at the same time.

After getting Microsoft Visual Studio Express 2012 for Windows Phone (VSE) up and running, I decided to go ahead and sign up for a free developer account, since the initial download is free for 30 days and then you have to have a Microsoft account. I used the same Microsoft account I signed up for before purchasing the laptop and the same one I use to login to my laptop. To do this, when VSE came up I clicked on the "Joining the developer program" link on the Start Page. Guess what happens when you click that link? I got a Script Error! You have to be kidding me. That brings back bad memories of my past using Microsoft products. I quickly clicked on YES button for the question "Do you want to continue running scripts on this page?". I then see that VSE has loaded the register page in a tab within VSE that is actually an IE window that points to part of the developer Publish tab for the Join the program page.

Next up for me is to get example code as that for me is the best place to get started to learn what I can do. Last week I read up on the API and visual components to Windows Phone 8. It turns out that I can get all of the samples in C++, C# and JavaScript in one place. I need some Nokia map examples as that is the most important thing I must get working this week. I jump over the here.com and look for sample code there. Last week I learned that the big difference between Windows Phone 7 and 8 is the switch from bing.com maps to Nokia here.com maps. Finally some good news, when I see that Nokia here.com map sample source code is available on GitHub. I know how to do GitHub, but have never attempted it on Windows. Things are starting to look up as there is a GitHub client for Windows. The download and install was painless as I already had a GitHub account so I logged in using my personal account. I then skipped back over to the on the Nokia developer page and used the Git URL to download all of the maps samples. So now I have all of the Microsoft and Nokia example source code on my laptop. Now let me load a couple of them and see if I can run the emulator...

It has been around 10 years since I used Visual Studio, so this is going to be like starting all over again. I decided to go back to the Windows Phone 8 page and try to work thru an simple example before I get to crazy with the samples. Instead of a way too boring and overused Hello World example, Microsoft choose to show how easy it is to open a web browser in Windows Phone 8 as their first example. I am just going to reserve my comments on VSE as the initial shock is just going to be too great to want to compare it to the slow Eclipse for Java or Apple Xcode for iOS, which are the only two other IDEs that I have used in the last 10 years. These tools take a while to master and each is different and just takes a while to get used to. Maybe by the end of the week I can make a better judgement call on the differences.

In order to build my first Windows Phone 8 app, I just followed the steps on the page how to create your first app for Windows Phone. All went fine until I tried to run the app in the emulator. I got an error message that I did not have the emulator configured correctly. I guess I missed one of the BIOS settings that I was careful to make sure my laptop supported. Then I tried exit VSE and saw the most meaningful message that I have seen today, a big red (X) icon followed by "0x80131500". That was so helpful it hurts. When I clicked OK on the error dialog, I saw the same "0x80131500" in the Error List at the bottom of VSE. If all else fails, then click on the window close button and everything was magically fixed by closing VSE.

Now I need to check the BIOS settings, so I bring up the instructions on my Mac laptop so I can read them when rebooting my Windows machine and need to check the BIOS settings. I then find the system requirements page and find the page that explains issues with setting up Hyper-V for emulator. Now I have a problem as I have to figure out how to access the BIOS on my Sony VAIO laptop, since the article mentions "", or "" or "" as typical ways to get to the BIOS on reboot. I would prefer not to try multiple times as that is just painful. I head over the Sony's site and find out the PS4 is now available. That is helpful but I don't care. I try "Support" at the top of the page and then select Electronics, since my only options are Playstation or Entertainment. I am clearly not in a playful mode nor do I feel entertained. The only clear choice on the next side pull menu is Product Support which leads me to a very confusing page. Thankfully I know to get the model number for my Sony laptop, so I enter SVF14N13CXB in the box in the middle of the page and hope for the best. At least I am taken to the correct page as I see my computer name at the top Fit 14A / Flip PC. There is a big search box on the right, so I entered BIOS and hope that something pops up that is useful. I click on the top most link and unfortunately for me I see a page with "Permission Denied" in big bold letters followed by "An illegal parameter was received" in small text below it. That was not helpful at all. I went back and clicked on the next link and the same think happened. Then in act of desperation I click on the link to chat with a Sony rep. It takes me to a form that looks simple on the surface, but then I have to enter my product and that is just as painful as it can get. I have a very small box that has tons of options. I search thru the whole list and then pick "Personal Computer", which opens a few choices. I select "Laptop PC" since that is what I believe I have but now computers are getting confusing as I have a laptop that pretends to be a tablet! I am so happy I know the model number as how I get to scroll thru a very large sorted list looking for it - problem is that the list is not sorted alphabetically so it makes it very hard to find. I cannot enter the number so I have to find it in the list, categorized in a way I don't understand. I finally find my model number at the bottom so it must be ordered historically. When I wait patiently for a bit, then I see a dialog popup with the same text repeated five times. I click on the top one and it takes me to something not useful at all as it is a patch to the BIOS and has a date of 10/21/2009, so something tells me that is not helpful since my computer was just released this year. I then decide to give up and chat with someone. I click on the live chat button and then I see a screen that tells me the product I entered does not exist which was a generic series of "SVF14N1SERIES". At least now I am presented with some choices that are close to what computer I have. I find my model number and enter into yet another chat. Hopefully the customer experience will get better now that I am chatting with a real person. I found help within one minute, so at least Sony got that part right. I was told to follow instructions on the BIOS page sent to me thru chat. The only thing I found in the BIOS menus related to the Hyper-V emulator settings was "Intel(R) Virtualization Technology" was disabled under the Advanced menu. I enabled it and then saved the settings and exited, hoping this was all I need to change.


Now that I have conquered changing the BIOS settings, I reboot the laptop and switch to Desktop view. I just cannot remember how to open programs in Desktop mode as I have to find the VSE program to start it again. Since the start menu is gone in Desktop mode and opening Windows Explorer required me to search for a file name, I am kind of hosed. I remembered where VSE saved my project file so I navigated to it and double clicked on the VSE project file in "C:\Users\Rick\Documents\Visual Studio 2012\Projects\MiniBrowser". When I tried to run the emulator it failed again.

I went back into the chat window and refreshed it so I did not have to wade thru their chat screens that prove usability matters and definitely leaves an impression when done incorrectly. I sent the Microsoft link to the SONY support person and he sent me instructions on how to enable Hyper-V on SONY laptops using Windows 8.1 Pro. I tried to following the instructions and found out they did not work as they were Windows 8 Pro instructions and I needed Windows 8.1 Pro instructions. At least the SONY support person waited for me to go thru the steps and the chat window did not expire like with other hardware sales people I chatted with on Friday. That is a good plus for them that is started to out weigh the bad chat screens I had to go thru. After following the instructions with some chat help and rebooting my laptop, I restarted VSE and this time I remembered that I needed to use the search charm and search for "VS E" and it comes right up. When I re-launched VSE, I saw a different error message about permission denied and when I clicked Retry button, a system prompt came up and when I accepted that message, the emulator ran and I see a Windows Phone on my laptop. Success and time to go home!

Day one - get computer working.
Day two - get Windows Phone app running in emulator.

Friday, November 15, 2013

first impressions of Windows 8

I should at least comment on what I see as I begin to use Windows 8 for the first time...

I have been using computers for 30+ years, so I should be able to figure this new beast out. I want to try it out for a bit before I switch to use Desktop mode which is familiar enough that I can get my work done ...

I know flat design is in but it sure it hard knowing what I can click on tap on. The good thing is that my new laptop came with a 4 page color quick start guide to help me get started as I would never guess I have to put the mouse in the upper right hand corner to see the Windows dock - sorry I mean list of charms. Who thought calling icons on the screen charms was a good idea? I thought charms were those things that girls wear on necklaces or on their wrists. Then again icons are not small like drawings on the screen either. I miss my Mac Finder Spotlight as on Windows 8 I must search within a context. For instance in the quick start guide it states that I must click on Search charm and then Settings and then search for Windows Update. So very sad.

My favorite so far is when I installed the VAIO updates as it automatically switched me to Desktop mode instead of the Start screen. Of course I had to wait for the standard Microsoft progress screens of downloading and installing for endless minutes. Kind of amusing that anyone would want to see the Desktop mode as all I care about is that my updates have worked. The standard Windows Update is all I care to see. It is pretty odd when the laptop goes into sleep mode as I have to get used to the clock and default drawing of Seattle - wait a second I can change that. It is pretty easy to customize the lock screen background as they have 5 different drawings/photos to choose from - I guess when going to flat it is also time to simplify all of my choices! The default color scheme and stylized drawings available for the Startup screen are pretty odd, but easily to change to one of the provided ones.

I did like the 5 or so screens when I first turned on my laptop as it helped me immediately get WiFi working and since I already had a Microsoft account, which I setup yesterday to access some of the developer documentation, I was able to get on the internet right away. Until of course I started applying updates, which left me plenty of time to blog!

By the way, who came up with the 5 dots that fly in from the left, collect together and then fly off to the right as a way of showing progress? I guess that matches the new spinning dots I see while waiting for updates to be applied while restarting my laptop. Change for change sake I assume.

So I bought a Windows Pro 8, since Windows Phone SDK requires it. I open the nice box and low and behold I see instructions that look good but don't work. Inside the box is a card with a product license key. I have to find out where to enter the code since the instructions don't work. Thankfully I have my mac to enter this blog post and search for answers - wait I have some version of IE available on my VAIO machine so let me try it. That was easy as I just entered "windows 8.1 upgrade" in IE and with two clicks I was on the Windows Store and waiting for the Windows 8.1 download - nice. Of course very nice would have been if when I ran Windows Update then 8.1 would have been an optional choice which I could have checked and it would have been done auto-magically. For now I just want a working computer, so nice will do.

While waiting for the 8.1 download, time to get back to figuring out how to use Windows 8.  Wait, I can try to switch my laptop to be a surface. I look thru the paperwork and find instructions on how to do that. So I can use it in 3 modes: Laptop mode, Viewer mode, or Tablet mode. Viewer mode has less steps and is first so let me try it. Pretty easy with instructions, but I have a problem. My display is up side down. I finally realized it is not an iPad as it did not automatically detect the orientation change. Unfortunately no mention how to get the display to do that, so enough of Viewer mode as that does not help me. Tablet mode was pretty easy and I can see how that would be useful as the screen lays right on top of the keyboard. Maybe one did I will have the Windows Phone emulator working and can demo this to my customer by pretending the laptop is a mobile tablet with their app running on it. When I moved the display back into position, the display automatically switched so maybe the first time it does not work! I surely hope not and expect this to not work again in the future  when I need to use it that way!

Now I did it. When I was messing around with the display I no longer see the Windows 8.1 update screen. I reopened IE and I see my last search right there waiting for me. I got back to the Windows Store and it says I can download the update. It cannot be that bad can it. No it is not, in the upper right hand corner I see green text on the white background telling me something "Updates (20) installing 8.1..." and when I click on that I see a screen that shows 20 medium size boxes with green borders that contains icons and text for apps to be updated - each has a green checkmark in the upper right hand corner. Not sure what that means - have them been installed or ready to be installed or available to be installed? What else would I see there? Maybe a red border with a red "X"? If I click on a box then the green border and check mark are removed. Now I see what they are trying to show me. If I click on "Installing Windows 8.1..." text in the upper right hand corner I see Windows 8.1 is installing. That is odd behavior that I have to toggle back and forth to get an idea of what is going on and what will happen next. I am hoping after Windows 8.1 is installed that the 20 app updates will be installed, but I have no indication that it will occur without me doing something. It down download 8.1 and automatically start the install so maybe there is hope. I would guess I am a couple of restarts away from that happening anyway.

I do like the simple IE in Start mode as I definitely understand that surface users do not need to see a bunch of window decoration when viewing a web site since the web site now takes up as much of the display as possible - nice. I can do this on my Mac but that is an advanced feature and to know how to get out of that mode on my Mac is not totally obvious.

I am now hoping that within 3 hours I will be have a computer ready to install Windows Phone 8 SDK on and my goal is to have my first app running by the end of today - please Microsoft help me achieve my goal and don't get in my way. The good news is that I have plenty of time to memorize the Windows 8 Getting Started guide since I am stuck at "Setting up 83%" for a while - wait it just jumped up to "Setting up 87%"! I thought it was installing Windows 8.1 but it is telling me it is just setting up something. Then all text disappeared and now all I see is a spinning dots and then a total black screen - no wait after a minute it switched back to the spinning dots. Then I see "Getting devices ready" followed by a bunch of screen flickers. If only this was much faster I would not have to be commented on every odd thing I see. It is only because I never have this problem with my Mac. Switching from OSX Lion to OSX Mavericks was an hour and it seemed like an Apple eternity and that jumped one who operating system level as I never installed OSX Mountain Lion. Wait a second, going from Windows 8 to Windows 8.1, how hard could that be as that is a minor version change. Apparently pretty difficult as I have been waiting for an hour now. I am encouraged now as I see "Applying PC settings 25%"; however, the only problem is that I have absolutely no idea how many steps are left or how many I have waded thru. Besides, what does that statement mean that it is applying PC settings? Maybe it is almost done? One can only guess and hope.

More comments on Windows 8 while I am waiting. After looking at the gestures illustrated in the color brochure, how would someone figure these out? Who is the target user for these surface laptops? Definitely not Apple iPad users as the gestures are nothing like those I am used to using. Maybe it is young people that like learning new ways of doing the same thing. It was amazing to watch the young fellow at BestBuy last night swipe his way around so quickly that I could not even tell the gesture he was using, so no hope in learning that way. Now I am at "Setting up a few more things 3%". The only trouble now is that the next message is "Setting a few more things 6%", so my wait will not end soon most likely. Then the most helpful message of the day "Getting ready", right at the 3 hour mark from when I opened the box.

Now I am kind of irritated because when I turned on the laptop this morning it asked me a series of questions and now with Windows 8.1 I am answering the very same ones. I am 100% sure none of those changed in the last 3 hours! This business of sending my email a code that I have to enter as part of the install process is definitely an oddity I was not expecting - maybe that is supposed to make me feel more secure. And then the message "Hi" I see on the screen - which makes it all worthwhile somehow. Instead of just being friendly, now I see the screen rotating thru the color palette with the messages "Taking care of a few things" with "Installing you apps" below it followed by "Taking care of a few things". Then I finally see my startup screen at 3 hours and 5 minutes.

Now I have to give up blogging as I see they have fixed some of the things in Windows 8.1, as now I see text "Everything ˅" above the search box which is definitely going to make finding stuff easier already! Of my gosh, so close and yet so far. When I searched for "Windows Update", I was switched from Start mode to Desktop mode. Now do I get back? They have added the windows logo on the left side of the menu bar and when I click that I get back to Start mode - wow two problems fixed that bothered me that quickly. And just when I thought I was done, it turns out I have two more updates that require yet another restart. I think is about my 5th restart, so I am close to averaging one every 30 minutes so far today. Come on Microsoft is the really the best you can do?

Surely now I am done? I am on step 5 out of 7 on the Sony Quick Start Guide. Sony has tried to get around this Start mode vs. Desktop mode confusion by adding a hardware button called "ASSIST", which automatically switches to Desktop mode. How that is putting a bandaid on top of a bandaid.

And then after 3 and half hours it is all worthwhile as I finally found a match when I searched for "Add features to Windows 8.1" as I paid $100 for Pro and now I realize I don't have to return it to BestBuy and get my money back. And I was able to enter the 20 digits on the plastic card the first time - I think I am getting better at this Windows 8 stuff. My old bad habits are returning just like I wanted to forget about them. Just when I thought everything was done - my code was verified and then it failed on the last step. I go back to the first step and I see the message "This key won't work. Check it and try again, or try a different key.". The only problem is that the key matches as I got someone else to verify, so time to call BestBuy... Who told me I had to bring the machine in and then they could swap out the card for me. When I objected, Mr. BestBuy told me to call the Geek Squad. Hopefully they can help me so I don't have to take it into the store. Bad news, I have a 9 minute wait ahead of me for the geek to rescue me from Microsoft... Turns out no they cannot. What makes matters worse is that the geek hung up on me! How rude!





From concept to reality in 6 weeks - part 1

Early this week at work I was volunteered to take an existing iPad app I designed and to build a working prototype of the same app on a Windows 8 Tablet. Seems simple enough, until I realized what I was up against in working on Microsoft products after a long welcome break. I last worked on a Windows machine 3 years ago. I have used only Apple products at home for over 10 years now. I guess you just forget how simple and lovely life can be until you re-enter the dark side of computing.

I really enjoy working on new things as that is what makes me wake up ready for work early in the morning. It can be scary at times as there are so many unknowns and not only from the technical side but also from the business perspective. I had a hard deadline of January 7th where this app will be shown at a trade conference. The Windows 8 Tablet would ideally work just like the iPad app but that is impossible since it is totally different hardware and user interface. From start to finish the original iPad app took 72 man days which includes design time and all of the time to develop it. I essentially have only 30 man days to get the same design working on a brand new version of Windows on a platform I know nothing about. That would normally mean it is time to panic.

Yesterday, I reviewed these concerns with the customer to make sure it was clear that the task was daunting and yet possible with caveats. We had to agree to set expectations that a full Windows 8 app just like the iPad app was not possible but a great demo can happen if everything falls into place. Then the first bombshell happened as I found out that the brand new physical tablet would not be in my hands until the week before Christmas at the earliest. Still not time to panic yet.

In preparing for that meeting,  I first read the Windows 8 guidelines to get a feel for what was possible. Since geographic maps are a key part of the app I am prototyping, I needed to learn about them for Windows. After some digging I discovered that in Windows Mobile 8 they switched from Bing maps, which were used in Windows Mobile 7.1, to Nokia maps. That is kind of scary, but at least HERE.com has been used elsewhere for a while and then Nokia purchased them and now they are available for Windows 8.

The biggest question of the week is what do I use for a development machine? I found an article on the Windows 8 SDK requirements. I also read that using my Mac is out of the question as the emulator will not work on virtual machines, like VirtualBox. So how do I find a machine that fits the strict Hyper-V requirements? It turns out that no computer manufacturer has this information on the web. I tried Lenovo, Dell, Asus, Samsung, Acer, and Best Buy web sites. Some made it hard to even find out if Windows Pro was available and whether 64-bit machines are the default. I could write a long article on the usability of shopping for a laptop as most of these sites did not help me. I could write another long article on live chat services since I tried chatting with sales and technical staff at Lenovo, Dell, Asus and Samsung. At least the Lenovo sales person told me he did not know but would find out for me and then re-directed me to a technical person who could only find a match in a desktop machine. The number one problem with web sales chat programs is that they timeout if unused, which I fully understand. The problem is while the sales person is searching if they don't say anything and I don't say anything then the session times out and is terminated. This means I get to start all over again. One of the people I chatted with could not get on the web so my Microsoft SDK link was not even visible to them. Then I contacted Dell as I thought that may be a better user experience for me. Turns out it was much worse. I tried 5 times to chat and every time the session expired before I could get help, so I finally gave up. Most of the chat programs send a transcript of the session by email but that was 5 emails I immediately trashed. The person at Asus was the most helpful as he admitted immediately he had no idea but told me to go to BestBuy and get them to reboot the computers I thought looked good and then view the BIOS settings to see if they matched  the Microsoft specs. Finally someone who had a novel and useful idea. I wanted to complete my due diligence and chatted with Samsung and the first person I found gave me the best customer experience of all time. He told me it would be a couple of minutes and sent a message every minute to make sure the session did not time out. He pushed a link to me with an machine that met the specs. It was a bit pricey so when I asked about a cheaper model, he sent me a list of all of the models Samsung sold that matches the spec. Within 10 minutes I had more useful information that the couple of hours I spend trying to find a computer elsewhere.

Then I went to Best Buy last night with the intent to buy a Samsung computer since my chat experience was so great. Turns out that BestBuy had sold out of the model I needed that fit my budget, so I turned to find a BestBuy sales person. I had printed off the Microsoft specs and gave it to the sales person as I was disappointed in thinking I had to start a very long process to find the correct machine and I had an evening meeting I needed to attend within 45 minutes. The sales person was like a kid but he knew how to be helpful so he took me immediately to a machine that fit my needs. Not that I didn't trust him but for $1000 I wanted to make sure I got the correct machine. He looked up the Microsoft article, rebooted the machine and checked the BIOS settings. One of them was not visible, so he downloaded a standalone program to check the remaining one, followed the 10 steps and found my answer than indeed the machine had what I needed. It was just as the Asus man described and I walked out with the computer and today starts my next story...

When to give up

I have decided to resume blogging and the best place to start again is to honor the honorable god of cricket, Sachin Tendulkar, who is retiring from cricket at the age of 40. I am sure he must have faults but he really impresses me with his gentlemanly attitude in the age of self glorification in the sight of money and fame. There are very few famous people I have any interest in meeting but this 5' 5" legend would definitely be near the top of my list. When professional athletes world wide are turning into tattooed, self indulgent, ego maniacs, I am so happy to finally see a person worthy of the title of hero and role model. Maybe one day in my visits to India I will get to meet him.

This all reminds me when I was 40 and retired from playing basketball publicly. I still remember the Christmas I turned 7 when I received the wonderful gift of an orange basketball rim. I can picture my dad putting up a square piece of solid plywood above the garage, painting a black square on it and then mounting my shiny new goal on it. I played basketball on that driveway for hours daily for years. Sometimes I would long for people to stop by to play with me no matter how much older they were than me. Hours on end I would dribble around the edge of our long driveway and shoot endless numbers of free throws. My life and dream for many years was to be a professional basketball player. Then I hit high school and I failed to keep growing so was just too short for the basketball team. I switched to cross country running but still loved to play basketball every chance I got. My first year of college I suddenly grew 6" and suddenly I was a reasonable height again for the hardwoods. What made it interesting is that I was always a guard when I was young as I had great ball handling skills from the hours and days of practice and was very fast. Now that I was taller, I was automatically playing forward which I had never done before. All of that self inflicted training paid off.

Well into my late 30's, I typically played basketball a couple of hours every other day. Since I never had any serious injuries related to my knees I made a huge decision to quit at age 40. I had some bad basketball related accidents. While playing in Saudi Arabia, I got hit in the mouth and lost 1/4 of one of my back teeth. In Houston, I was playing with old worn out shoes and the whole side of the shoe blew out when I tried to stop quickly,  which resulted in a horrible 6 months of pain and surgery for plantar fasciitis, followed by 5 years of wearing hard orthotics. The best thing to come out of that time was that I now have real arches as up to that time my foot was totally flat. The scariest injury was when a clumsy fellow who played nasty ran up to me from the side and bumped into my knee at full speed. That resulted in 6 months of daily swimming to rehabilitate my knee so I could play basketball again. I always seem to get injured and my wife would comment on how injury prone I was since I had to go all-out, full steam when playing. Still for me I did not have any ACL or major injury so I played basketball for the last time publicly for my 40th birthday. The only times I have played since it to teach my youngest son that someone twice his age can beat him any time I want!