Thursday, December 26, 2013

Silencing the Arc Touch SE Mouse

I’ve been using the Microsoft Arc Touch Surface Edition mouse for almost a month now. In fact, I’m coming up on the last possible return date. The thought of returning it has occasionally crossed my mind because sometimes I can’t use the mouse without annoying others in room due to the vibrating/clicking sound the mouse makes when you scroll. But as I discovered today, you can easily turn off the sound. And conveniently, all you have to do is install an app from the Windows Store.
Interestingly, once I turned it off I realized that I kind of miss the feedback. Easy enough, though, to toggle it on/off when needed.
Overall, the mouse itself is convenient. Easy to flatten and carry, requiring little space. It’s not the most comfortable mouse I’ve used but I think I’m fine with the tradeoff I get for the portability.

Wednesday, December 18, 2013

Yoga 2 Pro - Initial Thoughts

I'd been planning for most of this past year to retire my older Dell Vostro 1520 laptop and replace it with a Surface Pro 2. Even when the original Surface Pro was just out the gate, I was content with resigned to waiting for the better-performing Haswell-based variety I kept hearing about.

I wanted the convenience and versatility of a tablet/laptop combo to use as my one device no matter where I went. I needed something powerful enough to run Visual Studio and SQL while also light and portable enough to kick back and enjoy a touch-first experience with the more-than-sufficient number of good Modern UI apps available in the Windows Store.

I did have one nagging question, however, that kept me from pulling the trigger: what would it really be like to work many hours straight on the smaller 10.6" screen, particularly when staring at the code editor?

While debating this in my mind, I began seeing a new round of convertible Ultrabooks that were intriguing. They were touch-capable laptops first, but were small enough and light enough to be used as tablets in certain scenarios. The more I thought about it, they fit my personal needs better.

I settled on the Lenovo Yoga 2 Pro, the next iteration of their Yoga series featuring a 4th-gen Intel (Haswell) processor. I also looked at the ThinkPad Yoga, but ended up with the Yoga 2 Pro for two primary reasons:
  1. Best Buy carried the Yoga 2 Pro at a good price given the specs. In particular, their excellent Christmastime return policy made it a safe option.
  2. The Y2P was thinner/lighter than the ThinkPad Yoga, with a slightly larger screen and a somewhat more appealing profile. It was also a bit less expensive.

Here's my take on using it for the first two weeks:

The Good:

  • Convenient. It is lightweight and fast.
  • Sharp screen. The high resolution has generally not been an issue for me on the desktop. The DPI setting defaults to 200%, and it is needed. Visual Studio does a pretty good job scaling at that DPI setting, as do Office and IE. SQL Management Studio doesn't seem to scale as well (the Object Explorer tree nodes are a little small), but it is sufficient. Even Chrome isn't as bad as I'd heard, but the tabs don't utilize the space available to them. [UPDATE: It appears that Chrome tabs are now displaying more appropriately]

  • Tablet mode. It's nice, but I haven't used it much, and I think that fact confirms that I made the right choice in going with a laptop-first device.

The (Initially) Not-So-Good:

  • Wi-Fi wouldn't work out of the box. The wireless adapter didn't even show up in Device Manager. Installing Lenovo's wireless adapter driver resolved the issue, but I'm not sure what happened there.
  • Bluetooth was a major issue and almost caused me to return the device. My Arc Touch SE mouse was constantly dropping. I thought that perhaps the Y2P's single-band Wireless-N card could be conflicting with Bluetooth since that uses the same 2.4GHz band. After a few frustrating days messing with drivers I decided to uninstall the Lenovo driver and use the generic one. That still didn't help. But I then came across a thread in Lenovo's user forum that pointed to one simple setting. Since unchecking this setting, it has been solid - only one drop in a few days. I still haven't re-installed Lenovo's Bluetooth driver, but it suspect that won't be an issue.

  • I did also get a few BSOD errors related to Bluetooth, but that was early on and was probably related to messing around with the drivers while trying to fix the drops. None of that has occurred since those first couple days.

Other considerations:

  • I continue to occasionally see this message in the System event log when booting, pertaining to my use of Hyper-V (needed for WP8 development): "The speed of Hyper-V logical processor 2 is being limited by system firmware." I'm not sure why, and I'm not sure yet whether this is a big deal. I can still run the WP8 emulator.
  • The Function keys come defaulted to using Lenovo's specific settings, and this is actually pretty useful in most scenarios. But this setting can be reversed in the BIOS so you get the normal use of the F keys without pressing Fn.
  • I like the feel of the keyboard, but haven't completely adjusted yet to the layout of the Page Up/Down, Home, End keys.

I've got another few weeks to return it, should I need to. But I'm hoping I'll continue to find the performance good and the device stable. I still think the Surface Pro 2 is a great device and might work for my scenario, but I am glad I went with a larger device given my needs.

Final note worth mentioning: I did wipe the primary partition and install a clean copy of Windows 8.1 Pro.

Friday, September 6, 2013

Building multi-interface apps with CSLA

I've benefited from using the CSLA framework in a number of projects at work over the past couple years. A recent side project gave me an opportunity to stretch my knowledge a bit, and CSLA was a big part of making it happen in a way that made sense and let me focus on the app's logic and presentation and less on the plumbing.

Here's a poor man's visual of what it looks like to support both a Windows Store app and an Azure-hosted Web app:

By no means a textbook example of how to use CSLA, but it works and is maintainable.

Friday, August 2, 2013

Good Ideas Take Time

I enjoy the challenges of learning and applying new skills or concepts to produce something that has value, but sometimes wish I could arrive at the destination quickly. From the design, to learning the techniques or frameworks necessary to implement the design, to the inevitable gotchas, lots of time is often required to bring ideas to fruition.

It has been a little over a year since I started my personal project called Scripture Box. When I began, all I knew was that I wanted to create a "simple WinRT app." But reality set in (actually, it still is):
  • XAML differences between WPF/Silverlight and WinRT
  • WinRT application life cycle, app contracts, etc.
  • The whole occasionally-connected app scenario
    • SQLite
    • Azure Mobile Services
      • Gotcha - can't update a SQL Azure table via Moible Services unless the Id column is explicitly lower-case (id vs Id)!
  • Continual design revisions as I've observed more and better apps in the Store
  • Windows Store Design Guidelines
  • Windows Store API
  • Ins and outs of a LLC
    • legal issues
    • taxes
    • funding
  • Having a good web presence
  • Azure Websites and Cloud Services
  • Marketing your product
  • Creating a good web app experience for reaching more people
  • Pricing an app / service
    • What the stats show vs what you think makes sense
    • Second-guessing your pricing strategy
  • Prioritizing the countless ideas that come to mind for improving your app / service, with each involving more learning and gotchas
I've learned a lot in the past year on this project - more than I anticipated. In the forefront is the reality that worthwhile ideas take time to develop.

Friday, July 19, 2013

Binding a ComboBox in a DataTemplate with XAML

I've been struggling to figure out how to bind a ComboBox inside of a ListView's DataTemplate. The problem I experienced was that when I changed the value of one ComboBox, all other ComboBoxes in the list got changed to the same value. Turns out the answer is to simply use the IsSynchronizedWithCurrentItem property. Hope I remember this one the next time around.
ItemsSource="{Binding Source={StaticResource deliveryTimesViewSource}, Mode=OneWay}"
SelectedItem="{Binding DeliveryHour, Mode=TwoWay, Converter={StaticResource deliveryHourToObjectConverter}, ConverterParameter={StaticResource deliveryTimesViewSource}}"

Wednesday, April 3, 2013

Printing SSRS reports directly (without previewing)

In case this helps someone else looking to do the same thing...I had a hard time finding consistent information on how to enable direct printing (i.e. without previewing) SSRS reports. Perhaps I just didn't look long enough, but almost everything I saw was either incomplete or not that helpful. The one source I found to be clear and helpful is by Brian Hartman. Source code included.

Monday, March 4, 2013

Scripture Box to the Web!

I've finally begun working on my goal to bring Scripture Box to the Web. Scripture Box currently exists as a Windows RT app (published in the Windows Store) and is slowly but steadily seeing adoption. But as I continue to view the website stats, it is clear a large number of people have an older version of Windows (mostly 7, some Vista/XP, but I even saw a couple Win 2000 and NT) as well as Macs. Of course, there are a number of visits by mobile devices as well (approx 15% of all visits).

While I would enjoy taking a shot at iOS or Android (probably using Xamarin), I believe I'll get the most return out a simple but effective HTML5/Js app. I'm mainly still thinking through technical design at this stage, and the following resources have provided plenty of good considerations:

I've already set up my ASP.NET MVC 4 project, installed Web Essentials, hooked up a little bit of data and published a few tests to Windows Azure. The project templates Microsoft added to MVC 4 provide a HUGE benefit. I'm also looking forward to getting even more out of the CSLA Framework. I plan to write a post about the overall design after I'm done.

Tuesday, February 12, 2013

RDP via Surface RT and Citrix

Until today, my only disappointment with the Surface RT was that I couldn't connect remotely to my PC at the office. The problem wasn't with the RDP capabilities included in Windows RT. It was that I couldn't connect (or didn't know how to connect) to my company's network from the Surface. But the following steps did the trick:
  1. Logged in to the Citrix portal with the IE Compatibility Mode setting turned on;
  2. Launched the Remote Desktop app;
  3. Specified that I wanted to open the resulting .ica file using the Citrix Receiver app.
It feels great to longer need my laptop on a trip just in case I need to deal with an issue at the office. Now I can have access to Visual Studio and all other tools from the Surface RT.

Wednesday, January 30, 2013

Determining Internet Connection status in a WinRT app

Last week I received word from someone using the Scripture Box Windows 8 app that he continually received notifications that he wasn't connected to the internet. That is, the app thought he was disconnected and therefore wouldn't try to sync with the Azure mobile service used for cloud storage.

I was quite confused. In all my testing - both with connected and disconnect scenarios (on multiple machines) - the app always correctly identified my internet connection status. I was using code similar to the following:

         var ConnectionProfiles = NetworkInformation.GetConnectionProfiles();  
         foreach (var connectionProfile in ConnectionProfiles)  
           if (connectionProfile.GetNetworkConnectivityLevel() == NetworkConnectivityLevel.InternetAccess)  
             App.IsConnectedToInternet = true;  
             doSync = true;  

While searching for potential problems, I ran across another slightly different method to discover one's connection status:

       ConnectionProfile conProfile = NetworkInformation.GetInternetConnectionProfile();  
       if (conProfile != null && conProfile.GetNetworkConnectivityLevel() == NetworkConnectivityLevel.InternetAccess)  
         App.IsConnectedToInternet = true;  
         doSync = true;  

From the documentation I couldn't quite tell what the difference was, and which was the correct to use.

I also happened to stumble upon this helpful post that basically included a simple but effective manual approach to checking for internet connectivity:

     public static async Task<bool> IsConnectedToInternetManualCheck()  
       HttpWebRequest req;  
       HttpWebResponse resp = null;  
       Uri url = null;  
       url = new Uri("");  
       req = (HttpWebRequest)WebRequest.Create(url);  
         resp = (HttpWebResponse)await req.GetResponseAsync();  
         req = null;  
         resp = null;  
         return true;  
         req = null;  
         return false;  

I figured this was a last resort effort to check for internet connectivity. So which method to use? I couldn't reproduce the issue, and I certainly didn't want to break what was working for others. I also didn't want to go through the release/certification process multiple times for the same issue. (For a few seconds I was tempted to see if this person would be interested in side-loading for testing purposes.)

I decided to take the safe approach and chain the three methods together: first checking with NetworkInformation.GetInternetConnectionProfile(). If that didn't work, then I'd loop through all network connections with NetworkInformation.GetConnectionProfiles(), and finally, if necessary, using the manual method above. Not necessarily pretty, but in the end one of the two additional methods worked. I just wish I knew which one.

And on an encouraging side note - the app update passed through the Microsoft Store certification process in approximately 12 hours(!) and was available in the store shortly thereafter. Good job, Microsoft.

Tuesday, January 1, 2013

WinRT App Development from Design to Certification

For the past six months I've worked on a Windows 8 (WinRT) app that started out as a request by my wife, but grew into something I planned to distribute via the Windows Store.  Lots of learning, planning and late nights were required.

I started to loose steam around the beginning of December, but I pushed through that last week until I was finally ready to submit to the store for certification.  I thought I had finished the hard part (design and coding) but then I came to the point of dealing with certification. There were a few items I didn't even consider in my design that I discovered were required for certification, and I had to go back and address those (like implementing certain interfaces).

Take the time up front to look at the certification requirements.  There are a number of resources on app submission guidelines and checklists.  Pete Brown's blog post is helpful, among others.  But Microsoft's own documentation is the most comprehensive and contains everything you need.  It is tempting to want to quickly get through it because of all the points it covers.  Don't.  Invest the time.  Otherwise, you may miss out on some opportunities or simply fail certification. 

Beyond that, here is a recap of the tools/services that I've relied on to get my app completed:
It feels good to be done (at least with initial release).  Hopefully the app will help many while paying for itself, but at the very least I've (a) given my wife and family a helpful tool and (b) learned a lot that I can apply in other areas of my work.

Check it out: