If you want to dynamically set the end year as per the current year, you can do it in the following way.
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js" type = "text/javascript"></script>
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js" type = "text/javascript"></script>
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel = "Stylesheet" type="text/css" /> 
<script type = "text/javascript">
    $(function () {
            changeMonth: true,
            changeYear: true,
            yearRange: '1950:' + new Date().getFullYear().toString()
<input type = "text" id = "txtDate" />
In the above code snippet the only difference is that I am detecting the end year using the JavaScript date library getFullYear method.