text:
Q: Getting started with Wt (Witty) in VS2013 I have installed Wt-3.3.5-rc2-msvs2013-Windows-x86-SDK with installer from http://sourceforge.net/projects/witty/files/wt/3.3.5/ and I'm trying to build the first solution from here http://andres.jaimes.net/780/how-to-create-a-first-application-using-wt-witty/ and have done the points from "In order to successfully compile any of these applications you have to let your compiler know about the additional include and lib folders and files." But still I get this kind of errors, any idea, why?
1>------ Build started: Project: hello, Configuration: Debug Win32 ------
1>  main.cpp
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\http\request(83): warning C4251: 'Wt::Http::UploadedFile::fileInfo_' : class 'boost::shared_ptr<Wt::Http::UploadedFile::Impl>' needs to have dll-interface to be used by clients of class 'Wt::Http::UploadedFile'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\http\request(414): warning C4251: 'Wt::Http::Request::cookies_' : class 'std::map<std::string,std::string,std::less<_Kty>,std::allocator<std::pair<const _Kty,_Ty>>>' needs to have dll-interface to be used by clients of class 'Wt::Http::Request'
1>          with
1>          [
1>              _Kty=std::string
1>  ,            _Ty=std::string
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wobject(242): warning C4275: non dll-interface class 'boost::signals2::trackable' used as base for dll-interface class 'Wt::WObject'
1>          c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\boost\signals2\trackable.hpp(38) : see declaration of 'boost::signals2::trackable'
1>          c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wobject(241) : see declaration of 'Wt::WObject'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wobject(516): warning C4251: 'Wt::WObject::statelessSlots_' : class 'std::vector<Wt::WStatelessSlot *,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WObject'
1>          with
1>          [
1>              _Ty=Wt::WStatelessSlot *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wobject(520): warning C4251: 'Wt::WObject::name_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WObject'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wobject(531): warning C4251: 'Wt::WObject::emptyObjectList_' : class 'std::vector<Wt::WObject *,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WObject'
1>          with
1>          [
1>              _Ty=Wt::WObject *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wobject(540): warning C4251: 'Wt::WObject::trackable_ptr_' : class 'boost::shared_ptr<T>' needs to have dll-interface to be used by clients of class 'Wt::WObject'
1>          with
1>          [
1>              T=int
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wstring(532): warning C4251: 'Wt::WString::utf8_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WString'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wstring(546): warning C4251: 'Wt::WString::stArguments_' : class 'std::vector<Wt::WString,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WString'
1>          with
1>          [
1>              _Ty=Wt::WString
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wanimation(173): warning C4251: 'Wt::WAnimation::effects_' : class 'Wt::WFlags<Wt::WAnimation::AnimationEffect>' needs to have dll-interface to be used by clients of class 'Wt::WAnimation'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wsignal(572): warning C4251: 'Wt::EventSignalBase::connections_' : class 'std::vector<Wt::EventSignalBase::StatelessConnection,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::EventSignalBase'
1>          with
1>          [
1>              _Ty=Wt::EventSignalBase::StatelessConnection
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wsignal(573): warning C4251: 'Wt::EventSignalBase::flags_' : class 'std::bitset<7>' needs to have dll-interface to be used by clients of class 'Wt::EventSignalBase'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wsignal(580): warning C4251: 'Wt::EventSignalBase::dummy_' : class 'boost::signals2::signal<void (void),boost::signals2::optional_last_value<void>,int,std::less<Group>,boost::function<Signature>,boost::function<R (const boost::signals2::connection &)>,boost::signals2::mutex>' needs to have dll-interface to be used by clients of class 'Wt::EventSignalBase'
1>          with
1>          [
1>              Group=int
1>  ,            Signature=void (void)
1>  ,            R=void
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(89): warning C4251: 'Wt::JavaScriptEvent::modifiers' : class 'Wt::WFlags<Wt::KeyboardModifier>' needs to have dll-interface to be used by clients of class 'Wt::JavaScriptEvent'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(92): warning C4251: 'Wt::JavaScriptEvent::touches' : class 'std::vector<Wt::Touch,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::JavaScriptEvent'
1>          with
1>          [
1>              _Ty=Wt::Touch
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(92): warning C4251: 'Wt::JavaScriptEvent::targetTouches' : class 'std::vector<Wt::Touch,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::JavaScriptEvent'
1>          with
1>          [
1>              _Ty=Wt::Touch
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(92): warning C4251: 'Wt::JavaScriptEvent::changedTouches' : class 'std::vector<Wt::Touch,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::JavaScriptEvent'
1>          with
1>          [
1>              _Ty=Wt::Touch
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(101): warning C4251: 'Wt::JavaScriptEvent::type' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::JavaScriptEvent'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(104): warning C4251: 'Wt::JavaScriptEvent::tid' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::JavaScriptEvent'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(106): warning C4251: 'Wt::JavaScriptEvent::response' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::JavaScriptEvent'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(108): warning C4251: 'Wt::JavaScriptEvent::userEventArgs' : class 'std::vector<std::string,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::JavaScriptEvent'
1>          with
1>          [
1>              _Ty=std::string
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wevent(435): warning C4251: 'Wt::WDropEvent::dropMimeType_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WDropEvent'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wexception(42): warning C4251: 'Wt::WException::what_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WException'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wstringstream(210): warning C4251: 'Wt::WStringStream::bufs_' : class 'std::vector<std::pair<char *,int>,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WStringStream'
1>          with
1>          [
1>              _Ty=std::pair<char *,int>
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wlogger(227): warning C4251: 'Wt::WLogger::fields_' : class 'std::vector<Wt::WLogger::Field,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WLogger'
1>          with
1>          [
1>              _Ty=Wt::WLogger::Field
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wlogger(235): warning C4251: 'Wt::WLogger::rules_' : class 'std::vector<Wt::WLogger::Rule,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WLogger'
1>          with
1>          [
1>              _Ty=Wt::WLogger::Rule
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wjavascript(387): warning C4251: 'Wt::JSignal<Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass>::name_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::JSignal<Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass>'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wjavascript(387): warning C4251: 'Wt::JSignal<Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass>::senderId_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::JSignal<Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass>'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wwidget(1236): warning C4251: 'Wt::WWidget::flags_' : class 'std::bitset<6>' needs to have dll-interface to be used by clients of class 'Wt::WWidget'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wwidget(1238): warning C4251: 'Wt::WWidget::eventSignals_' : class 'std::list<Wt::EventSignalBase *,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WWidget'
1>          with
1>          [
1>              _Ty=Wt::EventSignalBase *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wwebwidget(387): warning C4251: 'Wt::WWebWidget::elementTagName_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WWebWidget'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wwebwidget(390): warning C4251: 'Wt::WWebWidget::AllChangeFlags' : class 'std::bitset<31>' needs to have dll-interface to be used by clients of class 'Wt::WWebWidget'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wwebwidget(398): warning C4251: 'Wt::WWebWidget::flags_' : class 'std::bitset<31>' needs to have dll-interface to be used by clients of class 'Wt::WWebWidget'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wwebwidget(503): warning C4251: 'Wt::WWebWidget::emptyWidgetList_' : class 'std::vector<Wt::WWidget *,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WWebWidget'
1>          with
1>          [
1>              _Ty=Wt::WWidget *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wlink(186): warning C4251: 'Wt::WLink::value_' : class 'boost::variant<std::string,Wt::WResource *,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_,boost::detail::variant::void_>' needs to have dll-interface to be used by clients of class 'Wt::WLink'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssdecorationstyle(216): warning C4251: 'Wt::WCssDecorationStyle::cursorImage_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WCssDecorationStyle'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssdecorationstyle(222): warning C4251: 'Wt::WCssDecorationStyle::backgroundImageLocation_' : class 'Wt::WFlags<Wt::Side>' needs to have dll-interface to be used by clients of class 'Wt::WCssDecorationStyle'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssdecorationstyle(224): warning C4251: 'Wt::WCssDecorationStyle::textDecoration_' : class 'Wt::WFlags<Wt::WCssDecorationStyle::TextDecoration>' needs to have dll-interface to be used by clients of class 'Wt::WCssDecorationStyle'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssstylesheet(78): warning C4251: 'Wt::WCssRule::selector_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WCssRule'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssstylesheet(286): warning C4251: 'Wt::WCssStyleSheet::media_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WCssStyleSheet'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssstylesheet(288): warning C4251: 'Wt::WCssStyleSheet::rules_' : class 'std::vector<Wt::WCssRule *,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WCssStyleSheet'
1>          with
1>          [
1>              _Ty=Wt::WCssRule *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssstylesheet(289): warning C4251: 'Wt::WCssStyleSheet::rulesAdded_' : class 'std::vector<Wt::WCssRule *,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WCssStyleSheet'
1>          with
1>          [
1>              _Ty=Wt::WCssRule *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssstylesheet(291): warning C4251: 'Wt::WCssStyleSheet::rulesModified_' : class 'std::set<Wt::WCssRule *,std::less<_Kty>,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WCssStyleSheet'
1>          with
1>          [
1>              _Kty=Wt::WCssRule *
1>  ,            _Ty=Wt::WCssRule *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssstylesheet(292): warning C4251: 'Wt::WCssStyleSheet::rulesRemoved_' : class 'std::vector<std::string,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WCssStyleSheet'
1>          with
1>          [
1>              _Ty=std::string
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcssstylesheet(294): warning C4251: 'Wt::WCssStyleSheet::defined_' : class 'std::set<std::string,std::less<_Kty>,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WCssStyleSheet'
1>          with
1>          [
1>              _Kty=std::string
1>  ,            _Ty=std::string
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wlocale(233): warning C4251: 'Wt::WLocale::name_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WLocale'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wlocale(234): warning C4251: 'Wt::WLocale::decimalPoint_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WLocale'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wlocale(234): warning C4251: 'Wt::WLocale::groupSeparator_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WLocale'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wlocale(237): warning C4251: 'Wt::WLocale::time_zone_' : class 'boost::shared_ptr<tz_type>' needs to have dll-interface to be used by clients of class 'Wt::WLocale'
1>          with
1>          [
1>              tz_type=boost::date_time::time_zone_base<boost::posix_time::ptime,char>
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wmessageresourcebundle(171): warning C4251: 'Wt::WMessageResourceBundle::messageResources_' : class 'std::vector<Wt::WMessageResources *,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WMessageResourceBundle'
1>          with
1>          [
1>              _Ty=Wt::WMessageResources *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2161): warning C4251: 'Wt::WApplication::requestTooLarge_' : class 'Wt::Signal<int64_t,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2203): warning C4251: 'Wt::WApplication::weakSession_' : class 'boost::weak_ptr<Wt::WebSession>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2215): warning C4251: 'Wt::WApplication::renderedInternalPath_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2215): warning C4251: 'Wt::WApplication::newInternalPath_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2216): warning C4251: 'Wt::WApplication::internalPathChanged_' : class 'Wt::Signal<std::string,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2216): warning C4251: 'Wt::WApplication::internalPathInvalid_' : class 'Wt::Signal<std::string,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass,Wt::NoClass>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2224): warning C4251: 'Wt::WApplication::javaScriptClass_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2234): warning C4251: 'Wt::WApplication::htmlClass_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2234): warning C4251: 'Wt::WApplication::bodyClass_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2240): warning C4251: 'Wt::WApplication::focusId_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2244): warning C4251: 'Wt::WApplication::scriptLibraries_' : class 'std::vector<Wt::WApplication::ScriptLibrary,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Ty=Wt::WApplication::ScriptLibrary
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2248): warning C4251: 'Wt::WApplication::styleSheets_' : class 'std::vector<Wt::WCssStyleSheet,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Ty=Wt::WCssStyleSheet
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2249): warning C4251: 'Wt::WApplication::styleSheetsToRemove_' : class 'std::vector<Wt::WCssStyleSheet,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Ty=Wt::WCssStyleSheet
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2253): warning C4251: 'Wt::WApplication::metaHeaders_' : class 'std::vector<Wt::MetaHeader,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Ty=Wt::MetaHeader
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2254): warning C4251: 'Wt::WApplication::metaLinks_' : class 'std::vector<Wt::WApplication::MetaLink,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Ty=Wt::WApplication::MetaLink
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2256): warning C4251: 'Wt::WApplication::exposedSignals_' : class 'std::map<std::string,Wt::EventSignalBase *,std::less<_Kty>,std::allocator<std::pair<const _Kty,_Ty>>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Kty=std::string
1>  ,            _Ty=Wt::EventSignalBase *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2257): warning C4251: 'Wt::WApplication::exposedResources_' : class 'std::map<std::string,Wt::WResource *,std::less<_Kty>,std::allocator<std::pair<const _Kty,_Ty>>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Kty=std::string
1>  ,            _Ty=Wt::WResource *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2258): warning C4251: 'Wt::WApplication::encodedObjects_' : class 'std::map<std::string,Wt::WObject *,std::less<_Kty>,std::allocator<std::pair<const _Kty,_Ty>>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Kty=std::string
1>  ,            _Ty=Wt::WObject *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2260): warning C4251: 'Wt::WApplication::justRemovedSignals_' : class 'std::set<std::string,std::less<_Kty>,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Kty=std::string
1>  ,            _Ty=std::string
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2265): warning C4251: 'Wt::WApplication::afterLoadJavaScript_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2265): warning C4251: 'Wt::WApplication::beforeLoadJavaScript_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2267): warning C4251: 'Wt::WApplication::autoJavaScript_' : class 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2271): warning C4251: 'Wt::WApplication::javaScriptPreamble_' : class 'std::vector<Wt::WJavaScriptPreamble,std::allocator<_Ty>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Ty=Wt::WJavaScriptPreamble
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2276): warning C4251: 'Wt::WApplication::javaScriptLoaded_' : class 'std::set<const char *,std::less<_Kty>,std::allocator<_Kty>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Kty=const char *
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2279): warning C4251: 'Wt::WApplication::showLoadingIndicator_' : class 'Wt::EventSignal<Wt::NoClass>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2279): warning C4251: 'Wt::WApplication::hideLoadingIndicator_' : class 'Wt::EventSignal<Wt::NoClass>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wapplication(2282): warning C4251: 'Wt::WApplication::objectStore_' : class 'std::map<const char *,boost::any,std::less<_Kty>,std::allocator<std::pair<const _Kty,_Ty>>>' needs to have dll-interface to be used by clients of class 'Wt::WApplication'
1>          with
1>          [
1>              _Kty=const char *
1>  ,            _Ty=boost::any
1>          ]
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcontainerwidget(367): warning C4251: 'Wt::WContainerWidget::flags_' : class 'std::bitset<8>' needs to have dll-interface to be used by clients of class 'Wt::WContainerWidget'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wcontainerwidget(368): warning C4251: 'Wt::WContainerWidget::contentAlignment_' : class 'Wt::WFlags<Wt::AlignmentFlag>' needs to have dll-interface to be used by clients of class 'Wt::WContainerWidget'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wtext(268): warning C4251: 'Wt::WText::text_' : struct 'Wt::WText::RichText' needs to have dll-interface to be used by clients of class 'Wt::WText'
1>          c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wtext(256) : see declaration of 'Wt::WText::RichText'
1>c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\wt\wtext(280): warning C4251: 'Wt::WText::flags_' : class 'std::bitset<9>' needs to have dll-interface to be used by clients of class 'Wt::WText'
1>c:\program files (x86)\microsoft visual studio 12.0\vc\include\xmemory(348): error C4996: 'std::_Uninitialized_copy0': Function call with parameters that may be unsafe - this call relies on the caller to check that the passed values are correct. To disable this warning, use -D_SCL_SECURE_NO_WARNINGS. See documentation on how to use Visual C++ 'Checked Iterators'
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\xmemory(333) : see declaration of 'std::_Uninitialized_copy0'
1>          c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\boost\signals2\detail\auto_buffer.hpp(191) : see reference to function template instantiation '_FwdIt std::uninitialized_copy<I,boost::shared_ptr<void>*>(_InIt,_InIt,_FwdIt)' being compiled
1>          with
1>          [
1>              _FwdIt=boost::shared_ptr<void> *
1>  ,            I=boost::shared_ptr<void> *
1>  ,            _InIt=boost::shared_ptr<void> *
1>          ]
1>          c:\program files (x86)\wt 3.3.5 msvs2013 x86\include\boost\signals2\detail\auto_buffer.hpp(178) : see reference to function template instantiation 'void boost::signals2::detail::auto_buffer<boost::shared_ptr<void>,boost::signals2::detail::store_n_objects<10>,boost::signals2::detail::default_grow_policy,std::allocator<T>>::copy_rai<I,false>(I,I,boost::shared_ptr<void> *,const boost::integral_constant<bool,false> &)' being compiled
1>          with
1>          [
1>              T=boost::shared_ptr<void>
1>  ,            I=boost::shared_ptr<void> *
1>          ]

A: Background
You have to make a distinction between errors and warnings. At the moment I only read one error in your log.
So, because one can not compile as long there is a least one error, we have to look at it. Also you have a ton of warnings, but as all warnings, they won't prevent compiling. But as any warning, you should be aware of them.
About the warnings
I get these warnings too, but since it seems that they are generated by a not 100% compliant use of the DLL API by Wt, windows way of shared linking. So IMHO they can be ignored, without much to worry.
About the one error
The one error you got, is basically a warning, because Microsoft likes to assume, that you're a dump developer and complains that using a function in C++, could be unsafe (called SDL). But since almost everything in the whole C++ language is "unsafe", C++ heavily relies on you to be a reasonable developer. (One could put more opinion in here about this :-)).
That's the reason why I think you can ignore this warning, also because it's Wts "fault".
Solution
You have to options to deal with it

*

*Degrade that one type of "error" to a warning by either define the preprocessor macro _SCL_SECURE_NO_WARNINGS, probably in the project settings.

*Disable all SDL checks, so you won't be bothered by errors and warnings, which are most the time, not indicating wrong language usage. (I recommend this, unless you like Visual Basic and think windows is the best OS, but then I would also recommend to not use C++ :-) )


text:
Q: Django form values not inserted in sqlite3 database tables I am a newbie in web development using Django.
I have created 3 models and correspondingly their forms. Even makemigrations and migrate commands did not report any problem and tables are also created in the SQLite DB file.
But still, values are not getting inserted in the DB file.
Empty QuerySet is getting received i.e. <QuerySet []>.
Could anyone please let me know why values do not get inserted? Thanks in advance.
The program snippet:-
model.py
class User(models.Model):

    name = models.CharField(max_length=100, default='ABC')
    password = models.CharField(max_length=50, default='ABC')

    def __str__(self):
        print("self.name:", self.name)
        return self.name

class Faculty_Info(models.Model):

    fid = models.IntegerField(default='123')
    fname = models.CharField(max_length=50, default="ABC")
    femail = models.EmailField(max_length=50, default='abc@gmail.com')
    fcontact = models.IntegerField(default='123')
    faddress = models.TextField(max_length=50, default='ABC')
    fsalary = models.IntegerField(default='123')

    def __str__(self):
        return self.fname

class Student_Info(models.Model):

    sid = models.IntegerField(default='123')
    sname = models.CharField(max_length=50, default='ABC')
    semail = models.EmailField(max_length=50, default='abc@gmail.com')
    scontact = models.IntegerField(default='123')
    saddress = models.TextField(max_length=50, default='ABC')

    def __str__(self):
        return self.sname

views.py
def faculty_info_section(request):
    faculties = Faculty_Info.objects.all()
    print("faculties", faculties)
    return render(request, "faculty_info_section.html", {'faculties': faculties})

def add_faculty(request):
    if request.method == "POST":
        faculty_form = Faculty_Info_Form(request.POST)
        print("faculty_form", faculty_form)
        if faculty_form.is_valid():
            try:
                faculty_form.save()
                print("faculty_form:", faculty_form)
                return redirect('/faculty_info_section')
            except:
                pass
    else:
        faculty_form = Faculty_Info_Form()
    print("faculty_form_2", faculty_form)
    return render(request, 'add_faculty.html', {'faculty_form': faculty_form})

faculty_info_section.html
    {% for faculty in faculties %}

        {{ faculty.fid }}
        {{ faculty.fname }}
        {{ faculty.femail }}
        {{ faculty.fcontact }}
        {{ faculty.faddress }}
        {{ faculty.fsalary }}

            Edit
            Delete

{% endfor %}

forms.py
from django import forms
from django.forms import Textarea

from School.models import User, Faculty_Info, Student_Info

class UserLoginForm(forms.ModelForm):
    class Meta:
        model = User
        fields = "__all__"

class Faculty_Info_Form(forms.ModelForm):
    class Meta:
        model = Faculty_Info
        widgets = {
            'fid': Textarea(attrs={'cols': 30, 'rows': 2}),
            'fname': Textarea(attrs={'cols': 30, 'rows': 2}),
            'femail': Textarea(attrs={'cols': 30, 'rows': 2}),
            'fcontact': Textarea(attrs={'cols': 30, 'rows': 2}),
            'faddress': Textarea(attrs={'cols': 30, 'rows': 2}),
            'fsalary': Textarea(attrs={'cols': 30, 'rows': 2}),
        }
        fields = "__all__"

class Student_Info_Form(forms.ModelForm):
    class Meta:
        model = Student_Info
        widgets = {
            'sid': Textarea(attrs={'cols': 30, 'rows': 2}),
            'sname': Textarea(attrs={'cols': 30, 'rows': 2}),
            'semail': Textarea(attrs={'cols': 30, 'rows': 2}),
            'scontact': Textarea(attrs={'cols': 30, 'rows': 2}),
            'saddress': Textarea(attrs={'cols': 30, 'rows': 2}),
        }
        fields = "__all__"

Please help, Thanks in advance.

redpajama_set_name: RedPajamaStackExchange


text:
Q: Can I use "It helps having a good imagination" instead of "It helps to have..."? In this sentence, can I also say "It helps having a good imagination"?

It helps to have a good imagination, and I am completely delusional.
  —— Hoult (A movie director)

Which usage would be better?

A: You can say that provided the listener/reader knows the context you are talking about. However, the COCAE shows that 'helps to have' is more frequently used as compared to 'helps having'.
We should carefully use the verbs as they have particular verb pattern that decides whether a verb would be followed by a gerund or an infinitive. The given link (of a post and not COCAE here) gives better idea to use them.
The sentence with the verb help and an object.
The above sentence does not have object or else it could have been the verb help followed by an object before the infinitive verb. In addition, the verb help is also a causative verb and thus can also be followed by a simple form (no to or -ing)

It helps me have a good imagination OR
  It helps me to have a good imagination.

Additional info: If it's can't help, it takes the gerund (-ing).


text:
Q: Swing JMenuItem - Icons not showing up I'm following the Zetcode tutorial on Java Swing; in this section it is explained how to create a menu, including how to add icons to the various menu elements.
Unfortunately, the icons do not show up when I run the code in Eclipse, despite I just reproduce the same code from there and I do not get any compile-time error.
I've already tried to have a look at the Oracle tutorial but I can't understand where the problem is; maybe somebody can help me?


text:
Q: Postgresql keeps throwing syntax error on FILTER I have made this query that compares 2 result
SELECT ROUND((COUNT(*)::decimal/(SELECT COUNT(*) FROM dashboard.event WHERE cast(event_start_adj AS DATE) = '2020-04-05')*100),2)
FROM dashboard.event
WHERE cast(event_start_adj AS DATE) = '2020-04-05'
AND planned = 'PLANNED'
GROUP BY planned'

The query above outputs 47.30 for the PLANNED Column while the next query outputs 52.70:
SELECT ROUND((COUNT(*)::decimal/(SELECT COUNT(*) FROM dashboard.event WHERE cast(event_start_adj AS DATE) = '2020-04-05')*100),2)
FROM dashboard.event
WHERE cast(event_start_adj AS DATE) = '2020-04-05'
AND planned = 'UNPLANNED'
GROUP BY planned

And this is the query I have made to compare the result of these 2 and make the column PLANNED and UNPLANNED become row:
SELECT
   unnest(array['colPlanned', 'colUnplanned']) AS months,
   unnest(array[col_planned, col_unplanned]) AS values
FROM(
    SELECT
        ROUND((
            COUNT(*)::decimal / (
                SELECT COUNT(*) FROM dashboard.event WHERE cast(event_start_adj AS DATE) = '2020-04-05') * 100)
              FILTER (WHERE cast(event_start_adj AS DATE) = '2020-04-05' AND planned = 'PLANNED'),2) AS col_planned,
        ROUND((
            COUNT(*)::decimal / (
                SELECT COUNT(*) FROM dashboard.event WHERE cast(event_start_adj AS DATE) = '2020-04-05') * 100)
              FILTER (WHERE cast(event_start_adj AS DATE) = '2020-04-05' AND planned = 'UNPLANNED'),2) AS col_unplanned
    FROM dashboard.event
    )t

Postgresql keeps throwing me a syntax error but upon checking all of my opening and closing () is okay.
Is there something I'm missing?
The error shown:

UPDATE:
Seems it's hard to ask this kind of question without giving a data, so I have made these query to show what i'm computing:
SELECT COUNT(*),(SELECT COUNT(*) FROM dashboard.event WHERE cast(event_start_adj AS DATE) = '2020-04-05'), ROUND((COUNT(*)::decimal/(SELECT COUNT(*) FROM dashboard.event WHERE cast(event_start_adj AS DATE) = '2020-04-05')*100),2)
FROM dashboard.event
WHERE cast(event_start_adj AS DATE) = '2020-04-05'
AND planned = 'PLANNED'

The above query outputs these:

The formula is basically getting the percentage of planned/unplanned that have occured on that day.
'((planned count or unplanned count) / overall_planned_count) * 100)'

is the formula i've created.
Now I can just run these query:
SELECT ROUND((COUNT(*)::decimal/(SELECT COUNT(*) FROM dashboard.event WHERE cast(event_start_adj AS DATE) = '2020-04-05')*100),2)
FROM dashboard.event
WHERE cast(event_start_adj AS DATE) = '2020-04-05'
AND planned = 'UNPLANNED'
GROUP BY planned

To get the result for the UNPLANNED but the problem is that i also need to get the result for the PLANNED. I can also run them both but the problem will be  they will be columned like this:
col_planned         col_unplanned
____________       _______________
47.30                52.70

But i needed the it to become a row not column and look like these:
col_this              result
____________       _______________
 unplanned           52.70
planned              47.30

That's why the query i've created is creating a dummy row but the problem is the syntax error that it's throwing.

A: As far as I can tell, you can simplify your query to this:
SELECT count(*) filter (where planned = 'PLANNED') / count(*)::decimal    as planned,
       count(*) filter (where planned = 'UNPLANNED') / count(*)::decimal  as unplanned
FROM dashboard.event
WHERE cast(event_start_adj AS DATE) = '2020-04-05'

I left out the round() part to focus on the actual query, but you can easily add that in
If you have an index on event_start_adj the above condition will not be able to use it. You will need to rewrite it to:
WHERE event_start_adj >= DATE '2020-04-05'
  AND event_start_adj < DATE '2020-04-06'

A: I think your code would be more simply written using conditional aggregation:
SELECT avg( (planned = 'PLANNED')::int ) as planned,
       avg( (planned = 'UNPLANNED')::int ) as unplanned
FROM dashboard.event
WHERE event_start_adj >= '2020-04-05'::date AND
      event_start_adj < '2020-04-05'::date + interval '1 day' ;

Note I changed the date comparisons to be more index compatible.
EDIT:
If you want the values in rows, it is just as simple:
SELECT planned, COUNT(*) * 1.0 / SUM(COUNT(*)) OVER () as ratio
FROM dashboard.event
WHERE event_start_adj >= '2020-04-05'::date AND
      event_start_adj < '2020-04-05'::date + interval '1 day'
GROUP BY planned;


text:
Q: Issue with snapped view metro app Hey Guys Please Help To Sort out My Problem , i have made an app and i have to upload it on windows store but the problem is that it does not support snapped view. I want that it should not work in snapped view, when the app enters in snapped view it just display a message " Switch To Full Screen ". Please tell me how to code for that and where to code in XAML or XAML.cs. Thanks in Advance.

A: One of the possible solutions

*

*Create a new page which you would want to use for Snap

*Listen to the event which is raised when the user snaps the app.

*Navigate to that page which has "Switch to Full Screen"

*Listen to the event which is raised when the user unsnaps

*Go back to the original page

To achieve this,
In your App.xaml.cs in the OnLaunched event write this
 Window.Current.SizeChanged += Current_SizeChanged;

Now for the event handler
 void Current_SizeChanged(object sender, Windows.UI.Core.WindowSizeChangedEventArgs e)
    {
        ApplicationViewState viewState = ApplicationView.Value;
       if (viewState == ApplicationViewState.Snapped)
        {
            //Navigate to the new common snap page
        }
      else{
              //Write the code to check if the previous state was snapped and then navigate back
        }
   }

A: Add a Basic Page and replace XAML with this:
<common:LayoutAwarePage
    x:Name="pageRoot"
    x:Class="App1.OopsPage"
    DataContext="{Binding DefaultViewModel, RelativeSource={RelativeSource Self}}"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:App1"
    xmlns:common="using:App1.Common"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d">

    <Grid>
        <!-- Full screen content. -->
        <Grid x:Name="FullScreenGrid">
            <TextBlock>Here is your content.</TextBlock>
        </Grid>

        <!-- Snapped view content. -->
        <Grid x:Name="SnappedViewGrid" Visibility="Collapsed">
            <TextBlock>Please go back to full screen :(</TextBlock>
        </Grid>

        <VisualStateManager.VisualStateGroups>

            <!-- Visual states reflect the application's view state -->
            <VisualStateGroup x:Name="ApplicationViewStates">
                <VisualState x:Name="FullScreenLandscape"/>
                <VisualState x:Name="Filled"/>
                <VisualState x:Name="FullScreenPortrait" />

                <!-- The back button and title have different styles when snapped -->
                <VisualState x:Name="Snapped">
                    <Storyboard>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="FullScreenGrid" Storyboard.TargetProperty="Visibility">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="Collapsed"/>
                        </ObjectAnimationUsingKeyFrames>
                        <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SnappedViewGrid" Storyboard.TargetProperty="Visibility">
                            <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                        </ObjectAnimationUsingKeyFrames>
                    </Storyboard>
                </VisualState>
            </VisualStateGroup>
        </VisualStateManager.VisualStateGroups>
    </Grid>
</common:LayoutAwarePage>

Make sure to replace App1 with your app namespace and you must have LayoutAwarePage.cs in your Common folder.


text:
Q: Cassandra opscenter is not communicating with cluster I have 2 node Cassandra cluster with datastax-agent up and running(one seed node) also nodetool status showing healthy.
In the 3 node I have opscenter install and the UI is loading fine with a blank screen, when I saw the var log it's complaining 'NO cassandra connection available for hostlist with a invalid unsupported version'(paster the log details message below). Any help is highly appreciated

2017-02-25 06:33:06+0000 [CLUSTER_NAME] ERROR: Control connection failed to connect, shutting down Cluster: ('Unable to connect to any servers', {'SEED-IP': })
  2017-02-25 06:33:06+0000 [CLUSTER_NAME]  WARN: No cassandra connection available for hostlist ['SEED-IP'] .  Retrying.

A: I was using an old version of opscenter which was not matching the version of dse. Here is the map for your refference.

Reference: datastax doc


text:
Q: Sitecore GEO IP I have an environment where a few Sitecore servers are behind a firewall & the reverse proxy in different AWS-VPCs (internet & intranet) with AWS Gateway. I need Geo-IP to be enabled and updated to the Sitecore host node for the device analytics dashboard (access via intranet or internet). Any possible suggestion? Thank you.

A: Reverse proxies typically forward the IP address from the connecting client via an additional http header X-Forwarded-For. See also https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For . You might need to enable this on AWS, I'm unfamiliar with their services.
However, also on the Sitecore end, you then need to enable reading of the header. This has been support for quite a while, and the documentations seems to have changed barely (if at all) since version 9.0:
https://doc.sitecore.com/xp/en/developers/90/sitecore-experience-manager/set-up-sitecore-ip-geolocation.html
The interesting bits are at the bottom, though:

When requests come from a reverse proxy server to your Sitecore instance that you want to track as the valid IP addresses of a client (not as the IP addresses of a proxy), use the following setting.

*

*In Sitecore.Analytics.Tracking.config change the Analytics.ForwardedRequestHttpHeader setting to the value: X-Forwarded-For


text:
Q: Equivariant K-theory for products of groups? Let $X$ be a $(G \times H)$-space. What is known about the connection between the groups $K_G(X)$, $K_H(X)$ and $K_{G \times H}(X)$? The $G$ and $H$ action on $X$ come from the canonical inclusions $G \to G \times H$ and $H \to G \times H$.
There is the Künneth theorem relating $K_G(X)$, $K_H(Y)$ and $K_{G \times H}(X \times Y)$, where $X$ is a $G$-space and $Y$ is a $H$-space. This only reduces to the above case when either $G$ or $H$ acts trivially (and the corresponding $X$ or $Y$ is a point).
I can't find anything in the literature, for K-theory or equivariant cohomology. Is there a specific reason why it is so hard to get information about $K_{G \times H}(X)$ from $K_G(X)$ and $K_H(X)$?

A: It is exactly the content of a paper of Minami (At least for compact Lie groups)
A Künneth formula for equivariant $K$-theory. Haruo Minami. Osaka J. Math. 6(1): 143-146 (1969).
Following ideas of Atiyah's proof of the Kunneth theorem for K-theory (non-equivariant) he obtain exactly the result you want.
As a final comment note that if $G$ acts on spaces $X$ and $Y$ it is too much hard to obtain $K_G(X\times Y)$ in terms of $K_G(X)$ and $K_G(Y)$


text:
Q: Is there a way to get a public URL for individual iCloud photos? I understand it's possible, through the Photos app and iCloud, to create a sharing stream of photos. What I am wondering is if it's possible to get a public URL from any given photo in iCloud.
My end goal is to use the URL in a shell script that would replicate CloudApp or Dropbox screenshot sharing, only using iCloud storage. Can't seem to find anything on the web that explains if this is/isn't possible.
Any suggestions are greatly appreciated :)

A: There is no way to get the URL from the Photos app that I am aware of. However, you can create a public album (see screenshot) which will then give you an album URL. You could scrape that page for image URLs. Psuedo Xpath to do so: //div[@class="view image-view canvas-image-view"]
(Note that the page is written in such a way that only the photo[s] visible on-screen are present in the HTML code, so your script would need to scroll through the window to scrape all the necessary URLs.)


text:
Q: Connect MySQL with Google App Engine with Eclipse I'm new to Google App Engine and I need to make an application with GAE.
I want the database to be MySQL. I signed up in Google Cloud SQL for limited preview but I want to work meanwhile locally (offline). Is that possible even though I don't have access yet to the Google Cloud SQL? If so, can you please supply me with the JDBC script to make that happen? And any libraries if needed.
I usually connect to the local DB with this:
package acc;

import java.sql.*;
import com.google.appengine.api.rdbms.AppEngineDriver;

import java.io.IOException;
import java.sql.*;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * provide database connection
 */
public class dbConnection {

   static Connection conn;
   static String url;

   public static Connection getConnection()
   {

      try
      {
          String url = "jdbc:mysql://localhost:3306/gp";

          Class.forName ("com.mysql.jdbc.Driver").newInstance ();

         try
         {
             String userName = "root";
             String password = "";

             conn = DriverManager.getConnection (url, userName, password);
             System.out.println ("Database connection established");
         }
         catch (Exception e)
         {
             System.err.println ("Cannot connect to database server");
         }
      }

      catch(ClassNotFoundException e)
      {
         System.out.println(e);
      } catch (InstantiationException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    } catch (IllegalAccessException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    }

   return conn;
}
}

Thanks alot
com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Could not create connection to database server.
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:525)
    at com.google.appengine.tools.development.agent.runtime.Runtime.newInstance_(Runtime.java:126)
    at com.google.appengine.tools.development.agent.runtime.Runtime.newInstance(Runtime.java:134)
    at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
    at com.mysql.jdbc.Util.getInstance(Util.java:386)
    at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1013)
    at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:987)
    at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:982)
    at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:927)
    at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2464)
    at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2207)
    at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:797)
    at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:47)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:525)
    at com.google.appengine.tools.development.agent.runtime.Runtime.newInstance_(Runtime.java:126)
    at com.google.appengine.tools.development.agent.runtime.Runtime.newInstance(Runtime.java:134)
    at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
    at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:389)
    at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:305)
    at java.sql.DriverManager.getConnection(DriverManager.java:579)
    at java.sql.DriverManager.getConnection(DriverManager.java:221)
    at acc.dbConnection.getConnection(dbConnection.java:35)
    at acc.DAO.getEmpList(DAO.java:40)
    at acc.SelectEmpServlet.doGet(SelectEmpServlet.java:27)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
    at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1166)
    at com.google.appengine.tools.development.HeaderVerificationFilter.doFilter(HeaderVerificationFilter.java:35)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at com.google.appengine.api.blobstore.dev.ServeBlobFilter.doFilter(ServeBlobFilter.java:60)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:43)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at com.google.appengine.tools.development.StaticFileFilter.doFilter(StaticFileFilter.java:122)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at com.google.appengine.tools.development.BackendServersFilter.doFilter(BackendServersFilter.java:97)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
    at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:388)
    at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
    at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
    at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
    at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418)
    at com.google.appengine.tools.development.DevAppEngineWebAppContext.handle(DevAppEngineWebAppContext.java:78)
    at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
    at com.google.appengine.tools.development.JettyContainerService$ApiProxyHandler.handle(JettyContainerService.java:369)
    at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
    at org.mortbay.jetty.Server.handle(Server.java:326)
    at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
    at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:923)
    at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:547)
    at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
    at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
    at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409)
    at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
Caused by: java.security.AccessControlException: access denied ("java.net.SocketPermission" "localhost" "resolve")
    at java.security.AccessControlContext.checkPermission(AccessControlContext.java:366)
    at java.security.AccessController.checkPermission(AccessController.java:555)
    at java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
    at com.google.appengine.tools.development.DevAppServerFactory$CustomSecurityManager.checkPermission(DevAppServerFactory.java:252)
    at java.lang.SecurityManager.checkConnect(SecurityManager.java:1048)
    at java.net.InetAddress.getAllByName0(InetAddress.java:1203)
    at java.net.InetAddress.getAllByName(InetAddress.java:1127)
    at java.net.InetAddress.getAllByName(InetAddress.java:1063)
    at com.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.java:247)
    at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:298)
    at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2385)
    at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2422)
    ... 48 more
java.lang.NullPointerException

A: >> Could not create connection to database server.
>> access denied ("java.net.SocketPermission" "localhost" "resolve")

The app engine is not allowing you to open sockets, and rightfully so. When deployed, you would never have access to such low-level mechanisms.
Documented here: https://developers.google.com/appengine/docs/java/runtime#The_Sandbox

An App Engine application cannot open a socket or access another host
  directly


text:
Q: Failed to build native extension I switched to Linux Mint About a Two weeks ago and want to install my bundle for my website but my terminal is giving me error
    Resolving dependencies.............
    Using rake 11.2.2
    Using i18n 0.7.0
    Using json 1.8.3
    Using minitest 5.9.0
    Using thread_safe 0.3.5
    Using builder 3.2.2
    Using erubis 2.7.0
    Using mini_portile2 2.1.0
    Using pkg-config 1.1.7
    Using rack 1.6.4
    Using mime-types-data 3.2016.0521
    Using arel 6.0.3
    Installing debug_inspector 0.0.2 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory: /var/lib/gems/2.3.0/gems/debug_inspector-0.0.2/ext    /debug_inspector
/usr/bin/ruby2.3 -r ./siteconf20160830-6661-3kryhn.rb extconf.rb
creating Makefile

current directory: /var/lib/gems/2.3.0/gems/debug_inspector-0.0.2/ext/debug_inspector
make "DESTDIR=" clean

current directory: /var/lib/gems/2.3.0/gems/debug_inspector-0.0.2/ext/debug_inspector
make "DESTDIR="
compiling debug_inspector.c
In file included from /usr/include/ruby-2.3.0/ruby/ruby.h:36:0,
             from debug_inspector.c:12:
/usr/include/ruby-2.3.0/ruby/defines.h:26:19: fatal error: stdio.h: No     such file or directory
compilation terminated.
Makefile:239: recipe for target 'debug_inspector.o' failed
make: *** [debug_inspector.o] Error 1

make failed, exit code 2

Gem files will remain installed in /var/lib/gems/2.3.0   /gems/debug_inspector-0.0.2 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/debug_inspector-0.0.2/gem_make.out
Using bundler 1.11.2
Installing byebug 9.0.5 with native extensions

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory: /var/lib/gems/2.3.0/gems/byebug-9.0.5/ext/byebug

/usr/bin/ruby2.3 -r ./siteconf20160830-6661-18ytmbw.rb extconf.rb
    creating Makefile
current directory: /var/lib/gems/2.3.0/gems/byebug-9.0.5/ext/byebug
make "DESTDIR=" clean

current directory: /var/lib/gems/2.3.0/gems/byebug-9.0.5/ext/byebug
make "DESTDIR="
compiling breakpoint.c
In file included from /usr/include/ruby-2.3.0/ruby/ruby.h:36:0,
             from /usr/include/ruby-2.3.0/ruby.h:33,
             from byebug.h:4,
             from breakpoint.c:1:
/usr/include/ruby-2.3.0/ruby/defines.h:26:19: fatal error: stdio.h: No   such file or directory
compilation terminated.
Makefile:239: recipe for target 'breakpoint.o' failed
make: *** [breakpoint.o] Error 1

make failed, exit code 2

Gem files will remain installed in /var/lib/gems/2.3.0/gems/byebug-9.0.5 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/byebug-9.0.5/gem_make.out
Using coffee-script-source 1.10.0
Using execjs 2.7.0
Using thor 0.19.1
Using concurrent-ruby 1.0.2
Using multi_json 1.12.1
Using sass 3.4.22
Using tilt 2.0.5
Using spring 1.7.2
Installing sqlite3 1.3.11 with native extensions

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory: /var/lib/gems/2.3.0/gems/sqlite3-1.3.11/ext/sqlite3

/usr/bin/ruby2.3 -r ./siteconf20160830-6661-3zztze.rb extconf.rb
    checking for sqlite3.h... * extconf.rb failed *
    Could not create Makefile due to some reason, probably lack of necessary
    libraries and/or headers.  Check the mkmf.log file for more details.  You may
    need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/bin/$(RUBY_BASE_NAME)2.3
--with-sqlite3-dir
--without-sqlite3-dir
--with-sqlite3-include
--without-sqlite3-include=${sqlite3-dir}/include
--with-sqlite3-lib
--without-sqlite3-lib=${sqlite3-dir}/lib
/usr/lib/ruby/2.3.0/mkmf.rb:456:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /usr/lib/ruby/2.3.0/mkmf.rb:587:in `try_cpp'
from /usr/lib/ruby/2.3.0/mkmf.rb:1144:in `block in find_header'
from /usr/lib/ruby/2.3.0/mkmf.rb:942:in `block in checking_for'
from /usr/lib/ruby/2.3.0/mkmf.rb:350:in `block (2 levels) in postpone'
from /usr/lib/ruby/2.3.0/mkmf.rb:320:in `open'
from /usr/lib/ruby/2.3.0/mkmf.rb:350:in `block in postpone'
from /usr/lib/ruby/2.3.0/mkmf.rb:320:in `open'
from /usr/lib/ruby/2.3.0/mkmf.rb:346:in `postpone'
from /usr/lib/ruby/2.3.0/mkmf.rb:941:in `checking_for'
from /usr/lib/ruby/2.3.0/mkmf.rb:1143:in `find_header'
from extconf.rb:30:in `<main>'

To see why this extension failed to compile, please check the mkmf.log which can be found here:

/var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/sqlite3-1.3.11/mkmf.log
    extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.3.0/gems/sqlite3-1.3.11 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/sqlite3-1.3.11/gem_make.out
Using turbolinks-source 5.0.0
Using rdoc 4.2.2
Using tzinfo 1.2.2
Installing nokogiri 1.6.8 with native extensions

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory: /var/lib/gems/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri

/usr/bin/ruby2.3 -r ./siteconf20160830-6661-657qsw.rb extconf.rb
    Using pkg-config version 1.1.7
    checking if the C compiler accepts ... * extconf.rb failed *
    Could not create Makefile due to some reason, probably lack of necessary
    libraries and/or headers.  Check the mkmf.log file for more details.  You may
    need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/bin/$(RUBY_BASE_NAME)2.3
--help
--clean
/usr/lib/ruby/2.3.0/mkmf.rb:456:in `try_do': The compiler failed to    generate an executable file. (RuntimeError)
You have to install development tools first.
from /usr/lib/ruby/2.3.0/mkmf.rb:571:in `block in try_compile'
from /usr/lib/ruby/2.3.0/mkmf.rb:522:in `with_werror'
from /usr/lib/ruby/2.3.0/mkmf.rb:571:in `try_compile'
from extconf.rb:138:in `nokogiri_try_compile'
from extconf.rb:162:in `block in add_cflags'
from /usr/lib/ruby/2.3.0/mkmf.rb:629:in `with_cflags'
from extconf.rb:161:in `add_cflags'
from extconf.rb:414:in `<main>'

To see why this extension failed to compile, please check the mkmf.log which can be found here:

/var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/nokogiri-1.6.8/mkmf.log
extconf failed, exit code 1

Gem files will remain installed in /var/lib/gems/2.3.0/gems/nokogiri-1.6.8 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/nokogiri-1.6.8/gem_make.out
Using rack-test 0.6.3
Using mime-types 3.1
An error occurred while installing debug_inspector (0.0.2), and Bundler cannot
continue.
Make sure that `gem install debug_inspector -v '0.0.2'` succeeds before
bundling.

I tried to install the debug_inspector like this
    gem install debug_inspector -v 0.0.2
result:
    Building native extensions.  This could take a while...
    ERROR:  Error installing debug_inspector:
    ERROR: Failed to build gem native extension.
current directory: /var/lib/gems/2.3.0/gems/debug_inspector-0.0.2/ext/     \debug_inspector
/usr/bin/ruby2.3 -r ./siteconf20160830-6775-1iui5kl.rb extconf.rb
creating Makefile

current directory: /var/lib/gems/2.3.0/gems/debug_inspector-0.0.2/ext  /debug_inspector
make "DESTDIR=" clean

current directory: /var/lib/gems/2.3.0/gems/debug_inspector-0.0.2/ext/debug_inspector
make "DESTDIR="
compiling debug_inspector.c
In file included from /usr/include/ruby-2.3.0/ruby/ruby.h:36:0,
             from debug_inspector.c:12:
/usr/include/ruby-2.3.0/ruby/defines.h:26:19: fatal error: stdio.h: No such   file or directory
compilation terminated.
Makefile:239: recipe for target 'debug_inspector.o' failed
make: *** [debug_inspector.o] Error 1

make failed, exit code 2

Gem files will remain installed in /var/lib/gems/2.3.0/gems/debug_inspector-0.0.2 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/debug_inspector-0.0.2/gem_make.out

EDIT
json runs with the same error
will try to reinstall the whole ruby system
EDIT2
installing devkit and trying again

A: For Rails on Linux Mint 18, add libraries:
build-essential patch ruby-dev zlib1g-dev liblzma-dev libsqlite3-dev

A: The Following Code Fixed my Problem
sudo apt-get install build-essential patch

sudo apt-get install ruby-dev zlib1g-dev liblzma-dev

A: This is what worked for me:
sudo apt-get install libmagickcore-dev libmagickwand-dev

Which I found after lot of research on this link.


text:
Q: Confusion setting Worker Role diagnostics with Powershell I want to ensure that my Worker Role always has the correct Diagnostics configured, but I am having a couple of issues and finding the documentation on this very unclear.
I had the diagnostics set up on the Worker Role and functioning as expected; for example the WAD tables were all being populated.
This has been working for many months and we have deployed (via the Swap VIP from Staging to Production) new versions of the Worker Role and the diagnostics have continued to function as expected.
Recently, however, we deployed a new version of the Worker Role (again, via the Swap VIP) and the diagnostics have been removed.  Using the
Get-AzureServiceDiagnosticsExtension -ServiceName "blah" -Slot "Production"

cmdlet I can see that, indeed there is no diagnostics config on the Worker Role.
Clearly I am missing something with how I configure the Worker Role using the
Set-AzureServiceDiagnosticsExtension

The documentation is very unclear about what the -Role and -Slot parameters do
(empahsis mine)

-Role<String[]>
An optional array of roles to specify the diagnostics configuration for. If not specified the diagnostics configuration is applied as the default configuration for all roles.

Does this mean that immediately all deployments get the config, no matter their Role or Slot?  Or does it mean that I am setting the "default" for any deployments that I make afterwards?  If I have latterly run this command with the -Slot parameter, will this affect the "default"? Why does the `Get-AzureServiceDiagnosticExtension not have a -Role param?

-Slot<String>
Specifies the environment of the deployment to modify. Supported values are "Production" or "Staging".

But what if I don't provide -Slot?  Does this mean that all slots immediately get the config? How does -Slot work with -Role as there is no mention of "default" here like the -Role documentation?
Additional confusion comes from the fact that Remove-AzureServiceDiagnosticsExtension also has -Slot and -Role but the documentation is not clear how this tallies up with "default" configs that it describes in the Set- cmdlet documentation.  Does removing without -Role or -Slot remove everything, or just the "default" that you Set- without -Role or -Slot?
What I would like to do is make sure that I only have to set the Diagnostics Once. i.e. at the point that I first Create the Worker Role, I set the Diagnostics and never have to touch it again.
However, I have the added complication that I would prefer to not have diagnostics recorded for the Staging, just the Production.
I've been playing with the cmdlets and testing but I have no confidence because

*

*The fact that diagnostics were removed on swapping a new version in even though they had been fine with previous swaps and

*The documentation is very unclear.

UPDATE
To try and understand this more I have made an assumption that by Set-ing the Diagnostics *on the Production Slot I will get the setup that I require.
I've done this with:
Set-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService" `
  -Slot Production -DiagnosticsConfigurationPath "<path to file>" `
  -StorageContext "<context>" -CertificateThumbprint "CERTHUMBPRINT"

But what you get back from Get- and Remove- are not what you would expect:

*

*Get, with no slot
Get-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService"
Returns an object, with ID (NOT EXPECTED)

Default-PaaSDiagnostics-Production-Ext-0

*Get, with Production Slot

Get-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService" -Slot Production
Returns an object, with ID (expected)

Default-PaaSDiagnostics-Production-Ext-0

*Get, with Staging Slot

Get-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService" -Slot Staging
Returns no object (expected)

*Remove, with no Role or Slot

Remove-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService"
Returns nothing to remove (expected)

WARNING: No existing Microsoft.Azure.Diagnostics.PaaSDiagnostics extensions enabled on given roles.

*Remove, with no Role but Staging Slot

Remove-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService" -Slot Staging
Returns nothing to remove (expected)

WARNING: No existing Microsoft.Azure.Diagnostics.PaaSDiagnostics extensions enabled on given roles.

*Remove, with Role "MyRole" and Staging Slot

Remove-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService" -Role "MyRole" -Slot Staging
Returns nothing to remove (expected)

WARNING: No existing Microsoft.Azure.Diagnostics.PaaSDiagnostics extensions enabled on given roles.

*Remove, with no Role but Production Slot

Remove-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService" -Slot Production
Returns nothing to remove (NOT EXPECTED)

WARNING: No existing Microsoft.Azure.Diagnostics.PaaSDiagnostics extensions enabled on given roles.

*Remove, with Role "MyRole" and Production Slot

Remove-AzureServiceDiagnosticsExtension -ServiceName "MyCloudService" -Role "MyRole" -Slot Staging
Return successful remove (NOT EXPECTED)

WARNING: Removing PaaSDiagnostics configuration for MyRole from Cloud Service MyCloudService.

I don't understand why a Get- with no Slot would return the Diagnostics, but a Remove- with no Role or Slot says there is nothing there.
Equally, why does the Remove- not work without the Role rather than with the Role?


text:
Q: .NET Native optimization breaks an application In one of the applications I've encountered an error associated with the optimization of code.
I tried to repeat this behavior in the test application. The application is available on GitHub:  https://github.com/altk/NullableError
The error occurs only when you compile using .NET Native, but not everywhere. Error reproduces on few PCs.
The application code is very simple. It must prints to the console:
-------------- ELSE --------------
-------------- SUCCESS --------------
But by reason of the optimization it prints:
-------------- ELSE --------------
-------------- FAIL --------------
All code of the application:
#define DEBUG
using System;
using System.Collections.Generic;
using System.Diagnostics;

namespace NullableError
{
    sealed partial class App
    {
        private readonly Dictionary<String, String> _dictionary = new Dictionary<String, String>();

        public App()
        {
            InitializeComponent();

            Execute();
            Exit();
        }

        private Int64? NullableInt64
        {
            get
            {
                var resultString = this[nameof(NullableInt64)];
                return String.IsNullOrEmpty(resultString) ? default(Int64?) : Int64.Parse(resultString);
            }
            //-----FIX VARIANT------
            //UNCOMMENT NEXT LINE TO FIX
            //[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoOptimization)]
            set
            {
                //-----FIX VARIANT------
                //REPLACE WITH
                //this[nameof(NullableInt64)] = value != null ? value.Value.ToString() : null;
                this[nameof(NullableInt64)] = value?.ToString();
            }
        }

        private Int64? AnotherNullableInt64
        {
            get
            {
                var resultString = this[nameof(AnotherNullableInt64)];
                return String.IsNullOrEmpty(resultString) ? default(Int64?) : Int64.Parse(resultString);
            }
            set { this[nameof(AnotherNullableInt64)] = value?.ToString(); }
        }

        private void Execute()
        {
            //-----FIX VARIANT------
            //REPLACE WITH IF-ELSE WITH
            //NullableInt64 = (DateTimeOffset.Now - DateTimeOffset.MinValue).TotalMilliseconds < 0 ? (Int64?) 125 : null;
            if ((DateTimeOffset.Now - DateTimeOffset.MinValue).TotalMilliseconds < 0)
            {
                Debug.WriteLine("-------------- IF --------------");
                NullableInt64 = 125;
            }
            else
            {
                Debug.WriteLine("-------------- ELSE --------------");
                NullableInt64 = null;
            }

            //-----FIX VARIANT------
            //REPLACE WITH
            //AnotherNullableInt64 = 0;
            AnotherNullableInt64 = null;

            Debug.WriteLine(String.Format("-------------- {0} --------------", this[nameof(NullableInt64)] == "0" ? "FAIL" : "SUCCESS"));
        }

        private String this[String key]
        {
            get
            {
                String result;
                return _dictionary.TryGetValue(key, out result) ? result : null;
            }
            set { _dictionary[key] = value; }
        }
    }
}

A: Microsoft confirmed this bug.
https://connect.microsoft.com/VisualStudio/feedback/details/2164313/net-native-optimization-breaks-an-application#
It will be fixed in upcoming VS 2015 Update 2


text:
Q: MySQL / MariaDB shuts down after exactly 1 minute 42 seconds I've installed Homestead via VirtualBox and Vagrant on macOS Sierra. Everything works, except for some mysterious reason MySQL shuts itself down after the box has been up for longer than 1 minute 42 seconds...
I'm able to use MySQL without issue for the first 1 minute 42 seconds, but then suddenly the service shuts down and refuses further connections.
I tailed /var/log/syslog after the server came up, and the following syslog entries  appearing:
Dec 10 20:02:25 homestead systemd[1]: mariadb.service: Start operation timed out. Terminating.
Dec 10 20:02:25 homestead mysqld[1611]: 2016-12-10 20:02:25 140574075632384 [Note] /usr/sbin/mysqld: Normal shutdown
Dec 10 20:02:25 homestead mysqld[1611]: 2016-12-10 20:02:25 140574075632384 [Note] Event Scheduler: Purging the queue. 0 events
Dec 10 20:02:25 homestead kernel: [  100.520787] audit_printk_skb: 15 callbacks suppressed
Dec 10 20:02:25 homestead kernel: [  100.520844] audit: type=1400 audit(1481400145.309:17): apparmor="DENIED" operation="sendmsg" info="Failed name lookup - disconnected path" error=-13 profile="/usr/sbin/mysqld" name="run/systemd/notify" pid=1611 comm="mysqld" requested_mask="w" denied_mask="w" fsuid=113 ouid=0
Dec 10 20:02:25 homestead mysqld[1611]: 2016-12-10 20:02:25 140573193234176 [Note] InnoDB: FTS optimize thread exiting.
Dec 10 20:02:25 homestead mysqld[1611]: 2016-12-10 20:02:25 140574075632384 [Note] InnoDB: Starting shutdown...
Dec 10 20:02:25 homestead systemd[1]: Started Session 4 of user vagrant.
Dec 10 20:02:26 homestead mysqld[1611]: 2016-12-10 20:02:26 140574075632384 [Note] InnoDB: Waiting for page_cleaner to finish flushing of buffer pool
Dec 10 20:02:27 homestead mysqld[1611]: 2016-12-10 20:02:27 140574075632384 [Note] InnoDB: Shutdown completed; log sequence number 1355249813
Dec 10 20:02:27 homestead mysqld[1611]: 2016-12-10 20:02:27 140574075632384 [Note] /usr/sbin/mysqld: Shutdown complete
Dec 10 20:02:27 homestead kernel: [  102.937893] audit: type=1400 audit(1481400147.726:18): apparmor="DENIED" operation="sendmsg" info="Failed name lookup - disconnected path" error=-13 profile="/usr/sbin/mysqld" name="run/systemd/notify" pid=2030 comm="mysqld" requested_mask="w" denied_mask="w" fsuid=113 ouid=0
Dec 10 20:02:27 homestead kernel: [  102.938561] audit: type=1400 audit(1481400147.726:19): apparmor="DENIED" operation="sendmsg" info="Failed name lookup - disconnected path" error=-13 profile="/usr/sbin/mysqld" name="run/systemd/notify" pid=1611 comm="mysqld" requested_mask="w" denied_mask="w" fsuid=113 ouid=0
Dec 10 20:02:27 homestead systemd[1]: Failed to start MariaDB database server.
Dec 10 20:02:27 homestead systemd[1]: mariadb.service: Unit entered failed state.
Dec 10 20:02:27 homestead systemd[1]: mariadb.service: Failed with result 'timeout'.
Dec 10 20:02:27 homestead systemd[1]: Reached target Multi-User System.
Dec 10 20:02:27 homestead systemd[1]: Starting Notify bootloader that boot was successful...
Dec 10 20:02:27 homestead systemd[1]: Reached target Graphical Interface.
Dec 10 20:02:27 homestead systemd[1]: Starting Update UTMP about System Runlevel Changes...
Dec 10 20:02:27 homestead systemd[1]: Started Update UTMP about System Runlevel Changes.
Dec 10 20:02:27 homestead snap[2063]: Ignoring 'booted' on classic
Dec 10 20:02:27 homestead systemd[1]: Started Notify bootloader that boot was successful.
Dec 10 20:02:27 homestead systemd[1]: Startup finished in 5.989s (kernel) + 1min 36.860s (userspace) = 1min 42.850s.

The first line, where it says mariadb.service, gets logged the moment I get kicked out of MySQL. But I have no idea why.
It looks like the logs are implying MySQL / MariaDB are still trying to start up after the box has been brought up - even though I've been able to connect to them by this point without issue. Then some mystery timeout is hit, and the whole thing shuts down.
Can anyone help me interpret this...? Thanks!

A: Finally figured it out - AppArmor seems to be causing the problem.
By following the steps outlined here, I was able to resolve the issue, and MySQL no longer shuts down unexpected.


text:
Q: What exactly does IQueryable mean? I'm not sure I understand what exactly IQueryable is.
I understand that it doesn't get me all the entities and puts the constraint part in memory but executes it as part of the command it sends to the database.
Please correct me if I'm mistaken and tell me, why should my repository functions return IQueryable and not a simple List?

A: IQueryable and IQueryable<T> are abstractions that encapsulate LINQ expressions; these expressions are then used by a LINQ provider - like the one used by Entity Framework - to turn these expressions into SQL that will, in turn, be sent to the database. Different LINQ providers interpret LINQ expressions differently, for example, MongoDB's turns these expressions into JSON queries.
IQueryables are only evaluated when a "terminal" method is called upon them, like, ToList(), ToArray(), Single(), SingleOrDefault(), First(), FirstOrDefault(), Count(), Any(), etc. This is when the provider quicks in and does the translation.
Microsoft includes a LINQ provider, which does not do a translation to anything, but operates in memory. This is the one used when you turn an IEnumerable<T> into an IQueryable<T>, by calling the extension method AsQueryable().

A: An IQueryable is not actually a collection of entities, rather it describes how to obtain that collection. The data is never retrieved from the source until you evaluate it, by turning it into an IEnumerable or something similar.
The advantage of returning an IQueryable from your repository is that your calling code can specify additional .Where clauses BEFORE the query goes to the database. If you returned an IEnumerable, your code would retrieve all values of one table from the database, and then perform filtering in memory, which is inefficient.


text:
Q: Range check feedback in Python For an assignment for school, I've got to come up with a code breaker that follows certain rules.

*

*Code is 4 numbers. (not random)

*I can't use functions/lists/arrays. Only loops.

*Implement a stop code. (9999)

*Every step of the way the user needs to get feedback.

*Feedback includes, but not limited to;

*

*What turn the player is on. (Limit of 10)

*If a number is used more than once.

*If a number is used outside of the range(0,8) and/or a symbol.

*Feedback(hint) where a used number actually should be placed if it had been used on a turn.

So, I've brewed something up that kinda does all of the above.
However, 2 main issues remain that I just can't seem to tackle.

*

*Feedback, (aka the hint), prints out multiple times. If the user used for example '1111' the program would print 4 times that number 1 should be used at location X. How can I limit my print output to only once, or even even better, to only once during the 10 turns?

*No matter what number I use within or not within the range(0,8), the program always gives me feedback that I've used something that I shouldn't. What would be the best way for me to solve this?
I'm not asking anyone to make my assignment, but just some tips or tricks to keep me going would be enormously appreciated! As you may see at first glance, I'm a complete beginner. So I apologise if things look messy.
code= "1436"     #gezochte code
beurt = 0        #beurten voor user
stop = "9999"    #stopcode voor user
gok = ''         #user input
num_range = range(0,8)
print("""Welkom, je mag 10 keer raden naar de juiste code van 4 nummers.
De nummers mogen niet opeenvolgend zijn.
De nummers gaan van 1 tem 7.
Je kan altijd vroegtijdig stoppen door 9999 in te geven.""")
print()
while gok != code:
    gok = (input("Geef een 4 cijferige code in: "))
    if gok == stop:
        print()
        print("U heeft gekozen om te stoppen.")
        break
    if gok == code:
        print()
        print("Super! Je hebt de code gekraakt!")
        break
    if gok != (num_range):
        print()
        print("Uw code zit niet binnen 1 tem 7 en/of is geen nummer.")
    if gok != code:
        beurt +=1
        print()
        print("Niet juist. Je zit aan beurt:",beurt)
    if beurt == 10:
        print()
        print("Uw beurten zijn opgebruikt.")
        break
    for i in num_range:
        if i == i\*2:
            print()
            print("Elk nummer kan maar 1 keer gebruikt worden.")
            print()
    else:
        for i in gok:
            if i == "1":
                print("Nummer 1 staat op de eerste plaats.")
                continue
            elif i == "4":
                print("Nummer 4 staat op de tweede plaats.")
                continue
            elif i == "3":
                print("Nummer 3 staat op de derde plaats.")
                continue
            elif i == "6":
                print("Nummer 6 staat op de vierde plaats.")
                continue

A: So for the first problem, I am taking a look at this piece of code:
for i in gok:
    if i == "1":
        print("Nummer 1 staat op de eerste plaats.")
        continue

What happens here, is that, for every number in gok, if the number matches "1", it will print out that statement. However, you want to also check whether that number is actually in the first position. You can do that by keeping track of the index of the number in your for loop:
for index, i in enumerate(gok):
    if index == 0 and i == "1":
        print("Nummer 1 staat op de eerste plaats.")
        continue

With enumerate, you keep track of both the index of the item in gok as well as the item itself. Repeat that for every if statement, and the first problem will be fixed.

For the second problem, you would want to check if your input is in the range 0-8. Currently you are doing that by:
if gok != (num_range):
    print()
    print("Uw code zit niet binnen 1 tem 7 en/of is geen nummer.")

What you could do instead, is test whether the number as integer is in between 0 and 8. This is done by:
for i in gok:
    if not 0 <= int(i) <= 8:
        print()
        print("Uw code zit niet binnen 1 tem 7 en/of is geen nummer.")

A: To check that the input is valid, you can use this:
    if len(gok) != 4:
        print()
        print("Number is not 4 digits")
        break
    all_digits = True
    for digit in gok:
        if not '0' <= digit < '8':
            all_digits = False
            break
    if not all_digits:
        print()
        print("Digits not in range(0, 8)")
        break

A: In such cases, when the task is easy and the overall code looks messy, I would suggest you to rewrite it from scratch.
But in this time, split your task into small pieces.
And use your previous experience to write better and more structured code.
So, first of all - let's repeat our task.
This is important step, so don't skip it (read it again, even if you think you get it).

*

*Code is 4 numbers. (not random)

*I can't use functions/lists/arrays. Only loops.

*Implement a stop code. (9999)

*Every step of the way the user needs to get feedback. Feedback includes, but not limited to;

*

*What turn the player is on. (Limit of 10)

*If a number is used more than once.

*If a number is used outside of the range(0,8) and/or a symbol.

*Feedback (hint) where a used number actually should be placed
if it had been used on a turn.

Secondly, let's think of it as a plan (as Dutch from RDR2 said "Don't worry, I have a plan, just have a little faith").
In order to write down the plan, you should ask yourself three simple questions:

*

*What user input will program request?

*What output it should give?

*How it going to look like (interface, hints, overall behavior etc)

And when you got the answers, you can write down the plan of how your code will work like.
Let's say:

*

*The code will have some configuration variables (searched code, stop code, current attempt etc)

*The code must first greet the user, explain the rules and then ask for an input.

*There will be only ONE single input throughout the code, and that is - user guess.

*After every input, the code must check whether the user guess is right or not. If it's not, we continue the game. If it is, the game is
over because user WIN the game.   (this and all next steps
will only be used, if user guess is wrong)

*If the user exceeds his attempts, the game is also OVER.

*Next we should give some feedback to help user guess the searched code.
This includes:

*

*Current attempt

*If a number is used more than once

*If some number in user input is out of given range

*If a searched code actually contains one of the used numbers in user input, we must give a hint about it (along with the according
number position within the searched code)

Ok, now we have a textual representation of our code (scenario, if you want to).
And only now, we are able to write down the solution using actual Python code.
You can try it by your own at this point, and then come back when you succeed to compare results.
First of all, let's create an empty python file and define some variables.
# CODE BREAKER v0.1 BETA

allowed_range = (0, 8)  # minimum and maximum allowed numbers that can be used within the code
searched_code = "1436"  # the code user will need to guess
stop_code = "9999"  # the stop code, if user enter it - game ends
max_attempts = 10  # how much attempts user will have

user_input = None  # this will contain current user guess
current_attempt = 0  # number of current attempt of a user

Next, according to our plan, we have to greet the user and explain the rules of the game.
print("Welcome to the CODE BREAKER game!\n\n"
+"Rules are simple:\n"+
f"- The code you need to crack contains {len(searched_code)} numbers\n"
+f"- You have only {max_attempts} attempts\n"
+"- Numbers cannot be consecutive\n"
+f"- Numbers must fit the given range from {allowed_range[0]} to {allowed_range[1]}\n"
+f"\nYou can always stop the game by typing {stop_code}"
+"\n\n")

Our third and fourth step is similar, - request an input from the user and check whether it's correct or not.
while True:
    # request input
    print(f"Attempts left - {max_attempts-current_attempt}")
    user_input = input(f"What's your guess?: ").strip()

    # compare guess with the actual searched code
    if user_input == searched_code:
        print("FAN-TA-STIC!!! You won the game. Awesome!!!")
        break
    elif user_input == stop_code:
        print("You quit the game.")
        break
    else:
        print("Wrong ...\n")

    # increment attempts
    current_attempt += 1

    # if attempts exceeded, quite the game
    if current_attempt > max_attempts:
        print("You have exceeded your attempts. Sorry, no luck this time.")
        break

What was that step five in our plan? ...
Nailed it! We have to give a user some feedback, if he did not guessed the code.
Check if a user input numbers is within the required range:
for num in user_input:
    if int(num) < allowed_range[0] or int(num) > allowed_range[1]:
        print(f"HINT: The number {num} you entered is not within the required range!")

Check if a user input numbers is consecutive:
prev_num = None
for num in user_input:
    if prev_num is None:
        prev_num = int(num)
        continue

    if prev_num+1 == int(num):
        print(f"HINT: The numbers {prev_num}{num} you entered is consecutive, but it's forbidden by the rules of the game!")
        break

Check if a user input numbers are only used once:
i_pos = 1
for i in user_input:
    j_pos = 1
    for j in user_input[i_pos:]:
        if i == j and i_pos != j_pos:  # skip, if it's the same position
            print(f"HINT: The number {i} is used more than once! Which is forbidden by the rules of the game.")
            break
        j_pos += 1  # track the sub loop number position
    if i == j:
        break # quite the upper loop

    i_pos += 1  # track the main loop number position

And finally, give a hint if some of a user input numbers is correct (location hint):
i_pos = 1
for i in searched_code:
    for j in user_input:
        if j == i:
            print(f"HINT: The number {j} you have entered is located at position {i_pos} in the searched code.")
            break # break & check other positions

    i_pos += 1  # offset of a number in searched_code variable

And that's all! Our plan is done. Every step is written as a code.
And everything seems to work just as planned!
Just as Dutch planned ... :D
By the way, here is the full final code (if you need it): https://pastebin.com/hayVjJTm
p.s. I've tried to write down the whole code as simple as I can (like the very beginner in Python would do it, I guess).


text:
Q: Is Web Speech API Grammar exposed to developers? I am currently doing some RnD on Webkit Speech Recognition and I wanted to create an application specific grammar file.
According W3C definition I wrote the following code. But it doesnt seem to show improved results in recognition for these words. Can you kindly provide some help with this.?
var recognition = new webkitSpeechRecognition();
recognition.grammars.addFromUri("voice/api_grammar/weight.grxml");
The grammar file is a simple file which looked like the following.
<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE grammar PUBLIC "-//W3C//DTD GRAMMAR 1.0//EN"
                  "http://www.w3.org/TR/speech-grammar/grammar.dtd">

<grammar version="1.0"
         xmlns="http://www.w3.org/2001/06/grammar"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://www.w3.org/2001/06/grammar
                             http://www.w3.org/TR/speech-grammar/grammar.xsd"
         xml:lang="en-US" mode="voice" root="sequence">

  <meta name='description' content='Example using examples'/>

  <meta name='in.1' content='sunny Yorktown Heights New York United States'/>
  <meta name='out.1' content='$sequence[$repeat[$alternatives["sunny"]],$ruleref[$token["Yorktown Heights"]],$Token["New","York"],$TOKEN["United States"]]'/>

  <rule id="ruleref">
    <example>"Yorktown Heights"</example>
    <ruleref uri="#token"/>
  </rule>

  <rule id="alternatives">
    <example>sunny</example>
    <example>cloudy</example>
    <example>warm</example>
    <example>cold</example>
    <one-of>
      <item> sunny </item>
      <item> cloudy </item>
      <item> warm </item>
      <item> cold </item>
    </one-of>
  </rule>

  <rule id="repeat">
   <example></example> <!-- for count=0 -->
   <example>warm</example>
   <example>warm sunny cloudy</example>
   <item repeat="0-3">
      <ruleref uri="#alternatives"/>
   </item>
  </rule>

  <rule id="sequence">
    <example>
      warm sunny cloudy "Yorktown Heights" New York "United States"
    </example>
    <example>
      warm sunny cloudy   Yorktown   Heights   New York United
            States
    </example>
    <example> <!-- this example is actually wrong but that is legal -->
      warm sunny cloudy "Yorktown   Heights" New York "United States"
    </example>

    <ruleref uri="#repeat"/> <ruleref uri="#ruleref"/>
    <ruleref uri="#Token"/> <ruleref uri="#TOKEN"/>
  </rule>

</grammar>

A: Though w3c specified the grammar for web speech it is not yet implemented by google chrome.


text:
Q: How to Apply Cauchy Integral Theorem I have a question about complex analysis.
Let C be the unit circle z = ejθ described from θ = -π to θ = π where α is a real constant. I need to prove this equation:

I thought that somehow I should rearrange the integrant to apply cauchy integral theorem. Thus I need singularity offspring of it.
Then I made variable displacement like this:

Now, I have the singularity but I'am stuck. How to go on with that?

A: We have
\begin{align}
\int_0^\pi e^{a\cos \theta} \cos(a\sin \theta)\, d\theta &= \frac{1}{2}\int_{-\pi}^{\pi} e^{a\cos \theta} \cos(a\sin \theta)\, d\theta \\
&= \frac{1}{2}\operatorname{Re} \int_{-\pi}^{\pi} e^{ae^{i\theta}}\, d\theta\\
&= \frac{1}{2}\operatorname{Re} \oint_C e^{az} \frac{dz}{iz} \tag{*}\\
\end{align}
Since $e^{az}/i$ is analytic inside and on $C$, and $0$ lies inside $C$, Cauchy's integral formula gives
$$\oint_C e^{az} \frac{dz}{iz} = 2\pi i\cdot \frac{e^{az}}{i}\bigg|_{z = 0} = 2\pi.$$
Hence, by $(*)$,
$$\int_0^\pi e^{a\cos \theta}\cos(a\sin \theta)\, d\theta = \pi.$$


text:
Q: insert div after X li I have an xslt navigation, which I want to break into 2 columns, so that after every 6 "li" it creates a new "div"...
I would like to output to be like this:

link

link

link

link

link

link

link

link

link

link

link

link

But not quite sure how to do this
My XSLT:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"  xmlns:xsl="http://www.w3.org/1999/XSL/Transform" >

  <xsl:output method="xml" omit-xml-declaration="yes" indent="yes"  encoding="utf-8" />
  <xsl:param name="html-content-type" />
  <xsl:template match="/NavigationTree">

    <xsl:if test="count(//Page) > 0">

        <xsl:apply-templates select="Page">
          <xsl:with-param name="depth" select="1"/>
        </xsl:apply-templates>

    </xsl:if>

  </xsl:template>

  <xsl:template match="//Page">
    <xsl:param name="depth"/>

      <xsl:attribute name="class">
        <xsl:if test="@InPath='True'">inpath </xsl:if>
        <xsl:if test="position() = 1">firstitem </xsl:if>
        <xsl:if test="position() = count(//Page)">lastitem </xsl:if>
        <xsl:if test="@Active='True'">selected</xsl:if>
      </xsl:attribute>

        <xsl:attribute name="class">
          <xsl:if test="@InPath='True'">inpath </xsl:if>
          <xsl:if test="position() = 1">firstitem </xsl:if>
          <xsl:if test="position() = count(//Page)">lastitem </xsl:if>
          <xsl:if test="@Active='True'">current</xsl:if>
        </xsl:attribute>
        <xsl:attribute name="href"><xsl:value-of select="@FriendlyHref" disable-output-escaping="yes"/></xsl:attribute>
        <xsl:value-of select="@MenuText" disable-output-escaping="yes"/>

        <xsl:text disable-output-escaping="yes"><![CDATA[]]></xsl:text>

        <xsl:if test="count(Page)">

            <xsl:apply-templates select="Page">
              <xsl:with-param name="depth" select="$depth+1"/>
            </xsl:apply-templates>

        </xsl:if>

  </xsl:template>

</xsl:stylesheet>

A: A way to do it would be to have a template that matches every 6 Page element:
<xsl:template match="//Page[position() mod 6 = 1]">

    <xsl:apply-templates select="." mode="SecondLevel"/>
    <xsl:apply-templates select="following-sibling::Page[position()<6]" mode="SecondLevel"/>

</xsl:template>

generating the div and applying a second-level template to the current element and its 5 following sibling. The second level template is the one you already have - with an added mode:
<xsl:template match="Page" mode="SecondLevel">

    <xsl:attribute name="class">
      <xsl:if test="@InPath='True'">inpath </xsl:if>
      <xsl:if test="position() = 1">firstitem </xsl:if>
      <xsl:if test="position() = count(//Page)">lastitem </xsl:if>
      <xsl:if test="@Active='True'">selected</xsl:if>
    </xsl:attribute>

      <xsl:attribute name="class">
        <xsl:if test="@InPath='True'">inpath </xsl:if>
        <xsl:if test="position() = 1">firstitem </xsl:if>
        <xsl:if test="position() = count(//Page)">lastitem </xsl:if>
        <xsl:if test="@Active='True'">current</xsl:if>
      </xsl:attribute>
      <xsl:attribute name="href">
        <xsl:value-of select="@FriendlyHref" disable-output-escaping="yes"/>
      </xsl:attribute>
      <xsl:value-of select="@MenuText" disable-output-escaping="yes"/>

      <xsl:text disable-output-escaping="yes"><![CDATA[]]></xsl:text>

</xsl:template>


text:
Q: Converting two columns of date and time data to one I have a simple data frame:
D <- c("2012/12/14", "2012/12/14")
Time <- c("18:40:37", "18:40:48")
df1 <- data.frame(D, Time)

I wish to combine the two columns of date and time information into one, preferable in the format of day, month, year, time.
How would I go about doing this?

A: A slightly shorter alternative could be:
df1 <- within(df1, { timestamp=strptime(paste(D, Time), "%Y/%m/%d%H:%M:%S") })
df1
       D     Time           timestamp
1 2012/12/14 18:40:37 2012-12-14 18:40:37
2 2012/12/14 18:40:48 2012-12-14 18:40:48

A: R> within(df1, { timestamp=format(as.POSIXct(paste(D, Time)), "%d/%m/%Y %H:%M:%S") })

           D     Time           timestamp
1 2012/12/14 18:40:37 14/12/2012 18:40:37
2 2012/12/14 18:40:48 14/12/2012 18:40:48

A: df1$TS <- as.POSIXct(paste(df1$D, df1$Time))

This will create an additional column TS in df1 that combines date and time and will be of type POSIXct. You can confirm by
str(df1)