Using Stylesheet, JavaScript Scripts for WordPress Widget

CSS and Javascript Scripts for Widgets can be used based on widget availability. If you have created a custom widget and need to load stylesheet only if it active on front end, you will have to use is_active_widget WordPress function right after parent::__construct method has been called.

class MY_Custom_Widget extends WP_Widget {
	function __construct(){
		$widget_ops = array('classname' => 'MY_Custom_Widget', 'description' => __( 'MY_Custom_Widget') );
		parent::__construct('MY_Custom_Widget', __('MY_Custom_Widget'), $widget_ops);
	}
	if ( is_active_widget( false, false, $this->id_base, true ) ) {
		wp_enqueue_script( 'jquery' );
		wp_enqueue_style( 'something', 'stylesheet_url' ); 
	}
	// rest of the widget codes
}

Now for using Scripts for Widget outside of the Widget class, ex: loading stylesheet for calendar widget, you just need to figure out the widget unique id.

add_action('wp_head', 'load_calendar_scripts');
function load_calendar_scripts(){
	if ( is_active_widget( false, false, 'calendar', true ) ) {
		wp_enqueue_script( 'jquery' );
		wp_enqueue_style( 'something', 'stylesheet_url' ); 
	}
}

Discussion