Bootstrap 3 Datepicker (eonasdan) does not work with jQuery 3.0 or above

if you are developing MVC, and you might have chance to look for a DateTimePicker for your MVC project. One of the favorites DateTimePicker is “Bootstrap 3 DatePicker” developed by Eonasdan (http://eonasdan.github.io/bootstrap-datetimepicker/ ). You may download and get it from Nuget. You may also install by using Bower, Rails, Angular, Meteor or manually. The latest version in Nuget is v4.15.35.1.

nuget_bootstrapdatepicker

One of the dependency is the jQuery. I have installed the latest one jQuery v3.1.1 at the moment I am writing to this blog.

I have followed the sample code Eonasdan has provided but I could not make it working. After some searching, I found out that Eonasdan has developed it when jQuery was still in v2. And jQuery has some changes from v2 to v3. One of the changes is jQuery does not provide the object.count() for jQuery object. It is changed into object.length

So, now you could make some code changes to the bootstrap-datetimepicker.js and the DatePicker will be working again. There are 2 locations of code that you have to change. Just simply search for “count()” and replace it as “length”.

Hope that my blog will help you to fix it. And as I know, someone has also point this out to the GitHub and commit into a new branch. But Eonasdan has not yet merge it into the release branch. Let’s do this fix in our way before he release the fixed code so that we could get a corrected js from Nuget.

bootstrapdatepicker_js_before
bootstrapdatepicker_js_after

NuGet redirection and package retrieval errors in Visual Studio 2015

Yesterday I have experience that I tried to install NuGet Package but an error occurred while retrieving package metadata in Visual Studio 2015.


NugetError.01

After getting some try and catch. I found out that the VS2015 is configured to connect the API v3 of the NuGet.org. So I tried to add another one with the URL on API v2 of the NuGet.org and I am then able to install any NuGet package. So I think that if you hit into the same error, this is a good to try.

NugetSetting.01


NugetSuccess.01

 

Useful links to learn Windows 10 and VS2015

images images
I am sure that you all are new to Win10 and VS2015. You may be looking for learning resource. Here I listed some of the sample site for you and so you could get some learning on these 2 new products.

Opportunity URLs Remarks
Developer Tools Download https://www.visualstudio.com/ Download any Visual Studio skus, including VS 2015
Developer for Windows 10  -What’s New
Get Started
Design
Develop
Publish
https://dev.windows.com/en-us/getstarted/whats-new-windows-10/
https://dev.windows.com/en-us/getstarted/
https://dev.windows.com/en-us/design/
https://dev.windows.com/en-us/develop/
https://dev.windows.com/en-us/publish/
All the info developers may need to write apps
Windows 10 courses in MVA https://www.microsoftvirtualacademy.com/en-US/training-courses/getting-started-with-windows-10-for-it-professionals-10629/ Great site to get online courses on Windows 10
Channel https://channel9.msdn.com/windows/ Another great online resource for Windows 10 related videos
Windows 10 Jumpstart http://www.microsoftvirtualacademy.com/liveevents/preparing-your-enterprise-for-windows-10-as-a-service/ A live event on August 14th

Visual Studio 2015 is released

VS2015.is.born
VS2015.is.born

As many of you might know that VS2015 is already released on 20th July 2015. If you are MSDN Subscriptor, you could download and install it now. For the Team Foundation Server 2015, you might have to wait for a little bit longer.

Watch the keynote on demand below to learn about the latest features and technologies. You can also watch the Visual Studio developer team create an end-to-end solution for an open-source project and see how they tackled problems along the way.

For more Visual Studio 2015 deep dive videos, please visit https://channel9.msdn.com/Series/ConnectOn-Demand

To download Visual Studio 2015, please visit https://www.visualstudio.com/downloads/download-visual-studio-vs

For more information about Visual Studio 2015, please visit https://www.visualstudio.com/vs-2015-product-editions

What is new with Visual Studio 2015 Preview?

Visual Studio 2015 Preview contains many new features, updates to existing features and is further extended with additional releases coming out November 12th , 2014.

Below you’ll find some highlights of features across core categories:

VS2015.Preview
Cross-platform mobile development

  • Tooling for Apache Cordova™ – Visual Studio Tools for Apache Cordova, which were previously released for Visual Studio 2013 are now built into Visual Studio 2015 Preview. With these tools you can create hybrid cross-platform mobile apps that are powered by the Apache Cordova™ framework and work on iOS, Android and Windows, while at the same time taking advantage of the powerful Visual Studio IDE features such as breakpoint debugging, IntelliSense code editors and much more.
  • Visual Studio Emulator for Android – Developers can now download an Emulator for Android that works with Visual Studio 2015 Preview. This new emulator, built by Microsoft is designed to be fast and reliable, easy to install and configure. It also enables developers to easily switch between different platform emulators without Hyper-V conflicts. To learn more and to download the emulator visit com download page.
  • Cross-platform Development using C++ – Developers can now use Visual Studio 2015 to share, reuse, build, deploy, and debug code for use in C++ cross-platform mobile projects. Developers can create projects from templates for Android Native Activity apps, or for shared code libraries that you can use on multiple platforms and in Xamarin native apps.
  • Code Sharing Across Projects – Sharing code is a key component to any cross-platform project, and now developers working on Universal Windows using C# can use Shared Projects to reuse their code in Xamarin native apps, or in other projects such as WPF, ASP.NET and various other project types.

Web & Cloud development

  • NET 5 Preview – Web developers can now use Visual Studio 2015 to create ASP.NET 5 Preview applications, which are built as a lean and composable .NET stack for building modern web applications for both cloud and on-premises servers.
  • Improvements to Add Connected Services – Visual Studio 2015 Preview we’ve created a new capability to simplify the process by which developers connect their apps to cloud-based services such as Azure Storage and Azure Mobile Services, or O365 and even 3rd parties such as Salesforce.
  • Sign-in and view resources for multiple Azure accounts – Visual Studio 2015 Preview enables you to be signed in simultaneously with multiple Azure accounts. View and manage Azure resources associated with those accounts in Server Explorer.
  • Environments hub in Team Explorer – Visual Studio 2015 Preview includes a new Environments hub in Team Explorer. This enables teams to manage Azure environments and share these environments with other team members. Developers can deploy applications to Azure environments from a Cloud Deployment Project, and view resources, logs, and activities related to their environments. For more information on what’s new for cloud developers please see the Azure SDK 2.5 release notes.

IDE productivity

  • Debugging & Diagnostics – Visual Studio 2015 enhances the Breakpoint capabilities with a new setting windows that allows developers to specify conditions and actions for breakpoints, including improved IntelliSense support for breakpoint conditions and actions. Developers also get PerfTips, a new feature to see how long code took to execute right from the code editor. Finally, there is also new support for using Lambda Expression in the debugger windows such as Watch and Immediate.
  • Code Editor – Visual Studio 2015 built on top of .NET Compiler Platform (“Roslyn”) brings many new features and improvements to existing capabilities to the code editor. This includes new light bulbs for quick action access to common commands such as refactoring code, including a new enhanced preview of how the code will be effected. We’ve also added refactoring support for Visual Studio, as part of Light Bulbs enhancement.
  • Code Analysis & Testing – Visual Studio 2015 now supports a new enhanced live code analysis capabilities, along with code analysis extensibility to 3rd party library developers through NuGet packages. With this enhancements developer get live code, advising them of issues as they type code without having to rebuild the project. In addition when NuGet libraries are extended to provide specific code-aware guidance, the editor will also light-up those changes as if they were built-in, helping solve problems early in the development lifecycle. We’ve also added a new feature called Smart Unit Testing (formerly PEX from Microsoft Research), which will explore your .NET code to generate test data and a suite of unit tests automatically.
  • Visual Studio IDE – The Visual Studio 2015 IDE has been enhanced to better support high-resolution displays with new icons in locations such as command bar, tool window toolbars and many other locations. We’ve also added touch support to the code editor, which can handle touch commands and gestures such as scrolling, tapping, pinch-to-zoom, etc.

To see the full details on what’s new in Visual Studio 2015 Preview please visit  release notes.