Three Car Seats in a Prius (or Other Mid-Sized Car). Easily!

Posted by | Filed under , , ,

I love my three kids! As a parent of three, however, I'm faced with new dilemmas like the question of how to transport them comfortably and safely. I could drop up to $40,000 on a new minivan, $5,000 for a used one, but frankly I'd like to save my money and the MPGs by making due with my 2007 Prius. After all, having kids is expensive already, and most family sedans say they hold up to five passengers, right?

Well, if you're like me, you came across a lot of confusing information elsewhere on the internet. There aren't a lot of definitive answers, and those who managed to fit three car seats in the back of their car make their solutions sound a bit sketchy (e.g. awkwardly "puzzle fitting" different car seat combinations or eschewing the latch anchors altogether in favor of seat belts because the fit is too tight).

 Well, my fellow fertile parent, I have some good news! It's actually quite easy to fit three car seats in the back seat of your car, and I have a how-to guide!

 The first thing you need to know is you may have to buy some new car seats. That may come as a bummer for some, but at least it beats dropping $1000s on a different vehicle, right?

 Anyway, the key to making things work is getting a couple Sunshine Kids Radian Car Seats. There are three models to choose from, all of which are specifically designed to fit three across in most vehicles' back seats. The Radian65 holds kids up to 65 lbs., the Radian80 holds kids up to 80 lbs. while being just as narrow as the 65, and the Radian XT, which is basically a Radian 80 with memory foam cushioning and head support.

 All will work for a three-car seat setup, and conveniently lack bulky armrests, but I personally recommend the Radian XT both because you can use it longer than the Radian65 (up to 80 lbs. vs. 65) and it gives your kids a headrest that provides better side-impact protection and head support for when they fall asleep.

 Next, while Sunshine Kids, the Radian's manufacturer, claims that you can use the Radian car seats as rear-facing car seats for babies, I recommend using a car seat specifically designed as a rear-facing car seat. The Radians are especially awkward as rear-facers as they keep their shape, but simply have a plastic shim that tilts them. Beyond looking a little sketchy, this configuration also takes up so much space that you may not be able to slide the front seats far enough forward to accommodate the size.

 Naturally, you'll want the narrowest rear-facing car seat possible also, and for that I recommend the Chicco KeyFit travel system seat, which beyond having higher-quality latch mechanisms, release systems and sunshades than competing Graco travel system seats, is also about 2 inches narrower. 

When put together, it looks a little something like this:

As you can see, the kids are comfortable, with plenty of space. What you can't see is that I'm using the latch system for the two outer seats no problem.

 Note that I put the rear-facing Chicco in the middle and secured it with a seat belt since, like many cars, the Prius lacks LATCH anchors for the middle seat, and sharing anchors with the outer seats isn't recommended. A rear-facing Chicco in the middle lets both front seats slide all the way back, and the travel system seat, though slightly tight, releases and locks without much fuss (you just need to make extra sure you click both sides into place and double check it by wiggling it around).

 Voila! What could have been a $40,000 investment in a low MPG mini van purchase turned into just a few hundred dollars worth of car seats that fit into my car!

 Now if I could just get the big girls to stop reaching into the middle car seat and stealing the baby's binkie!

Currently rated 2.9 by 15 people

  • Currently 2.866666/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Solved! - The service 'System.Workflow.ComponentModel. Compiler.ITypeProvider' must be installed for this operation to succeed.

Posted by | Filed under , , ,

I'm working on a SharePoint project where several componenets (Workflow, List Definitions, Content Types, etc.) are tightly related to the same functionality. To reduce the risk of components breaking because of an out-of-sequence or missing dependency, and just to make things easier, I wanted to throw everything together in the same project. I discovered something interesting about Workflows in the process, however.

Namely, if you try to add a Workflow to a typical project, you'll get an error in the Workflow designer saying:

     "The service 'System.Workflow.ComponentModel.Compiler.ITypeProvider' must be installed for this operation to succeed."

This happens if you added references to the proper assemblies (System.Workflow.Activities, System.Workflow.ComponentModel, System.Workflow.Runtime and microsoft.sharepoint.WorkflowActions)!

Odd, but luckily there are solutions. One is to write a bunch of code to build the support that the Workflow Designer needs, but I was looking for something even simpler. What I discovered, is that you can add support for Workflows to your project (the .csproj or .vbproj file) by cracking it open in notepad and adding some "ProductTypeGuids" to the project XML. Just add both of the GUIDs featured in the ProjectTypeGuids element below (or add the element if it's not there), and you should be good to go!

<PropertyGroup>
    ...
    <AssemblyName>MyCompany.Technnology</AssemblyName>
    <ProjectTypeGuids>{14822709-B5A1-4724-98CA-57A101D1B079};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
    ...
  </PropertyGroup>

 I'm curious to see if you can add these GUIDs to many types of projects to enable Workflow support (and further curious about if there are any consequences apart from designer support),

Currently rated 5.0 by 3 people

  • Currently 5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

The Very Basics of a Custom ConfigurationSection

Posted by | Filed under , , ,

In my view, the custom configuration API in .NET is one of the most underappreciated tools at a .NET developer's disposal.

 The .NET Framework team made it dirt simple to create configuration extensions that harness the capabilities you're used to. With one simple class, you have all you need to add entries to web.config/app.config and machine.config files, you have rich API's supporting features like XML encryption, and you do it all without any XML parsing logic or file IO!

 At the core, a custom configuration section consists of three pieces:

  1. A class that inherits from System.Configuration.ConfigurationSection (be sure you add a reference to System.Configuration).
  2. A registration of your custom configuration section in configSections element your .NET configuration file.
  3. The XML configuration itself, which you add later in the file.

We'll examine each f these parts seperately, and briefly cover what you need to know about each.

 First, the ConfigurationSection class! In my case, I created an overly simplified section that includes the email address of someone you want to send notifications to.

 In it, you'll want to pay attention to four things. First, data access is handled by ConfigurationManager though of note is that WebConfigurationManager, a web-centric class with extra capabilities, may also be used for web apps. The second thing to note is the path we use to access our configuraiton section, "cSharpConsultant/notifications" in our case. This corresponds to our configuration XML and the configSections entry we make for it.

 Third, notice how we implemented our property via a ConfigurationPropertyAttribute. The "emailAddress" value we use in the attribute works in conjuction with the property getter and setter to access the internally parsed and managed configuraiton value. You'll see later on that "emailAddress" directly relates to an XML attribute in our custom configuration.

 Lastly, see how we can apply validation rules to our property via a RegexStringValidatorAttribute. RegexStringValidator is just one of the many available rules we can apply to our configuration property. The biggest gotcha to note, however, is that the validation rules will run on the default value of a property before they validate the actual value in the configuration file. This means that without a "DefaultValue" set in ConfigurationProperty, our RegexStringValidator would actually run against a blank default value and throw an exception saying "The value does not conform to the validation regex string"!

public class NotificationsConfigurationSection : ConfigurationSection
{
  private const string configPath = "cSharpConsultant/notifications"
  public static NotificationsConfigurationSection GetSection()
  { 
    return (NotificationsConfigurationSection) 
      ConfigurationManager.GetSection(configPath);
  }

  /*This regular expression only accepts a valid email address. */ 
  [RegexStringValidator(@"[\w._%+-]+@[\w.-]+\.\w{2,4}")] 
  /*Here, we register our configuration property with an attribute. 
  Note that the default value is required if we use 
  the property validation attributes, which will unfortunately 
  attempt to validate the initial blank value if a default isn't found*/
  [ConfigurationProperty("emailAddress", DefaultValue=Address@Domain.com)]
  public string EmailAddress
  { 
    get{ return (string)this["emailAddress"]; }
    set{ this["emailAddress"] = value; }
  }
}

 The second part of our setup is to register our configuration class in the file where we want to use the configuration. At the top of all .NET configuration files is a "configSections" element, where we'll register the schema and type of custom ConfigurationSection. Notice how our setup relates to "cSharpConsultant/notifications", the path we used to access our section in the above code.

<configSections> 
  <sectionGroup name="cSharpConsultant">
    <section name="notifications"
        type="ConfigurationSample.NotificationsConfigurationSection,
        ConfigurationSample, Version=1.0.0.0, 
        Culture=neutral, PublicKeyToken=null"/>
</sectionGroup>

Finally, to complete our setup, we need the actual configuration! Notice how the attribute "emailAddress" relates to the ConfigurationProperty value we registered in our custom configuration section's "EmailAddress" property.

<cSharpConsultant>
    <notifications emailAddress="NotifiedPerson@Domain.com"/>
</cSharpConsultant>

 That's it! Now to access our custom configuration, it's as simple as this!

NotificationsConfigurationSection section 
  = NotificationsConfigurationSection.GetSection();
string emailAddress = section.EmailAddress;

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Creating an SPWeb From Its Absolute URI

Posted by | Filed under ,

A collegue of mine recently asked a fairly common question for SharePoint developers getting familiar with the SharePoint API; "If I have the absolute URI of my web, how do I use it to instantiate a corresponding SPWeb object?"

You'd assume that the SPWeb would have a constructor that accepts an absolute URI, but that isn't the case. What you have to do is first create an SPSite using your URI, then call the parameterless OpenWeb() method on it.

string uri = "http://server/site/subsite/web";

//remember your "using" statements so the SPSite and SPWeb are properly disposed
using(SPSite site = new SPSite(uri))
//here, OpenWeb() opens the web corresponding to the URI passed to the SPSite constructor
using (SPWeb web = site.OpenWeb())
{
    //use your web here
}

Currently rated 5.0 by 2 people

  • Currently 5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Worked for Me! iPhone 3G Car Bluetooth Echo and Break Up Solution

Posted by | Filed under , ,

I love my iPhone 3G, but the one major (and I do mean major) issue for me was that there was that when it connected to my 2007 Prius' OEM Bluetooth system, there was an annoying echo and complaints of my voice frequently breaking up (though callers sounded fine to me).

Luckily, the solution was pretty simple in my case:

  1. Initiate a call via your Bluetooth system.
  2. Press the "Volume Up" button on the iPhone 3G until its "Bluetooth Volume" is cranked all the way up.

Voila, virtually no echo and the calls didn't break up any more! The difference was instant and noticeable.

If you have a Toyota, Lexus, BMW, Nissan, Infiniti, Volvo and other make of car and have the same issue, I recommend trying the solution. I used it to fix my echo/break up problem twice (once originally and once after a firmware update reset my Bluetooth volume).

Unfortunately, I discovered that it isn't working for everyone as you can see in the comments below.

 UPDATE: Of note, is that I adjusted my Prius' Bluetooth microphone sensativity before taking the above steps, and John says in his comments below that it helps doing so.

Here's a link that explains how it's done for the Prius: http://priuschat.com/forums/audio-electronics/33443-low-bluetooth-microphone-volume.html. Note that certain settings in diagnostic mode can ruin your car if you're not careful, so just stick to adjusting the Bluetooth mic.

 

Currently rated 2.8 by 6 people

  • Currently 2.833333/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

ZvBox Hands-On Review!

Posted by | Filed under , ,

Introduction

Call me obsessed with getting internet and hard-drive content to my TV, but the day I heard the Apple TV would offer movie rentals from the internet, I not only ordered one but bought a 52" HDTV to go with it! I am ready go digital with movies like I did music back in the 90's since it's so much more convenient! However, as great as the Apple TV is, it and all other media streamers on the market suffer from the same problem: lack of broad format support.

What about the TV I record with Windows Media Center? What about the DVD's I have ripped to my hard drive? What about the streaming media I get from the internet? If I wanted to play all of these, I might need several different devices but then I'd certainly still have to deal with many unsupported formats and websites.

The ZvBox, however, takes a different and very powerful approach that ends up solving the format limitations! It hooks up to your computer and sends whatever is on the monitor to your TV screen (and in HD)! Perfect! If the ZvBox delivers on its promises, it means I will be able to watch my recorded TV, my ripped DVD’s, the movies I downloaded via iTunes and any bit of video I can find on the internet!

Well, I got my eager hands on a demo unit last week, so let’s see how it fared!

Installation

I heard mention elsewhere about how daunting the ZvBox installation was and about the true problems of it not working well with satellite cable, so I was a little worried about the difficulty of setting it up myself. I also worried about and the possibility of screwing my cable service up. Fortunately, I discovered the installation horror stories were overblown and the ZvBox didn’t interfere with my TV, phone or internet services, all of which run over cable.

Contents of the ZvBox Package

Basic hardware installation consists of hooking up a few coax cables, a channel filter near one of your home’s splitters (you’ll need to figure out where they are), and then plugging your monitor into the VGA ports of the ZvBox.

If you’re like me, one of your first questions about the ZvBox is, “Why VGA?”. Many if not most newer computers have moved to the newer DVI or HDMI standards. Well, according to my contact as ZeeVee, the reason is that along with the newer outputs comes DRM. Since VGA is analog, you get around any restrictions.

Unfortunately, what you don’t get around is the fact that a DVI-to-VGA adapter isn’t included with the ZvBox, which the majority of customers will have to purchase separately. Lame! Add another $20 to the price for that omission.

Functionality/User Friendliness

Once performing a channel scan and tuning into the “ZV” channel, a press of a button launches the “Zviewer” interface, which acts as a streamlined portal to sites like Hulu.com, an online service offering ad-supported on-demand movies and TV shows. That feature is a pleasant surprise with the ZvBox! I hadn’t previously used Hulu.com, mostly because I like watching TV on my TV, not my computer monitor (go figure), but since the ZvBox bridges the gap between PC to TV, Hulu is a compelling service that has me questioning if I really need to pay the extra dollars for on-demand cable service. ZvBox gives me a free alternative with a (slightly clumsy) graphical interface and about the same selection!

Screenshot of Zviewer: Hulu.com selction.
Hulu.com movie selection as seen through Zviewer.

MediaCenter interface as seen through ZvBox.
ZvBox broadcasts any PC application like Windows Media Center, which can play recorded TV and ripped DVD's.

The included RF remote (which lets you control your computer from pretty much any room in the house) is mostly familiar in terms of its controls. You have your standard play/pause/rewind buttons, directional arrows to navigate around, the easy-to-overlook “full screen” and “back” buttons for enlarging video and going to the previous screen respectively, and then a feature unique to the remote: an electrostatic touchpad mouse like you’d find on your laptop.

The touchpad is used mostly when you leave the “Zviewer” interface to utilize the “PC-to-TV” functionality that is the primary selling point of the ZvBox. Unfortunately, there is about a half second lag between any computer input and the time it hits your screen, so anytime you have to use the touchpad, it’s a bit of an annoyance. So too is the remote’s method for keyboard input, which simply provides a number pad where you can enter text similar to the way you’d send a text message on the cell phone.

The good news is that it’s usually possible to keep the touchpad and text interaction to a minimum since most of the programs you’ll want to use (iTunes, Windows Media Center, etc.) are supported by the arrow keys and play/pause/rewind buttons. If you want to do something like surf the web, which is more input intensive, you’ll either want the expensive and not-yet-released ZV keyboard, or a Bluetooth keyboard presuming your computer is in Bluetooth range of the TV(s) you want to watch.

I noticed some other quirks with the system, like sometimes having to restart the ZvBox when I restart my computer, but since the ZvBox lets me watch Hulu, iTunes, and my ripped DVD’s and recorded TV in Windows Media Center, I can forgive some of the system’s quirks, especially when much of the important nuance like automatic resolution changes to fit your TV, turning off the screen saver, and diverting audio solely to the TV is handled perfectly.

Performance

The performance of the ZvBox is mixed, but acceptable overall. The resolution is quite good (I could read 6 pt. font in the ZV channel in my experiments), I noticed no skipping (aside from when an overloaded website is buffering video), but I did notice some pixilation in darker scenes and gradients because of the signal compression, as pictured below.

Correctly displayed gradient on monitor. Pixelated gradient generated by ZvBox.
How a gradient looks on a PC monitor. This is the way it should look. How the same gradient looks when localcast via ZvBox. Notice the pixelation near the color transition.
Chronicles of Narnia as viewed through ZvBox localcasting.
'Chronicles of Narnia' looking good when localcasted via ZvBox!

Most of the time you won’t ever notice the issue and the picture looks as great as the pictured ZV channel screenshot of “Chronicles of Narnia”. because of the compression and 720p resolution, however, I wouldn’t recommend streaming 1080p sources like Blu Ray from your computer to the ZvBox.

Also, because of the noted input delay the ZvBox is great for video and music streams, but it’s not meant for gaming or applications requiring fast response to mouse and keyboard actions.



Conclusion

The ZvBox has its warts, but I’ve been waiting for a device that can play all of my media regardless of the source or format. In that regard, the ZvBox delivers! The interface isn’t quite as smooth as other streamers I own, but then it’s not optimized to play only the handful of formats those devices support. The fact that ZvBox lets you stream from Hulu, navigate Windows Media Center, plus support any website, program or file format you can throw at certainly makes it the most versatile media streamer on the market, and if you can get over its quirks and the $500 price tag, I’d recommend it!

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Warning About .NET Framework 3.5 SP1, SQL Server 2008 and WSS 2.0

Posted by | Filed under ,

I got this information through the grapevine. For those using the latest version of the .NET Framework and/or SQL Server 2008, but using the older version of Windows SharePoint Services, this is pretty important.

As a heads up the product team will be updating the System Requirements for WSS v2 to reflect that support for .NET Framework 3.5 and .NET Framework 3.5 SP 1 are not supported on WSS v2.  This would include Visual Studio 2008 SP 1 that includes .NET Framework 3.5 SP 1.

 

Note:  The product team will also be updating system requirements to exclude support for SQL Server 2008 as well since it did not receive exhaustive testing either.  There are no known issues with it so far but the product team feels they need to draw the line on older versions of SharePoint and what they support.

 

Symptoms

If .NET Framework 3.5 SP 1 is installed on WSS v2 the symptoms are:

 

Each web part will display the following error:

 

Web Part Error: A Web Part or Web Form Control on this Web Part Page cannot be displayed or imported because it is not registered on this site as safe.

 

Also, the following NT Events are reported:

 

NT Event Viewer Application Log displays multiple error warnings:

Event ID: 1000

Error initializing Safe control - Assembly: Microsoft.SharePoint, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c TypeName: * Namespace: Microsoft.SharePoint.SoapServer Error: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

 

Due to the fact that .NET Framework 3.5 was not tested thoroughly we are retroactively removing support for it.

 

Workaround:

Workaround:  Uninstall In Add/Remove Programs remove Microsoft .NET Framework 3.5 SP 1 and Microsoft .NET Framework 3.0 and uninstall Microsoft .NET Framework 2.0.  Then reinstall .NET Framework 2.0 Service Pack 1 Download Here.

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Adding a CSS Style & Class To An ASP.NET Page Header

Posted by | Filed under , ,

 There are a variety of techniques out there for wiring up a CSS class to an ASP.NET Web Form through code. You can register a link to a CSS file via Page.Header.Controls.Add() and ASP.NET 2.0 introduced the robust WebResource framework for registering entire style sheets for a given page, but what about when you want to add a dynamic style to the HTML  header?

Typically, the technique would involve something like this:

Page.Header.Controls.Add(
    new LiteralControl(
        @"<style type='text/css'>
                /*type selector*/
                BODY
                {
                    background: Aqua;
                }
                /*class selector*/
                .myClass
                {
                    background: WhiteSmoke;
                    font-size: 20pt;
                }
                </style>
            "

        )
);

...but there are drawbacks to the approach including the need for verbose "style" tags with each chunk of CSS styles you want to add and the lack of validation on style names and values.

Luckily, there's a more sophisticated and elegant approach supported by .NET Framework 2.0 or higher using Page.Header.Stylesheet and the System.Web.UI.WebControls.Style class. With the approach, instead of having to define your CSS class using a string, you can used strongly-typed objects instead! Additionally, all of the styles you add will get added to one single style attribute in the Page header.

Style typeStyle = new Style();
typeStyle.BackColor = Color.Aqua;
Page.Header.StyleSheet.CreateStyleRule(typeStyle, null, "BODY");

Style classStyle = new Style();
classStyle.BackColor = Color.WhiteSmoke;
classStyle.Font.Size = FontUnit.Parse("20pt");
Page.Header.StyleSheet.CreateStyleRule(classStyle, null, ".MyClass");

There is, however, a drawback to the approach which is the limited number of properties available in the Style base class. For instance, if you wanted to set a value for the "margin" CSS style, you'd need to either use or create a subclass of Style that overrides the AddAttributesToRender() method.

Currently rated 4.0 by 1 people

  • Currently 4/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Silverlight 2 Examples and Code Samples from Presentation

Posted by | Filed under ,

As promised, here is the code from last Monday's presentation.

The first of the example applications is a data-entry wizard showcasing dynamic animations, input controls and data binding in Silverlight 2.0. The scenario is that we wanted a new way for the user to enter data in a series of steps that didn't require a series of HTML pages.

A Silverlight 2.0 Wizard Example

You can see it by following this link, and download the code here!

The second application is a mock-video blog that demonstrates the use of markers in video created with Expression Encoder and interaction with the HtmlPage. The idea with this one is that we wanted a way to emphasize advertisement links through animations to increase user interest and, therefore, conversion rates.

A ficticious video blog that promotes the products it reviews.

You can see it by clicking here, and download it by clicking here!

 Also, in reference to the question about passing Silverlight data between pages, someone after the presentation pointed out a very important technique I didn't think to mention, namely the use of isolated storage. Issolated storage is a sandboxed area of the client's file system that you can perform file I/O on from a Silverlight application. Think of it as cookies on steroids: a place where you can read and write information that other domains can't access. It was a very great point I'd be remiss not to mention now!

Thanks to all who attended and participated in the discussion! It was a pleasure getting to present!

*** Now updated from beta for Silverlight 2 release version! ***

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

A Cool Way To Handle ASP.NET Properties Using Nullable Types

Posted by | Filed under , ,

In ASP.NET 1.x, it used to be common to handle the getter of a value type properties thusly:

public int SomeInteger
{
         get
         {
                object val = ViewState["SomeInteger"];
                return val != null ? (int)val : 0;
          }
}

Not bad, but there's more code than needed with nullable types and the "null coalescing operator", anyway. Here's the newer, sleeker way to do the same thing with half the space!

public int SomeInteger
{
         get{ return ViewState["SomeInteger"] as int? ?? 0; }
}

So what's going on in this snippet? Well, we cast the value to a nullable int (int?) which holds a reference to either an int or null then we use the aforementioned ?? operator to return our default value or 0 in the case of null

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5