緊急開催! パートナー様向け「Visual Studio 2015 製品説明会」 4 月 15 日@品川

2015 年中に発売が予定されている Visual Studio 2015。2015 年になって 3 ヶ月が過ぎ、パートナーの皆様にお伝えできる情報が少しずつ増えてまいりました。 そこで、パートナー様向けに Visual Studio 2015 のエディション構成や価格、ライセンス体系、そしてパートナー様にご活用いただける販売促進キャンペーンなど、お伝えしうる限りの最新情報をご案内する製品説明会を開催いたします。 2015 年 4 月 15 日 (水) 10:00 ~ 12:00 パートナー様向け製品説明会開催 Visual Studio 2015 は、クラスプラットフォーム開発を強力に推し進めており、Windows、Linux、iOS、Android といったさまざまなプラットフォーム向けのアプリケーションを構築することができるようになります。 この説明会では、こうした Visual Studio 2015 の新機能もご紹介いたします。 Visual Studio 2015 の世界観をご理解いただき、パートナーの皆様との協業をいっそう加速できればと思っています...(read more)

Posted by on 29 March 2015 | 9:00 pm

Azure App Service を発表

このポストは、3 月 24 日に投稿された Announcing Azure App Service の翻訳です。 モバイル ファースト、クラウド ファーストの世界で企業に求められているのは、顧客、パートナー、従業員が手元のデバイスを使用してどこからでもシームレスにデータにアクセスできるようにすることです。そして、開発者に求められているのは、複数のプラットフォームをサポートするアプリケーションを開発し、そのアプリケーションによってオンプレミスの情報システムやクラウドベースのサービスとの統合を実現したり、ビジネスやユーザーの成長に合わせたグローバルなオートスケールを実現できるようにすることです。そこで今回発表されたのが、Azure App Service という Azure の新しいサービスです。この記事では、アプリケーション プラットフォーム チームを代表して Azure App Service についてご紹介させていただきます。 App Service は、あらゆるプラットフォームとデバイスに対応する Web アプリやモバイル アプリの開発に使用できる新たなクラウド サービスです...(read more)

Posted by on 29 March 2015 | 8:30 pm

Introducing Dashba.com, where Marketing Research meets Customer Relationship

Guest post by Alex Arias, Managing Director, www.dashba.com 1. Why are you building this start-up? What does it do? We noticed there was a gap between advertising and marketing teams that could be  filled. Businesses usually struggle when advertising their solutions by keeping  the goals of advertising and product marketing teams separate. Marketing and advertising efforts should extend beyond leads and sales to valuable, continual feedback. This priceless feedback can in turn help to navigate future marketing and advertising direction, therefore increasing future sales and customer loyalty. Dashba assists in providing valuable insight to consumer behaviour, values and attitudes surrounding any brand, service or product. Dashba.com is a clean, straightforward platform built purely to create authentic and meaningful customer relationships.  2. What does a product marketing team need to understand from engineering about how to sell the product? Dashba has been built for private one on one communication with close audiences, which allows marketers to announce advertising, news and information to distinct stakeholders such as corporate employees, decision makers, and general public using full screen media assets on any device. Marketers retain full control of their brand’s image, meaning they can manage users’ reviews and messages, reward users, generate new customers and foster beneficial relationships with employees and consumers, learning and improving at the same time their advertising campaigns. For consumers in general, Dashba is a great way to connect with their favourite brands, learn about new products, provide valuable feedback and get access to exclusive products, samples, discounts, events and win prizes through promotions. All in all, Dasbha is a full service platform that benefits both the companies and customers by fostering meaningful relationships, rather than just a click of a like button. 3. What impact or legacy do you hope to make in the market and in the business world? We understand that companies have a need to advertise their products and solutions, and they have turned to online and social channels to do so. Often this has created some issues with consumers which have seen that advertising has become more intrusive in their social experience and with less quality or without real value for them. Many bad examples can be found on social media, and as such we believe that our efforts will help both ends to create, communicate and receive the right advertising, using the right channel and giving consumers what they are really interested in. A good advertisement via the right channel means happy customers ready to do happy businesses. 4. What advice do you have for anyone wanting to start a business in your country? The first step would be to have a good understanding of the industry where you are going to compete, and learn everything about the market that you are looking to offer your product in. Market research, UX research, consumer perception and product/market fit are the keys to start a new business. After that, get surrounded by a good team, not only smart and capable people with their skills up-to-date but also committed to what the business is creating. They have to believe in your product so that your company has a strong foundation to build upon. 5. How do you work with investors, or do you currently use any outside money at all? We haven’t yet used any outside money, however, we believe on growing our business consistently so that we are always ready to present and discuss opportunities with investors, VCs and advisors in order to get their feedback, further advice and networking in general. If investment is an opportunity we will discuss it. On the other hand, we are actively looking for partnerships with major media agencies, publishers and advertising companies that can utilise our platform to benefit their customers and make the whole process seamless. 6. Why would an entrepreneur turn to Microsoft for help in building scale, a team, or using software? Many years ago Microsoft was also a small business; as such I do believe Microsoft has the spirit, expertise, products and skilled people working everyday to help entrepreneurs to grow their business. Microsoft’s solutions are worldwide accepted with a proven track of successful companies using them and that’s enough guarantee of the quality that you will add to your business.

Posted by on 29 March 2015 | 7:02 pm

[まとめ] SQL Server Japan Support Team Blog インデックス

★Welcome to Microsoft SQL Server Japan Support Team Blog ==================================== ■1. 一般情報 ◆a. SQL Server Update 情報 ◆b. DO’s&DONT’s やった方がいいこと やらない方がいいこと ◆c. How to系 ◆d. 若葉マークブログ ◆e. Known issue ◆f. SQL Connectivity ■2. SQL Serverエンジン ◆a. ツール ◆b 機能 ◆c. SQL トラブルシューティング ◆d. インストール/アップグレード/アンインストール ■3. SQL Database (Azure) ■4. Analysis Services ■5. Reporting Service ■6. データアクセス ◆a. ADO.NET ◆b. ADO ◆c. JDBC ■7. Integration Services ■8. PowerBI ■9. イベント・お知らせ ==================================== ■1. 一般情報 – a. SQL Server Update 情報 1. SQL Server の最新モジュール情報 (まとめページ) 2. SQL Server の更新プログラム Topへ ======================== ■1. 一般情報 – b. DO’s&DONT’s やった方がいいこと やらない方がいいこと 1. DO's&DONT's #1: やらない方がいいこと – 運用環境で、Profiler GUI を使用してトレースする 2. DO's&DONT's #2: 絶対にやらなければいけないこと - データ型を一致させる 3. DO's&DONT's #3: やらなければいけないこと - 非典型的パラメータ値が存在する場合の再コンパイル (Atypical Parameter Problem ... 4. DO's&DONT's #4: やらない方がいいこと - クエリの 条件句 (WHERE や JOIN ON 等) で参照されている列の加工 5. DO's&DONT's #5: やっておいた方がいいこと - SQL Azure アプリケーションでは Activity ID を記録しておく 6. DO's&DONT's #6: 絶対にやってはいけないこと – ストアドプロシージャ内でのパラメータ値の変更 7. DO's&DONT's #7: やらない方がいいこと - インデックス再構築 (REBUILD) 後のデータファイル圧縮 (SHRINK) 8. DO's&DONT's #8: やってはいけないこと - インデックス再構築 (REBUILD) 後のインデックス統計情報更新 (UPDATE STATISTICS) 9. DO's&DONT's #9: やらない方がいいこと - ディメンションのキー属性として末尾に全角スペースが格納される恐れがあるカラムを利用する。 10. DO’s&DONT’s #10: やらない方がいいこと - クエリの条件句で変数を参照する 11. DO’s&DONT’s #11: やってはいけないこと - トランザクションログファイルの拡張サイズを極端に小さくする 12. DO’s&DONT’s #12: やった方がいいこと - max server memory を設定する 13. DO’s&DONT’s #13: 絶対にやってはいけないこと - ORDER BY が指定されていないクエリの結果が一定の順番に並んでいると仮定すること 14. DO’s&DONT’s #14: 絶対にやってはいけないこと - ひとつの CPU に対して affinity mask と affinity I/O mask の両方 ... 15. DO’s&DONT’s #15: やってはいけないこと - クラスタ SQL Server をサービスとして操作すること 16. DO’s&DONT’s #16: やってはいけないこと - ログ配布プライマリデータベースのログバックアップ 17. DO’s&DONT’s #17: やっておいた方がいいこと - tempdb データファイル数を CPU 数に一致させる 18. DO’s&DONT’s #18: やった方がいいこと - .NET Framework アプリケーションでパラメータクエリを実行する場合にはパラメータのデータ型やサイズ ... Topへ ======================== ■1. 一般情報 – c. How to系 1. システム データベースのリストア手順 2. [PowerPivot][HowTo] SharePoint 2013 で PowerPivot for SharePoint を使用する方法 3. 非ドメイン環境上のサーバー間でミラーリングを構築する方法について 4. SQL Server の手動アンインストール手順 5. SQL Server 2008 R2 Service Pack のクラスター環境への適用手順 6. Tips:SQL Server の Log フォルダの位置の確認方法 7. HowTo: BID トレース - データアクセス アプリケーションのトレースを採取する 8. ODBC API を使用して mdb ファイルからメモ型データを取得する方法 9. バックアップからのリストアによるリカバリ手順 10. Windows Vista 以降の OS 上で SQL Server 2008 SQL Server 2008 R2 から DTS パッケージ デザイナ を使うには 11. How To:Ghost Record を確認する方法 12. SQL Server SysPrep の注意事項と実行手順 13. 64 ビットSQL Server から SQL Server 2000 へのリンクサーバー設定について 14. [Linux] BCP で 2GB 以上のサイズのファイルをインポートするには 15. SQL Server Profilerを使用して、取得したPowerPivot 実行時のトレースを確認する方法 16. 実行プランを読む - 基本編 (その 1) 17. 実行プランを読む - 基本編 (その 2) 18. 実行プランを読む - 基本編 (その 3) 19. 実行プランを読む - 基本編 (その 4) 20. 実行プランを読む - 活用編 (その 1) – クエリチューニング 21. 実行プランを読む - 活用編 (その 2) - クエリパフォーマンス悪化の原因 22. SQL トレーススクリプトの作成、実行 (SQL Server 2000) 23. SQL トレーススクリプトの作成、実行 (SQL Server 2005, 2008, 2008 R2) 24. HowTo: Management Studio を使ってトランザクションログファイル (ldf) のサイズを小さくする方法 25. Oracle 経験者のための SQL Server HowTo #1: 拡張イベントを使って On-Error Dump を取得する 26. Oracle 経験者のための SQL Server HowTo #2: サーバートレースを使ってセッション・レベルのSQLトレースを取得する 27. オンプレミスのSQL Server データベースのバックアップ先としてクラウドを活用しよう 28. PowerPivot for Excel: SQL Server 認証ユーザーのパスワード保存について 29. デッドロックを避けるコツ 30. SQL Server Data Tools の入手 Topへ ======================== ■1. 一般情報 – d. 若葉マークブログ 1. [若葉マークブログ] 第 1 回 : トランザクションとは 2. [若葉マークブログ] 第 2 回 : ロックとは 3. [若葉マークブログ] 第 3 回 : システム データベースとは Topへ ======================== ■1. 一般情報 - e. Known issue 1. KB 2007728 - Error message when you use SSL for connections to SQL Server: "The cer ... 2. IEの制限の影響によりWCF Data Services クライアントにおいて、300秒で'System.InvalidOperationException'が発生することがある 3. [Windows XP] 暗号化され����� SQL Server Compact Edition データベースに対してアクセス遅延が発生することがある 4. Known Issue: SQL Server 2008 フェールオーバクラスタのアンインストールに失敗する 5. クエリ ビルダーで作られたクエリを実行すると構文エラーが発生する 6. [*.rdlc] エクスポートした PDF の文字化け ~ 確認ポイントの鍵はシステム構成要素にあり ~ 7. osql での DBCC CHECKDB 結果に "SQLGetDiagRec failed" が大量に出力される 8. SQL Server Profiler ツールの LoginName 列に無効化している“sa” ログインが出力される 9. SQL Server 起動完了後のエラー 18456 「ユーザー 'XXX' はログインできませんでした。 理由: 明示的に指定されたデータベースを開けませんでした。」 10. Known Issue: SQL Server 2008/SQL Server 2008 R2 インストール時に "Visual Studio - VsTemplat ... 11. SQL Server 2008 および SQL Server 2008 R2 の不具合修正情報の公開 – 照合順序のバージョンが 90 の場合、誤った実行結果が返ってくる事象に ... 12. Halloween Protection (HP) について 13. DBCC SHRINKFILE 実行時のメッセージ 14. データベースの所有者が確認できない影響 15. CLR オブジェクト開発時の注意点 16. 透過的なデータ暗号化 (TDE) 環境のミラーリングの構成でエラー 927 17. SQL Server 2005 Management Studio の [ログインをロックアウトする] チェックを外した際の注意点について 18. FAQ:実行時間の長い I/O を示すエラー833について 19. 状態 または エラー ID が 29 のエラー 18056 20. エラー666 21. SQL Server 2012 BCP ユーティリティ 使用時の警告 “フォーマット ファイルを使用して BCP インポートを行うと、区切り列内の空の文字列が NULL に変換 ... 22. SQL Server 2000 MSDE から 上位バージョンへのアップグレードについて 23. SQL Server 2012 構成ファイルの分散再生クライアントのオプションについて 24. NVARCHAR/NCHAR データ型の列に格納されるデータが?になる Topへ ======================== ■1. 一般情報 - f. SQL Connectivity 1. Troubleshooting Connectivity #1 - SQL Server への接続 2. Troubleshooting Connectivity #2 - エラー情報からわかる失敗原因 3. Troubleshooting Connectivity #3 - 予期しない接続切断 4. Troubleshooting Connectivity #4 - 接続エラーの調査方法 5. Troubleshooting Connectivity #5 - セッション��立までの動作 6. Troubleshooting Connectivity #6 - 接続タイムアウトは悪なのか? 7. [SQL Connectivity] Case Study : クラスタ化された構成の SQL Server 2008 Service Pack 1 以前のバージョンの名前付き ... 8. [SQL Connectivity] Case Study : 認証 DC ダウン時の SSPI エラーについて 9. [SQL Connectivity] 名前付きパイプでの接続時トラブルシューティング 10. Troubleshooting Connectivity #7 - 接続タイムアウトエラーまでの時間は? Topへ ======================== ■2. SQL Server エンジン – a. ツール 1. [SDP] 情報採取ツール Support Diagnostic Platform 2. Kerberos Configuration Manager for SQL Server 3. SQL Server 2012 BCP ユーティリティ 使用時の警告 “フォーマット ファイルを使用して BCP インポートを行うと、区切り列内の空の文字列が NULL に変換 ... 4. HowTo: Management Studio を使ってトランザクションログファイル (ldf) のサイズを小さくする方法 5. Oracle 経験者のための SQL Server HowTo #1: 拡張イベントを使って On-Error Dump を取得する 6. Oracle 経験者のための SQL Server HowTo #2: サーバートレースを使ってセッション・レベルのSQLトレースを取得する 7. [SSMA] SSMA の動作環境についての推奨 8. [SSMA] SSMA for Oracle Extension Pack インストール時に「スカラー変数 “xxx” を宣言してください。」エラーが発生する。 9. SQL Server Profilerを使用して、取得したPowerPivot 実行時のトレースを確認する方法 10. Known Issue: SQL Server 2008/SQL Server 2008 R2 インストール時に "Visual Studio - VsTemplat ... 11. SQL Server Profiler ツールの LoginName 列に無効化している“sa” ログインが出力される Topへ ======================== ■2. SQL Server エンジン – b. 機能 1. recovery interval 構成オプションは何を指定するオプションなのか 2. 照合順序 - 文字の比較と並び順 (その 1)  3. 照合順序 - 文字の比較と並び順 (その 2)        4. DOPは並列クエリで使用されるスレッド数ではない       5. SQL Server 2012/2008 R2 新機能: 列変更カウンタ (colmodctr)        6. クエリタイムアウト - その仕組み       7. SQL Server のメモリ管理 - Part 4        8. SQL Server のメモリ管理 - Part 3        9. SQL Server のメモリ管理 - Part 2        10. SQL Server のメモリ管理 - Part 1 11. 排他ロックヒントを指定した行の列を読み取れる動作について 12. SQL Server 2012 におけるパーティションインデックス再構築時の統計情報更新 13. NUMERIC/DECIMAL の演算結果の有効桁数と小数点以下桁数 14. SQL Server における数値定数 2147483647 と 2147483648 の違い 15. DATETIME データ型のミリ秒に関する注意事項 16. FAQ: 32-bit/64-bit SQL Server 間でのユーザーデータベースの移動は可能? 17. FAQ: SQL Server 起動後、接続が可能となるタイミングは? 18. SQL Server へのメモリ割り当てを減らすと tempdb 使用量が増える?? 19. 統計情報の自動更新が ON の時には統計情報を手動で更新する必要はない?       20. 変数とパラメータの違い 21. CXPACKET 待ちは悪いことか? 22. インデックス再構築と再構成の違い 23. LSN とは? 24. 断片化について 25. インテントロックとは? 26. NVARCHAR/NCHAR データ型の列に格納されるデータが?になる 27. 統計情報更新処理をキャンセルした場合の動作 28. real および float データ型におけるアンダーフロー時の動作 Topへ ======================== ■2. SQL Server エンジン – c. SQL トラブルシューティング 1. SQL Server セットアップトラブルシューティング – 初級編 2. [SQL Troubleshooting] SQL Server トラブルシューティング 6 回シリーズのご案内 3. [SQL Troubleshooting] 第1回 : Tips - SQL Server エラーログとイベント ログを採取する (SQL 2000 ~ 2008 R2) 4. [SQL Troubleshooting] 第2回 : Tips -パフォーマンス ログ��採取方法 (Windows Server 2003 ~ Windows Server ... 5. [SQL Troubleshooting] 第3回 :パフォーマンスログの確認方法について 6. [SQL Troubleshooting] 第4回 サーバートレースの解析方法 – (1) 7. [SQL Troubleshooting] 第5回 サーバートレースの解析方法 – (2) 8. [SQL Troubleshooting] 第6回:ブロッキング情報を採取する (SQL Server 2000 ~ 2008 R2) 9. どうする? SQL Server のクエリ パフォーマンスが低下した!        10. デッドロック調査用の情報採取 11. バックアップが存在しない、または、バックアップからのリストアが行えない場合のデータベース復旧手順 12. 破損したデータベースからのデータ抜き出し方法 Topへ ======================== ■2. SQL Server エンジン – d. インストール/アップグレード/アンインストール 1. SQL Server 2008 R2 SP2 適用後のクエリ動作について 2. SQL Server 2000 MSDE から 上位バージョンへのアップグレードについて 3. SQL Server 2012 構成ファイルの分散再生クライアントのオプションについて 4. スクリプト アップグレード モード 5. SQL Server セットアップトラブルシューティング – 初級編 6. PowerPivot for SharePoint のサービスパックを適用する方法 7. SQL Server の手動アンインストール手順 8. SQL Server 2008 R2 Service Pack のクラスター環境への適用手順 9. クラスター環境にSQL Server をインストールする際、MSDTC をクラスター化する必要があるか? Topへ ======================== ■3. SQL Database (Azure) 1. [Windows Azure] ゲスト OS アップグレード後、ゲスト OS 上のSQL Server Native Client を使用している WebRole/Worker ... 2. Windows Azure で、Web ロールで特定のバージョンの SQL Server Native Client を常に使えるようにする方法 3. [Windows Azure SQL Reporting] Visual Studio でファイルエクスポートをするプログラムを書いてみよう 4. Windows AzureのIaaS機能でSQL Serverを使ってみよう 5. [SQL Database] デッドロックの調査方法について 6. [SQL Database] 接続タイムアウトの発生を改善したい 7. [SQL Database] Insert クエリにおいて使用制限されている Table ヒントについて 8. SQL Azure 高可用性を保持するための仕組み 9. WebロールからWindows Azure SQL Database にアクセスする (3/3) : Azure 管理者ポータルを使用したストレージの作成と Web ロールの配置 10. WebロールからWindows Azure SQL Database にアクセスする(2/3) : EDM を作成しよう 11. WebロールからWindows Azure SQL Database にアクセスする (1/3) : Azure 管理者ポータルを使用したテーブルの作成 12. Windows Azure で、Web ロールで特定のバージョンの SQL Server Native Client を常に使えるようにする方法 13. [SQL Database] 照合順序を指定したデータベース作成方法について 14. SQL Database にてスクリプトの生成が行えない 15. NVARCHAR/NCHAR データ型の列に格納されるデータが?になる Topへ ======================== ■4. Analysis Services 1. [SSAS] SQL Server Analysis Services トレース採取方法 2. Analysis Services のデータが '-0'(マイナスゼロ)と表示される 3. Known Issue: NullProcessing プロパティを Preserve にすると「Preserve は、個別のカウント メジャー 'XXXX' の有効な Nul ... 4. SQL Server 2005,2008,2008 R2 Analysis Services Standard エディションにおける使用可能な関数について 5. [SSAS] SQL Server Analysis Services メタデータマネージャー Error 発生時の対処方法 6. NULL データが含まれる場合の MDX 関数 BOTTOMCOUNT 使用の注意事項 Topへ ======================== ■5. Reporting Service 1. [SSRS] Reporting Services サービスが起動しない 2. [SSRS] HTML 形式で表示したレポートと PDF や印刷で表示したレポートの見栄えが異なる。対処方法は!? 3. [SSRS] SharePoint 統合モードのレポートサーバー構築手順 (単一サーバー) - SQL Server 2012 と SharePoint 2013 の組み合わせ) 4. [SSRS] SharePoint 統合モードのレポートサーバー構築手順 (単一サーバー) - SQL Server 2008 と SharePoint 2010 の組み合わせ) 5. [SSRS Troubleshooting] SQL Server Reporting Services トラブルシューティングのご案内 6. [SSRS]Reporting Services 使用時の TERADATA 拡張機能エラー 7. [SSRS] Reporting Services 文字化け:異なる OS 間の PDF 文字化け 8 [SSRS] レポートパラメータの位置や順序を変更できるか 9. [SSRS] Reporting Services の詳細ログ 10. [SSRS] SharePoint 統合モードのレポートサーバー構築手順 (単一サーバー) - SQL Server 2012 と SharePoint 2010 の組み合わせ) 11. [SSRS] SQL Server 2008 Reporting Services 不具合情報 – 1月1日に発生する イベント ID 123 について 12. [SSRS] [SQL Server 2008 以降のバージョン] ReportViewer のレポート表示後、印刷ボタン(アイコン)を押下すると「クライアントの印刷コントロー ... 13. [SSRS] Response.Redirect でページ遷移すると画像が見えなくなる(deleteAfterServicing パラメーター) 14. [SSRS] SQL Server 2008 Report Services で 3 つ以上のカスケード型レポートパラメータを設定したレポートを表示した場合、カスケード型レポー ... 15. Reporting Services のレポートで印刷を行うと「クライアントの印刷コントロールを読み込めません。」のエラーが発生する 16. Known Issue: Reporting Services への初回アクセス時に、レポート表示に時間がかかる。 17. How To:Reporting Services のレポートをコマンドで配置する方法 18. SQL Server 2008 R2 Reporting Services 不具合情報 – “値 'x' は無効です。有効な値は、'xx' から 'xxx' です。” 19. SQL Server 2008 以降の Reporting Services で総ページ数表記が “?” になる 20. SQL Server Reporting Services カスタムアセンブリの設定方法 21. [TroubleShooting] PowerPivot ギャラリーで PowerPivot ファイルを開くとエラーが発生する 22. [SSRS] SharePoint 統合モードのレポートサーバー構築手順 (単一サーバー) - SQL Server 2014 と SharePoint 2013 の組み合わせ 23. [SSRS] Reporting Services 文字化け:PDF の文字をコピーして貼り付けると文字化け 23. [SSRS] SharePoint 統合モードのレポートサーバー構築手順 (単一サーバー) - SQL Server 2014 と SharePoint 2010 の組み合わせ 24. [SSRS] Report Viewer コントロール 2010 Language Pack Service Pack 1 が修復インストールとなる 25. [不具合] SQL Server 2014 Reporting Services にて、パフォーマンスオブジェクト ReportServer:Service が動作しない Topへ ======================== ■6. データアクセス – a. ADO.NET 1. [ADO.NET] DataGridView 内のデータ編集とそのときのバインドした DataTable の動作 2. [ADO.NET/SNAC] イニシャル パートナーがダウンしている場合、フェールオーバー パートナーに接続できる確率を高める方法 3. 「タイムアウトに達しました。プールから接続を取得する前にタイムアウト期間が過ぎました。プールされた接続がすべて使用中で、プール サイズの制限値に達した可能性があります。」エラー ... 4 4. DO’s&DONT’s #18: やった方がいいこと - .NET Framework アプリケーションでパラメータクエリを実行する場合にはパラメータのデータ型やサイズ ... Topへ ========================  ■6. データアクセス – b. ADO 1. KB 2517589 / 2640696 : Win7 SP1 上でビルドした ADO を参照するプログラムが下位バージョン OS 上で動作しない現象と対処方法 (Ver 2.1) 2. Known Issue: ADO アプリケーションを Windows Server 2008 上で動作させると「要求された名前、または序数に対応する項目がコレクションで見つかり ... Topへ ========================  ■6. データアクセス – c. JDBC 1. [JDBC] JDBC ドラ��バーの Java 7 対応について 2. Microsoft SQL Server JDBC Driver は Android OS をサポートしない Topへ ========================  ■7. Integration Services 1. Known Issue: SSIS パッケージの TransactionOption オプションを Required とすると、パッケージの動作が停止しているように見える。 2. 64 bit 環境上における Oracle からデータ取得する Integration Services プロジェクト (SSIS パッケージ) の注意事項 - 開発編 3. [SSIS] パッケージログの出力方法 4. [SSIS] OLE DB プロバイダーを使用してフラットファイルをインポートすると正しくない結果となる 5. SQL Server Data Tools の入手 Topへ ========================   ■8. PowerBI 1. [HowTo] PowerBI for Office365 サイトのブックにある PowerView のデータ更新 Topへ ======================== ■9. イベント・お知らせ 1. [Info] 毎週水曜日はサポート・サービスデイ ~ 調布でお待ちしています ~(※オンラインも可能です!!) 2. [皆様のご意見募集しております!]サーバーおよびツール製品に関するインターナショナルユーザー アンケート 2013~「ローカライズについてモノ申したい方、大募集です!~」 3. 壁紙追加されました![期間限定Info]Windows Server 2012 先得早割キャンペーン(吉田健一氏コラボ壁紙全員プレゼントです!) 4. [重要なお知らせ] 2012 年 7 月 2 日 (月) から技術サポート窓口時間が変更になります 5. SQL PASS Summit 2011 at Seattle 6. db tech showcase 2012 Topへ

Posted by on 29 March 2015 | 7:01 pm

Let's Take a Road Trip to the Cloud.

19th March 2015   //   View as Webpage   //   Haven't subscribed yet? Join us! What can Azure do for Developers? You probably know that Azure can host and run Virtual Machines. Perhaps you also know that you can deploy Linux on Azure too, e.g. CoreOS, Suse, Ubuntu. Azure didn’t start out as an Infrastructure-as-a-Service hosting platform however; that capability was added later. Azure was initially built as a cloud platform to enable developers to build and scale applications that span Mobile, Cloud, and on-premises. The Azure cloud platform can supply you, as a developer, a set of ready-to-consume managed services so that you can focus on building great functionality instead of fiddling with infrastructure. Because these managed services are able to be provisioned with a few clicks, it’s easy to get them up and running leaving you more time to concentrate on building features into your app. Building app for iOS, Android, or Windows Phone? Azure Mobile Services can take the hard work out of things like broadcast push messaging, offline app data sync, and social integration. Azure Mobile Services has cross platform APIs that you can use to provide a streamlined experience across multiple platforms – streamlined for both Developers as well as End Users. Got some data you need to store? Azure has you covered. There are a number of data services ranging from fully managed Azure SQL Database, to DocumentDB – a highly-scalable NoSQL document database service, to Redis Cache for high throughput, low latency data access. How do you manage your application code, or measure application performance when running in the cloud? You can be up and running in minutes using Visual Studio Online and you can even integrate your favourite tools like Git. Plugging Application Insights into your app can give you visibility over performance and errors, right down to the block of code in your language of choice. There are many more services and building blocks in Azure. Find out more from the free developer jumpstart courses available on Microsoft Virtual Academy or head along to one of the upcoming MSDN NZ DevCamps in Auckland, Christchurch, or Wellington. Head on over and create your free trial with NZ$250 of credit to get you started, or activate your MSDN benefits to get free monthly azure credits worth up to NZ$2500/yr, and get developing! Regan Murphy Technical Evangelist Microsoft New Zealand Microsoft Student Accelerator Kicks off for 2015 at the MSA Showcase. Microsoft NZ celebrated student innovation on the 9th of March at the Auckland Town Hall, kicking off Microsoft Student Accelerator for 2015. Registrations for the programme are now open to students, supporters, and employers - new entrants welcome! Check out the full summary of the event, and have a look at the video to get a glimpse of the difference MSA is making at high school, tertiary and employer levels. Build 2015. Can't wait for Build 2015? Brush up on your knowledge of the Windows 10 universal app platform to prep for the big show. Join Build online April 29th - May 1st for live video streaming, and follow @BLDWIN for updates on the event. Diagnose and Debug Your Applications in Depth with the Support Portal. Join your guide Cory Fowler as he talks to the product teams in Redmond as well as the web community. The Support Portal is a Site Extension which provides a set of capabilities which help a developer Diagnose and Debug by providing an aggregate of the IIS and FREB logs. Updates to ASP.NET 5 Yeoman Generators for Beta 3. Microsoft Developer Network has updated the ASP.NET 5 yeoman generators to have the latest content based on ASP.NET 5 beta 3. Jeffrey Fritz covers the updates which are now available, and more information is available here. Have a Windows app project on the side? Show it off! Share it with the rest of the community in the Kiwi Windows Apps Facebook group or send us an email to nzdev@outlook.com. eResearch. 23rd, 24th & 25th March (QUEENSTOWN) eResearch NZ provides a place for anyone in the research sector to share works in progress and outcomes. This year, eResearch is going to Queenstown, set against the stunning views of Lake Wakatipu. Find out more. Microsoft Developer Cloud Essentials. 24th March (AKL), 26th March (CHCH) At this DevCamp you will learn about some of the best features and services of Microsoft Azure and how to build and move a variety of apps to the cloud. You will see how to build web sites, mobile applications, and enterprise-class applications. .NET User Group Meetup (Ellerslie). 25th March (AKL) Join us for some async goodness. Jordan Morris will present a simple and unapologetically-prescriptive set of guidelines for writing stable asynchronous code using the TPL and async/await keywords. NodeConf Christchurch. 28th & 29th March (CHCH) Explore Node.JS' event driven architecture, in a city of event driven architecture. Startup Weekend. 10th - 12th April (WEL) Startup Weekend is where entrepeneurs, developers, and designers get together to form new businesses in a 54-hour marathon of inspiration, perspiration, collaboration, and fun! We attract people with all skill levels in a friendly, welcoming, yet challenging environment. Full details on the event are available here. Road to the Cloud. 16th April (AKL) Business leaders of independent software vendor organisations (ISVs) face increasing challenges in today's software market. Join this event to learn from your peers in the industry that have leveraged the benefits of the cloud to build a successful business. This event is focused on business strategy, and is not a technical learning event. Microsoft Developer Cloud Essentials. 20th April (WEL), 29th April (AKL) At this DevCamp you will learn about some of the best features and services of Microsoft Azure and how to build and move a variety of apps to the cloud. You will see how to build web sites, mobile applications, and enterprise-class applications. Codemania. 24th April (AKL) Codemania is for the passionate software developer. Get inspired by some amazing speakers at the conference, or attend their valuable workshops. There is plenty to see and learn! Successful developers are always upgrading their skills. Microsoft Virtual Academy (MVA) offers online Microsoft training delivered by experts. Watch videos, download PowerPoint slides and test yourself as you learn at absolutely no cost. If you want to learn something different, head over to MVA here! Don't forget, the MVA Lite app is now available, so you can now learn anywhere at anytime! Here are the courses your Microsoft Technical Evangelists recommend this week: Practical Performance Tips to Make Your HTML/JavaScript Fast. Want to maximise the performance of your modern websites and apps with JavaScript and HTML5? This Web Development Wednesdays course has the strategies, tips, and tricks you need, along with helpful demos and best practice guidelines. Windows 10 Technical Preview Fundamentals. Be prepared for Windows 10 by getting familiar with the fundamentals. Learn about new UI enhancements, find out how management and deployment is evolving, and hear about how new security enhancements in Windows 10 can help your organisation respond to the modern security threat landscape. Microsoft Azure Fundamentals. Not familiar with Microsoft Azure? This course will give you the foundations to begin your cloud journey. Join Bob Tabor as he delivers the first four courses that teach you the fundamentals of Microsoft Azure. © 2015 Microsoft Corporation    Terms of Use ::: Trademarks Microsoft respects your privacy. To learn more, please read our online Privacy Statement. If you would prefer not to receive this newsletter any longer, click here to unsubscribe. To set your contact preferences for other Microsoft communications click here. The Privacy Officer // Microsoft New Zealand Ltd, PO Box 8070 Symonds St, Auckland 1150, New Zealand

Posted by on 29 March 2015 | 3:12 pm

云计算设计模式指南系列(0) - 背景简介及内容提要

  大家好。这个博客很久没有更新了,这半年多来在工作重心上有所变动,现在主要还是研究Azure以及服务端开发这块了。不过最近WindowsApp方面的变化的确令人激动,今后在App开发这块应该还会持续关注。我们准备开始撰写若干篇关于云计算以及Azure的博客文章,暂定名《云计算设计模式指南》,这是第0篇,主要是给大家介绍一下我们的想法以及作为系列文章的目录。   首先必须向Patterns & Practices(模式与实践,P&P)小组及其Cloud Development系列致敬。我们希望有更多的开发者能够关注到P&P的Cloud Design Patterns: PrescriptiveArchitecture Guidance for Cloud Applications。该系列中包含了24个云计算设计模式以及10个通用场景的设计指导。这里所讲的设计模式并不是指类似经典GoF的设计模式的侧重面向对象、软件工程方面的设计指引,而是联系云计算环境的一些特质和优势所作出的架构设计层次最佳实践。可贵之处在于,事实上其中涉及到Azure的功能、服务方面的内容并不占太多篇幅,更多的只是在描述某个场景的最佳实践的同时,提及对应的在Azure中能通过哪些服务组件来完成目标。所以该系列文章老少咸宜,不管开发者关心的是不是Azure或是.Net,都将从中受益。   言归正传,正值Azure在中国大陆正式商用一周年之际,我们最近也在构思一系列的关于Azure以及云计算架构设计方面的中文博客文章,内容主要来自于平时的实践和积累,所以在引用和翻译到一些Azure官方和非官方的文档资料的同时,还会尝试加入一些个人的观点、学习笔记以及样例代码、项目。早些在学习前文所提到的Cloud Design Patterns系列的时候就已经向几乎身边所有关心Azure的同事朋友强烈推荐阅读。   我们在日常工作中接触到不少国内外的Azure用户,主要还是把Azure平台当做IDC托管机房来用,没有或者来不及考虑利用一些Azure所提供的非常优秀的特性和服务来优化开发和降低运维成本。现在提笔写这个系列文章的最主要的一个动机是希望更多的开发者在接触到云计算特别是Azure的时候,除了IaaS 的VM、Networking等基础设施的迁移之外,能够在开发设计层面重新审视一下当前的实现和架构是否已经充分利用到了云平台的优势,是否能够适应分布式计算存储、易伸缩等架构特性。   以下是我��到的内容大纲,不保证坑会被完全且按次序在接下来几个月中填满,但一定尽力。   Cache-Aside。考虑将一个传统Web 服务的满足横向扩展(scale out)的特性并迁移到云端的第一步往往是检查其缓存机制,这里并不是指狭义上的页面缓存或是数据缓存,而是包括了应用逻辑是否会依赖于某个特别计算实例内的磁盘内容、内存对象、全局变量和缓存数据等等。Azure提供了多种缓存服务但当前官方推荐的是使用Redis Service,不仅功能强大而且Client API通用,我们可以通过Linux或Windows Server VM来部署自己的Redis服务。   Competing Consumer,Priority Queue,Queue-based Load Leveling Pattern,SchedulerAgent Supervisor Pattern等多方消息传递和分发的相关模式。不同节点之间的通讯消息,在经过队列Queue或主题Topic的缓冲和分发之后,能够极大程度上提高消息传递的效率和可靠性。Azure中消息队列服务我们一般会用到Service Bus。消息传递是个非常大的主题,我们将联系实例场景用最基础的代码演示Service Bus对以上这几个经典场景模式的实现。   Retry pattern。在公有云的环境中,整套解决方案中所涉及的包括虚拟机、网站、存储、数据库、消息队列等等服务可能散落在多个机柜甚至数据中心,而各个服务所在的物理宿主可能被多个实例共享,数据包也可能会被高负荷的网络所临时阻塞。所以在服务间互相调用的时候会有一定几率临时性地产生一些极短暂的错误(transient error),而这些错误往往并不是服务器这段的问题,且只需毫秒级别的等待重试就能解决问题。为了程序能够平稳运行,我们需要能识别这些transient error并加入重试Retry的相关机制。   Cost Effectiveness Design成本效益最大化设计。了解Azure的计费模式介绍、制定缩放计划、识别缩放单元Scale Unit、通过Management API进行自动化操作和管理将会显著降低运维成本,这些特性也是云平台同托管机房的最大的优势。而在功能实现层面,我们可以通过Azure平台或SDK内建的诊断工具(Diagnostics)集中记录和分析服务的运行情况,以分析最优的部署和缩放方案。同时某些细节功能的优化实现也能提高服务接口的吞吐量,更高效合理地利用带宽和存储资源。   NoSQL非关系型数据库实践。同传统关系型数据库相比,主流的NoSQL解决方案在可扩展性、高可用性、并发查询等方面有极大优势,键-值的基本存储和查询方式也允许表内数据结构可变(Schema Free),更能适应海量以及非结构数据的大规模存储查询的需要。 Azure提供了StorageTable、DocumentDB等NoSQL服务,亦可自行在Linux VM上部署Mongo DB。   Troubleshooting Azure故障排错的方法和工具。日常工作中我们需要同客户一起解决Azure使用过程中碰到的问题。有时我们通过查询数据中心端能够定位问题所在,但是更多时候我们会通过一些更高效的方法来帮助排错。而这里所涉及到的一些工具和方法本身其实并不局限于MSFT内部或付费客户。   同时,我们当前正在开发一个原型项目(POC)。初步想法是构建可随时缩放、扩展的爬虫集群,从外部数据源抓取数据,存储到本地的数据库。最终客户端能够通过API查询数据。抓取操作可以实时响应客户端要求,也能按照既定计划由专门的任务服务器所统筹。这个项目需要运用到多种云计算设计模式和场景,也会涉及到Azure的多个服务,包括Websites/WebRole/WorkerRole/ServiceBus/DocumentDB/Redis/APIManagement等。待代码相对稳定成熟后会发布源代码和相关文档。。   其他方面之后亦会随时补充。     文章目录索引 (最后更新3/30): 云计算设计模式指南系列(0) - 背景简介及内容提要 …

Posted by on 29 March 2015 | 1:17 pm

Release Management–Releases failing with Error: (404) Not Found.

Recently one of the customer reported that the releases are failing with following stack trace. Essentially releases were failing while sending email notifications to the release step approvers. Message: The remote server returned an error: (404) Not Found.: \r\n\r\n at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult) at Microsoft.TeamFoundation.Release.Data.WebRequest.PlatformHttpClient.EndGetResponse(IAsyncResult asyncResult) at Microsoft.TeamFoundation.Release.Data.WebRequest.RestClientResponseRetriever.EndGetAsyncMemoryStreamFromResponse(IAsyncResult asyncResult, IPlatformHttpClient platformHttpClient) at Microsoft.TeamFoundation.Release.Data.WebRequest.RestClientResponseRetriever.EndDownloadString(IAsyncResult asyncResult, IPlatformHttpClient platformHttpClient) at Microsoft.TeamFoundation.Release.Data.WebRequest.RestClient.EndPost(IAsyncResult asyncResult) at Microsoft.TeamFoundation.Release.Data.Proxy.RestProxy.HttpRequestor.<>c__DisplayClass1.<GetPostCaller>b__0(String url, String body) at Microsoft.TeamFoundation.Release.Data.Proxy.RestProxy.BaseNotificationServiceProxy.SendNotification(Int32 releaseId, String releaseName, String applicationVersionName, String stageTypeName, String environmentName, Int32 releaseStepId, Int32 releaseStepTypeId, Boolean releaseStepIsAutomated) at Microsoft.TeamFoundation.Release.Workflow.Services.ReleaseWorkflowService.CreateNextReleaseStep(Release release, Stage stage, StageStep stageStep, Int32 releaseStageRank, Int32 trialNumber) at Microsoft.TeamFoundation.Release.Workflow.Services.ReleaseWorkflowService.Initiate(Release release) at Microsoft.VisualStudio.Release.ViewModel.ViewModels.ReleaseViewModel.<StartRelease>b__85(Object sender, DoWorkEventArgs args) at Microsoft.VisualStudio.Release.ViewModel.ViewModels.ReleaseViewModel.PerformActionAndRefresh(DoWorkEventHandler action, Boolean selectViewEditorBasedOnReleaseStatus) at Microsoft.VisualStudio.Release.ViewModel.ViewModels.ReleaseViewModel.StartRelease()   It turned out to be the releases were failing because the release name contained special character ‘#’ due to which POST Call URL was getting truncated after ‘#’ char. By URL specifications, “#” is a reference to the start of the current document. Thus, the character "#" should be excluded in that are passed in the URL because it is used to delimit a URI from a fragment identifier in URI.   For Example, let say release name is “My Release #1”. While constructing SendNotification(Email notifications to the step approver) POST Call we expect below URL POST  http://rmserver:1000/account/releaseManagementService/_apis/releaseManagement/NotificationService/SendNotification?releaseId=1&releaseName=My%20Release%20#1&applicationVersionName=ReleaseTemplate1&stageTypeName=Stage1&environmentName=Environment1&StepId=1&releaseStepTypeId=1&releaseStepIsAutomated=True But due to special meaning of ‘#’ character, URL is truncated and below invalid POST call is made for SendNotification service. POST  http://rmserver:1000/account/releaseManagementService/_apis/releaseManagement/NotificationService/SendNotification?releaseId=1&releaseName=My%20Release%20    The above issue will occur if if any of the artifacts like ReleaseName, ReleaseTemplateName, StageTypeName or EnvironmentName contains special characters like ‘#’. The workaround for now is please refrain from using special characters like ‘#’ in any of the artifacts like Release Name, Release Template Name, Stage Name, Environment name etc. till this gets fixed in the future release of the Release Management product.   Thank You.

Posted by on 29 March 2015 | 11:29 am

Обновление приложения ASP.NET 3.5 до ASP.NET 4.5 и сопутствующие проблемы: общая система аутентификации с использованием форм.

Мне часто приходится заниматься проблемами миграции старых приложений ASP.NET на более новые версии. И независимо от того насколько много документации по этому поводу предоставляет Microsoft и насколько богатый опыт накопился у сообщества за последнее время, невозможно избежать новых проблем на которые тратится много человеко-часов. Даже несмотря на то, что статьи в MSDN описывают проблемы миграции в розовом цвете, реальность всё же сильно другая. Именно решению подобных проблем будет посвящён данный цикл статей, точнее весь мой опыт который накопился за всё это время. В данной статье будет рассмотрен случай переноса веб-приложения ASP.NET 3.5 на платформу ASP.NET 4.5.1 и проблема разделения куки-файла аутентификации (стандартно это .ASPXAUTH cookie) между разными приложениями. Как известно, ASP.NET поддерживает проверку подлинности с помощью форм в распределенной среде: либо между приложениями на одном сервере, либо на веб-ферме. И данная возможность часто используется в крупных веб-приложениях. Проблема в общих чертах вглядит так, у нас есть несколько веб-приложений ASP.NET 3.5 работающих в веб-ферме, назовём их A, B, С, D, E. Для всех из них используется единый механизм аутентификации и авторизации на основе форм. Приложение A основное, у остальных отсуствует собственная логика системы авторизации и аутентификации, они разделяют её с A. Нам нужно перенести A, B, С, D с ASP.NET 3.5 на ASP.NET 4.5.1, E оставляем. Начинать можно с данного руководства, на пути будет много препятствий (сильно специфичных для проекта, но данная статья только об одном), которые нужно будет преодолеть с помощью могучего интернета (полезными также будут вот эта документ и это руководство). Допустим всё проходит гладко, ну или почти всё. Открываем наш сайт A, логинимся, переходим на сайт B, нас туда не пускают. Самое главное, всё отлино работает на старой платформе. Пытаемя выяснить причины.  Первым делом проверяем идентичность настроек секций <authentication> и <machineKey>. <authentication mode="Forms"> <forms path="/" loginUrl="~/Default.aspx" protection="All" domain=".mydomain.com" timeout="2000" name=".ASPXAUTH" slidingExpiration="true"> </forms> </authentication> <machineKey validationKey="A2734932DA6EE8B5917A35C2BA8536DE3E14074C415EE45417CD7" decryptionKey="4171F954D13C3C2DDF7C3551283C4" validation="SHA1" ></machineKey>   Обратите внимание, что в примере, для экономии места, приведены фиктивные значения validationKey и decryptionKey, реальные же намного длинее. Убедившись что всё идентично, запускаем приложения, не работает аутентификации. Разница платформ, однозначно да. Смотрим логи сервера, находим: Event code: 4005 Event message: Forms authentication failed for the request. Reason: The ticket supplied was invalid. Нужно проверить настройки IIS, не была ли включена генерация случайных ключей на уровне IIS, также нужно проверить аккаунты от имени которых работают пулы, на идентичность. Была и такая проблема с приложениями C и D, решение описано здесь. Те кто регулярно наблюдал и наблюдает за изменениями в платформе .NET наверняка помнят, что в .NET 4.5 были внесены криптографические улучшения остальным пришлось бы потрать больше времени в поисках. Прочитав все три части становится понятно, откуда может быть проблема, дело в арибуте targetFramework узла <httpRuntime targetFramework="4.5.1" />. Он попросту отсутствует в старых версиях web.config, хотя присутствует по умолчанию в новых. Как и почему, всё описано здесь. А что касается приложения E, его по тем или иным причинам невозможно перенести на новую платформу. В этом случае возникает другая проблема, проблема разных механизмов шифрования, котрая решается добавлением атрибута compatibilityMode в тег <machineKey compatibilityMode="Framework20SP1" />. Также была проблема и с requestValidationMode, решается удалением этого атрибута из <httpRuntime requestValidationMode="2.0" />. Значения атрибутов и элементов конфигурацй не были описаны детально, можно их найти в MSDN или по приведённым ссылкам. В итоге получаем, что общие решения не всегда работает, каждое приложени в своём роде уникально. Надеюсь, что данная статья окажется полезной, если вы сталкнётесь с подобным.

Posted by on 29 March 2015 | 9:15 am

Unity 5 Roadshow at Chevy Chase MD

Carl Callewaert from Unity is here at Microsoft’s Chevy Chase (Maryland) office to talk about the latest and greatest Unity 5.0, on Sunday March 29, 2015. Event Info: https://unity3d.com/events/unity-5-roadshow-dc RSVP: http://www.eventbrite.com ...read more...(read more)

Posted by on 29 March 2015 | 9:07 am

Small Basic - About Fonts

About Fonts A font’s a group of characters that share a style, called a typeface. For example, Times New Roman and Courier New are typefaces. A font’s also characterized by its size. In typography, the size of a font’s measured in points, where each point’s about 1/72 inch tall. For example, in a 12-point font, each character’s height is about 1/6 inch. But when you use any font in a graphics window, the height of the characters depends on the type of monitor you have. Some fonts are stored on the hard disk as images; these are called raster fonts. MS Sans Serif is one example. These fonts look best when they’re drawn using their default font sizes. If you use a non-default font size, they’ll be scaled (enlarged or shrunk) to fit, but the result probably won’t look good. Other fonts are stored on the hard disk as mathematical formulas, along with information that tells your computer how to display them. You can scale these true type fonts (like Times New Roman, Courier New, and Arial) to any size you want. Use the FontName property of the GraphicsWindow object to tell Small Basic which font typeface you want. If you give it the name of a font that isn’t installed on your computer, then Small Basic picks an installed font that it thinks is similar to the one you set. Even though the font isn’t what you wanted for your application, your program should still work. But if you want to be sure you know what your text will look like, design your applications using fonts that are already installed on most computers. See the “Recommended Fonts” for more details.   Small and Basically yours,    - Ninja Ed & Majed Marji

Posted by on 29 March 2015 | 5:59 am

Small Basic - About Hexadecimal Pen and Brush Colors

You can set RGB colors using the BrushColor property of the GraphicsWindow object. Every color’s made up of three values, written in the hexadecimal number system (or hex, for short). In decimal, the number system you’re probably most familiar with, each digit can have a value from 0 to 9; in hex, you can still use digits 0 to 9, but you can also use A, B, C, D, E, and F, representing the decimal numbers 10, 11, 12, 13, 14, and 15. In an RGB color, each pair of hex digits represents a color value. From left to right, those are red (R), green (G), and blue (B), as shown in the Figure below. Together, these three components make a color identifier. Figure: Selecting a color by its red, green, and blue components As you change those digits, you’re actually changing a color! For example, in the Figure above, the color value 0000FF gives you pure blue, because FF is the highest a pair of hex digits can be and the other two pairs are just zeroes. The Figure also shows how you’d make green and red; what color identifier would you use to make purple? Try different combinations of digits and see what colors you can make! Note: We’ve covered all you need to know to get started with colors in hexadecimal, but if you want to learn more, head to Small Basic: Color for an overview and to Small Basic Getting Started Guide: Appendix B: Colors for a list of hexadecimal colors! But if you don’t like the hex format, you can just use the GetColorFromRGB() method, instead: GraphicsWindow.GetColorFromRGB(red,green,blue) The three arguments of the GetColorFromRGB() method set the red, green, and blue values of your color. You can pass any three values between 0 and 255. The higher the value, the brighter your color! The method returns a color identifier that you can use to set the brush or pen color. For example, this next statement sets the pen’s color to bright yellow by combining red and green: GraphicsWindow.PenColor=GraphicsWindow.GetColorFromRGB(255,255,0) Another method that makes dealing with colors easy is GetRandomColor(). This method doesn’t have any arguments; it returns a randomly selected color. Go ahead and try it out!    Small and Basically yours,     - Ninja Ed & Majed Marji

Posted by on 29 March 2015 | 4:31 am

Un autre "petit nouveau" :-) Bienvenue à DocumentDB !

Comme souligné dans un précédent billet, la récente conférence Strata + Hadoop World 2015, nous donne le prétexte ;-) pour revenir sur une actualité proche. Nous ne l’avions pas fait depuis un certain temps il est vrai… Comme le titre de ce billet l’indique, nous souhaitons rapidement introduire ici le “nouveau” service Azure DocumentDB. Disponible actuellement en version préliminaire publique, DocumentDB sera en disponibilité générale dès le 8 avril prochain comme récemment annoncé. (En démarrant dès aujourd’hui, vous n’avez aucune inquiétude à voir votre compte sera automatiquement migré vers la nouvelle offre en disponibilité générale.) Pour faire une rapide présentation (plus ici), Azure DocumentDB est un service Cloud géré de base de données NoSQL (“not only Structured Query Language”) orienté documents conçu pour les applications modernes métier (web et mobiles) d’aujourd’hui ;-) Ce dernier est ainsi conçu de toutes pièces pour prendre en charge de manière native les documents JSON (JavaScript Object Notation) en fournissant un ensemble riche de fonctionnalités de traitement de données finement optimisé pour le modèle de données JSON. DocumentDB vous permet ainsi de parcourir rapidement les schémas et est optimisé pour les applications mobiles ainsi que pour les applications web/Node.js côté serveur. Le service adopte l'ubiquité des langages JSON et JavaScript, éliminant ainsi les non-correspondances entre le type d'application et le schéma de base de données. Une intégration approfondie de JavaScript directement dans le moteur de base de données permet aussi aux développeurs d'exécuter la logique applicative de manière efficace et directement au sein du moteur de base de données pour une transaction. Azure DocumentDB fournit de manière cohérente des lectures et des écritures rapides, la flexibilité de facto des schémas et la possibilité de mettre à l'échelle facilement une base de données à la demande, service cloud oblige. DocumentDB autorise les requêtes ad hoc complexes à l'aide du langage SQL, prend en charge des niveaux de cohérence bien définis et offre un traitement de transactions multi-documents intégré en JavaScript utilisant le modèle de programmation familier des procédures stockées, déclencheurs et fonctions définies par l'utilisateur. Votre curiosité est aiguisée ? Pour en savoir plus et une vue d’ensemble du service, nous vous invitons à lire le livre blanc Présentation de DocumentDB - Une base de données NoSQL pour Microsoft Azure (en anglais) qui couvre également les concepts fondamentaux suivants : Le modèle de données DocumentDB, Gestion des données NoSQL par les applications, Options pour équilibrer les performances de façon cohérente. Il s'agit du bon choix pour les applications modernes lorsqu'un débit prévisible, une faible latence et des requêtes flexibles sont indispensables. Ces applications modernes accèdent ainsi à la base de données via des opérations CRUD, des requêtes et un traitement JavaScript via une simple interface HTTP RESTful. La programmation dans DocumentDB s’avère donc simple, facile, ouverte. Elle ne nécessite pas de codage personnalisé ni d'extensions JSON ou JavaScript. Vous êtes directement opérationnel(le) grâce à un large éventail proposé de kits de développement logiciel (SDK) avec notamment la prise en charge de JavaScript, Java, Node.js, Python et .NET. Tout est fait dans le même temps pour s’assurer qu’Azure DocumentDB s’intègre aussi bien avec les autres services de données de la plateforme Microsoft Azure comprenant notamment Azure HDInsight et Azure Search. Azure DocumentDB est disponible en version préliminaire publique depuis le 27 octobre 2014 dans l’environnement d’exécution Cloud Microsoft Azure. Vous pouvez donc l’essayer dès maintenant depuis le nouveau portail de gestion Azure ici. Comme indiqué dans la capture d’écran ci-dessus, vous serez prêts dans le quart d’heure qui suit. Il ne vous reste plus qu’à prendre en main l’environnement et à commencer à l’utiliser. Vous pouvez pour cela vous référer au didacticiel disponible ici qui vous guidera dans vos premiers pas pour enchaîner ensuite avec la création de votre première application moderne Java, Node.js, Python ou encore ASP.NET. Vous ne disposez pas encore d’un abonnement Azure. Qu’à cela ne tienne, cliquez ici pour un environnement d’évaluation gratuit d’Azure. Dans l’intervalle, pour plus d’informations sur DocumentDB, nous vous invitons à aller lire ou relire les billets déjà publiés sur le Blog Microsoft Azure. N’oubliez pas non plus le Forum MSDN DocumentDB qui est là pour faciliter la création d’une communauté d’échanges sur le sujet. Vous pouvez également visualiser et/ou télécharger la présentation Microsoft Azure: DocumentDB and other noSQL databases animée par mon collègue Benjamin Guinebertière lors de la conférence NoSQL matters Paris 2015 la semaine dernière ;-) Vous y trouverez nombre de compléments intéressants !

Posted by on 29 March 2015 | 4:22 am

Small Basic 1.1 est arrivé ! (fr-FR)

Depuis l'année dernière, nous avons commencé l'aventure du développement continu de Microsoft Small Basic. Avec une nouvelle équipe rassemblée au sein de Microsoft dans un nouveau monde de périphériques et de plateformes. Comme vous pouvez l'imaginer, nous faisons une étape à la fois. Cette version est un petit pas, mais c'est une  étape importante. S'il vous plait rejoignez-nous pour essayer Small Basic 1.1, et postez vos impressions dans les commentaires ci-dessous. Nous vous proposons deux possibilités pour télécharger Microsoft Small Basic: Small Basic 1.1 - Si vous êtes sur Windows 7 / Windows Vista ou un système plus récent Small Basic 1.0 - Si vous êtes sur Windows XP ou un système plus ancien   Microsoft Small Basic 1.1 Small Basic 1.1 à été mis à niveau vers le Framework NET 4.5, et inclus le correctif du bug de l'API Flickr (1.0-17). Il est compatible avec Windows 10 Tech Preview, Windows 8.1, Windows 8, Windows 7, Windows Server 2008 R2, et Windows Vista. Si vous utilisez Windows XP, vous devrez télécharger Small Basic 1.0. Toutes les extensions créées pour Small Basic 1.0 devrons être recompilées pour Small Basic 1.1. Vous avez deux options pour le téléchargement: Téléchargement Direct en Français - Après le téléchargement, exécuter le fichier MSI. Les autres langues sont toujours disponibles dans l'Assistant d'Installation. Page du Centre de Téléchargement - Vous pouvez directement sélectionner et télécharger votre langue depuis cette page. Vous y trouverez également des informations sur les nouveautés.  Vous trouverez également des informations sur cette version dans l'article Microsoft Small Basic 1.1 Release Notes.   Microsoft Small Basic 1.0 Small Basic 1.0 est compatible avec Windows XP, Windows Server 2003 et les systèmes plus anciens. Il nécessite le Framework .NET 3.5 SP1. Il n'inclus pas le correctif de l'API Flickr du Small Basic 1.1. Vous avez deux options de téléchargement: Téléchargement Direct en Anglais -  Une fois le fichier MSI téléchargé, exécutez le. Les autres langues sont disponibles dans l'Assistant d'Installation. Page du Centre de Téléchargement - Vous y trouverez plus d'information sur cette installation (En Anglais uniquement).  Quoi de Neuf dans Microsoft Small Basic 1.1 Nouvelles mise à jour Framework NET 4.5 - Nous avons mis à niveau vers le Framework .NET de la version 3.5 SP1 vers la version 4.5. Bien que cela provoque des ruptures de comportement (voir plus bas), c'était nécessaire afin de permettre la création de nouveaux objets tirant parti des nouveaux dispositifs, systèmes d'exploitation et capacités. Langues de Téléchargement - Vous désormais télécharger directement Small Basic dans votre langue depuis le Centre de téléchargement. Voir la Page du Centre de Téléchargement. Corrections de Bugs Objet Flickr (1.0-17) - Flickr à modifié ces API, ce qui à rendu inutilisable l'objet Flickr. Ceci a été corrigé dans Small Basic 1.1. Ruptures avec les précédentes versions Windows XP - u fait de la mise à niveau vers le Framework .NET 4.5, Small Basic 1.1 ne fonctionne pas sur Windows XP et les systèmes plus anciens. Nous continuons de proposer Small Basic 1.0 pour les utilisateurs de Windows XP et de systèmes plus anciens. Extensions 1.0 - Toutes les extensions créées pour Small Basic 1.0 doivent être recompilées pour Small Basic 1.1 et redistribuées. Autres Modifications Nous expérimentons des graphismes plus modernes. Actuellement seul l'Assistant d'Installation a été modifié avec des graphismes modernisés temporaires. Ils seront actualisés à nouveau dans les prochaines versions. Configuration Système Système d'exploitation pris en charge:  Windows 10 Tech Preview, Windows 8.1, Windows 8, Windows 7, Windows Server 2008 R2, Windows Vista, Mini-Mac (Windows 8.1 / Parallels Desktop 10 for Mac / Mac OS X Yosemite), Lifebook (voir les instructions d'installation) Framework .Net 4.5:Obligatoire pour Windows 7 et Windows Vista. Il est pré-installé sur Windows 8 et les systèmes plus récents. Instructions d'Installation Si vous avez Small Basic 1.0 d'installé, désinstallez-le. Vous devrez également effacer tous les fichiers dans le dossier "smallbasic". A NOTER: Si vous faîtes une installation sur Lifebook (Windows 8.1 J), vous devrez modifier autoriser l'accès au dossier "C:\Users\xxx\AppData\Roaming\Microsoft" à "SYSTEM". Télécharger et Installer Microsoft Small Basic dans votre langue préférée. Lancer Microsoft Small Basic en cliquant sur le raccourci de son programme. Merci de vous joindre à nous dans notre aventure Small Basic. Nous avons parcouru un long chemin, mais comme vous pouvez le constater, nous venons seulement de commencer !  "Small basic"quement votre, Yan

Posted by on 29 March 2015 | 2:45 am

Imagine Cup Bangladesh 2015: How to Submit Your Project Online

Because this is the first time we are hosting the Imagine Cup Bangladesh 2015 competition online due to unavoidable circumstances. This blog post gives you a short tour of the submission process for your project. If you have followed the instruction at http://aka.ms/icreg and registered your team, you now have to follow the instruction below to submit your project by April 15, 2015 at 23.59. Beyond that time period you will not be able to submit anything for the competition. We kept project submission an extremely simple process. Step 1: Go to Dashboard. For this example, I already have created a team called Team Bangladesh and a list of competition available to me as a contestant from Bangladesh – register for the competition as I have done so for Innovation category as below:   Step 2: Now click on submit which will reveal the project artifacts for you to submit as part of your entry to the competition. Remember the deadline for submission is April 15, 2015 at 23:59. Make sure that you try to submit way before the deadline so that your internet won’t trouble you in the process. The requirements of the submission are fully described in detail as seen above. Remember failure to send any of these, least but not limited to full source code of the solution zipped, instruction on setting up machine, list of freely available software/tools that need to be installed prior to running the program and how to run the program itself, 10-minute video of your presentation in wmv/mp4 format, project proposal in doc, docx, pdf, ppt, pptx no longer than 10-pages/20-slides. Before you submit please read all of this post. Grab this opportunity to stomp new horizon of possibility, passion, expertise, recognition and acquaintance. Gear up to flaunt your skills in the local as well as international arena of next-gen games and apps, and battle it out with the brightest students around the world. And who knows - with the technical support, mentorship and grants from Microsoft, your brainchild could become the next best business to an afflicting social issue and earn you the bragging rights, cash & prizes, and access to prestigious IT events around the world.

Posted by on 29 March 2015 | 1:59 am

Build a Cloud-hosted Web-Based Blob Copy Utility using Node.js

Introduction The goal is simple. Present a web form that allows a user to type in a URL. A username and password also accepted. When the user clicks perform copy, the image pointed to by the URL will be copied to azure blob storage through a streaming mechanism. We will build a blob copy utility using Node.js, hosted in Azure. We will host this application in Azure websites. There are a few things to accomplish at the Azure portal. first we will provision in Azure website. We will also provision in Azure storage account. The assumption here is that you already have a repository defined in Github. We will correlate our Azure websites to Github. Workplan As you can see we have a few things to do at the portal in addition to writing some code. I will assume you have the skills to go figure out how to provision a storage account. But I will walk you through the new portal where we provision and Azure website. We have three pieces of code. We have one node.JS file called server.JS. For the web form we have SubmitForm.htm and style.css. Provision Github Repo We will login to Github and define a new repository called blobcopy. Provide a name for your repo. Copy the following code from the Github web site. Make a folder on your local drive. Paste in the commands from the clipboard. This will associate your local repository with the repo hosted at Github. Image 15 Provision Web App at the Portal Let's begin by creating an Azure Web Site to host our Node.js application. Now we will go to the Azure portal to provision in Azure website. Click the new button on the lower left corner. From the create menu choose web + mobile. The GUI will expand. On the right click web app. Choose the region (data center location), then click CREATE. Choose a region. Provide a name for your node.JS hosted website. In my case on calling at my blob copy but your name will be different. Choose a region. You will wait less than 2 minutes for your site to come up. We will now set up continuous deployment with Github. Click set up continuous deployment. For the source select Github by Github. Select configure required settings, where you will go back to choose the repo that you created at Github. In my case that was called blobcopy. blobcopy has been selected. You will need to login to github here to associate your github repo. Now it is time to ride our node. JS code. Writing some node.js code (Hello World) We will create a program call server.JS. It's important to give it this name because that's what Azure websites will use as a default file name. We will write a simple "hello world" example to start. Save your file returned back to the command line, and type in the following Github commands. This is what allows Github to copy our code from a local hard disk up into the cloud where we are hosting our Azure website We will now return to the portal to copy the URL of our provisioned website. We will now navigate to that URL and should see hello world. This validates that we have things set up correctly. Web Client Let's now write a web client that will submit form data to our node back-end. The point is to be able to pass in blob endpoints to node, which will then copy them to another destination. Your form might look something like this. Notice I'm running this locally but you can choose to also run this in Azure, using the same techniques just discussed. Image 31 Source Code for SubmitForm.html The style sheet can be found in the Appendix. Take special node of the URL where the form fields are submitted. http://myblobcopy.azurewebsites.net/ The original intent of this program is to copy pictures from Amazon over to Azure. That's why you see the source URL pointing to Amazon. Although we will enter and support a username password, for the purposes of this demo we are not going to worry about authentication and authorization. One important thing to notice here is the form action points to our provision website up in Azure, from the previous step. Once again, the url is: http://myblobcopy.azurewebsites.net/ <html> <head> <link href="style.css" rel="stylesheet"> </head> <body> <form action="http://myblobcopy.azurewebsites.net/" method="post"> <div id="title">Copy blob from Amazon to Azure</div> <div class="row"> <label class="col1">Source URL (Amazon):&nbsp;&nbsp;</label> <span class="col2"><input name="sourceurl" class="input" type="text" id="sourceurl" value="http://www.motorbikespecs.net/images/Suzuki/GSXR_1000_K3_03/GSXR_1000_K3_03_2.jpg" size="80" tabindex="1" /></span> </div> <div class="row"> <label class="col1">User Name:&nbsp;&nbsp;</label> <span class="col2"><input name="username" class="input" type="text" id="username" value="c" size="80" tabindex="3" /></span> </div> <div class="row"> <label class="col1">Password:&nbsp;&nbsp;</label> <span class="col2"><input name="password" class="input" type="text" id="password" value="d" size="80" tabindex="4" /></span> </div> <div align="center" class="submit"> <input type="submit" value="Perform Copy" alt="send" width="52" height="19" border="0" /> </div> </form> </body> </html> Return back to the server.js node code Let's now finish writing our server back-end the perform a copy. Submitting form fields and having Node.js receive them. We will need to leverage a bunch of node packages. We will need to install a number of those node packages, approximately eight of them. At the top of our node.js app (server.js) we will want to leverages some packages, like this: var http = require('http'); var querystring = require('querystring'); var azure = require('azure'); var request = require('request'); var stream = require('stream'); var util = require('util'); var url = require("url"); var path = require("path"); But these packages will need to be installed. The assumption is that you've installed Node on your development computer and Node Package Manager. You can get the bits here: https://nodejs.org/ npm install http npm install querystring npm install azure npm install request npm install stream npm install util npm install url npm install path Here is the output of request as an example. Azure is a big one and will take the longest. These are packages or libraries used by our app for additional functionality. You can read about them here: https://www.npmjs.com/ Copying an image to Azure Storage Double check and make these edits are in your code. var http = require('http'); var querystring = require('querystring'); var azure = require('azure'); var request = require('request'); var stream = require('stream'); var util = require('util'); var url = require("url"); var path = require("path"); var blobService = azure.createBlobService('brunostorage', 'YOU GET THIS FROM THE PORTAL UNDER YOUR STORAGE ACCOUNT 8OGSlD7wWHLQA+q3dXmNUOUtBW/liL3a1zc8DevrtlAKnI5wwzg=='); var containerName = 'ppt'; var port = process.env.PORT || 1337; http.createServer(function(req, res) { var body = ""; req.on('data', function(chunk) { body += chunk; }); req.on('end', function() { console.log('POSTed: ' + body); res.writeHead(200); // Break apart submitted form data var decodedbody = querystring.parse(body); // Parse out the submitted URL var parsed = url.parse(decodedbody.sourceurl); // Get the filename var filename = path.basename(parsed.pathname); // Send text to the browser var result = "Copying " + decodedbody.sourceurl + "</br> to " + filename; res.end(result); // Start copying to storage account loadBase64Image(decodedbody.sourceurl, function (image, prefix) { var fileBuffer = new Buffer(image, 'base64'); blobService.createBlockBlobFromStream(containerName, filename, new ReadableStreamBuffer(fileBuffer), fileBuffer.length, { contentTypeHeader: 'image/jpg' }, function (error) { //console.log('api result'); if (!error) { console.log('ok'); } else { console.log(error); } }); }); }); var downloadImage = function(options, fileName) { http.get(options, function(res) { var imageData = ''; res.setEncoding('binary'); res.on('data', function(chunk) { imageData += chunk; }); res.on('end', function() { fs.writeFile(fileName, imageData, 'binary', function(err) { if (err) throw err; console.log('File: ' + fileName + " written!"); }); }); }); }; var loadBase64Image = function (url, callback) { // Required 'request' module // Make request to our image url request({ url: url, encoding: null }, function (err, res, body) { if (!err && res.statusCode == 200) { // So as encoding set to null then request body became Buffer object var base64prefix = 'data:' + res.headers['content-type'] + ';base64,' , image = body.toString('base64'); if (typeof callback == 'function') { callback(image, base64prefix); } } else { throw new Error('Can not download image'); } }); }; var ReadableStreamBuffer = function (fileBuffer) { var that = this; stream.Stream.call(this); this.readable = true; this.writable = false; var frequency = 50; var chunkSize = 1024; var size = fileBuffer.length; var position = 0; var buffer = new Buffer(fileBuffer.length); fileBuffer.copy(buffer); var sendData = function () { if (size === 0) { that.emit("end"); return; } var amount = Math.min(chunkSize, size); var chunk = null; chunk = new Buffer(amount); buffer.copy(chunk, 0, position, position + amount); position += amount; size -= amount; that.emit("data", chunk); }; this.size = function () { return size; }; this.maxSize = function () { return buffer.length; }; this.pause = function () { if (sendData) { clearInterval(sendData.interval); delete sendData.interval; } }; this.resume = function () { if (sendData && !sendData.interval) { sendData.interval = setInterval(sendData, frequency); } }; this.destroy = function () { that.emit("end"); clearTimeout(sendData.interval); sendData = null; that.readable = false; that.emit("close"); }; this.setEncoding = function (_encoding) { }; this.resume(); }; util.inherits(ReadableStreamBuffer, stream.Stream); }).listen(port); Updating your repo We are now ready to synchronize our local edits up to Azure websites by issuing the following Github commands. git add . --all git commit -m "new updates" git push -u origin master Make sure that your form is submitting to the correct endpoint. Yours will be different from the highlighted section below. Run the submitting form and it should look something like this. Notice that are hardcoded a URL that points to an existing photo. Ideally, this could be some photo sitting on Amazon that you wish to copy to Azure. Once you click perform copy the following screen should appear. It indicates that the file was successfully downloaded and written to your Azure blob storage account. You can download a simple utility to go to your Azure storage blob files to validate the correct copy of current. You can download it for free here: http://azurestorageexplorer.codeplex.com/ Conclusion There is room for improvement in this quick sample. One of the things you can do is make the process more asynchronous. The way to do that is to leverage Azure queues. That means all submitted URLs would go into a queue. From there a background process would read from the queue and perform the actual operation whereby the images are copied azure blob storage. But the code provided above serves as an excellent starting point to build a more robust solution. Appendix Style Sheet - style.css #linear_grad { height: 100px; background: linear-gradient(#deefff, #96caff); } #button_grad { height: 40px; width: 100px; color: #ffffff; font: bold 84% 'trebuchet ms',helvetica,sans-serif; font-size: large; background: linear-gradient(#aeaeae, #929292); } body { background-color: #DBE8F9; font: 11px/24px "Lucida Grande", "Trebuchet MS", Arial, Helvetica, sans-serif; color: #5A698B; } #title { width: 330px; height: 26px; color: #5A698B; font: bold 11px/18px "Lucida Grande", "Trebuchet MS", Arial, Helvetica, sans-serif; padding-top: 5px; background: transparent url("images/bg_legend.gif") no-repeat; text-transform: uppercase; letter-spacing: 2px; text-align: center; } form { width: 335px; } .col1 { text-align: right; width: 135px; height: 31px; margin: 0; float: left; margin-right: 2px; background: url(images/bg_label.gif) no-repeat; } .col2 { width: 195px; height: 31px; display: block; float: left; margin: 0; background: url(images/bg_textfield.gif) no-repeat; } .col2comment { width: 195px; height: 98px; margin: 0; display: block; float: left; background: url(images/bg_textarea.gif) no-repeat; } .col1comment { text-align: right; width: 135px; height: 98px; float: left; display: block; margin-right: 2px; background: url(images/bg_label_comment.gif) no-repeat; } div.row { clear: both; width: 335px; } .submit { height: 29px; width: 330px; background: url(images/bg_submit.gif) no-repeat; padding-top: 5px; clear: both; } .input { background-color: #fff; font: 11px/14px "Lucida Grande", "Trebuchet MS", Arial, Helvetica, sans-serif; color: #5A698B; margin: 4px 0 5px 8px; padding: 1px; border: 1px solid #8595B2; } .textarea { border: 1px solid #8595B2; background-color: #fff; font: 11px/14px "Lucida Grande", "Trebuchet MS", Arial, Helvetica, sans-serif; color: #5A698B; margin: 4px 0 5px 8px; }

Posted by on 28 March 2015 | 9:06 pm

TypeC - A Simple .NET Dependency Injection / IoC Container

TypeC is a simple .NET type container for resolving interfaces/abstract base classes to their concrete implementations. TypeC implements factory method for instantiating types. Only one container can exist in a given .NET AppDomain as it is a singleton implementation. Multiple concrete child types can be mapped to the same base class through namespace support. The project repo is located at http://github.com/hanuk/typec; the nuget package can be installed using the command: "Install-Package TypeC" from the NuGet Package Manager Console inside Visual Studio. The following snippets show the sample usage: //during the startup TypeContainer typeC = TypeContainer.Instance; typeC.Register<IList<string>, List<string>>(); //deep inside the layers of the code var list = typeC.GetInstance<IList<string>>(); list.Add("test");   With namespace support: //during the startup string namespace = "MyNamespace"; TypeContainer typeC = TypeContainer.Instance; typeC.Register<IList<string>, List<string>>(namespace); //deep inside the layers of the code var list = typeC.GetInstance<IList<string>>(namespace); list.Add("test"); Loading type mapping from a configuration file: //during the startup string fileName = "TypeConfig.xml"; TypeContainer tc = TypeContainer.Instance; //the Load(fileName) will fail if types can't be resolved tc.Load(fileName);   //deep inside the layers of the code IGenericWriter<MyClass> writer1 = tc.GetInstance<IGenericWriter<MyClass>>("gwriter3"); writer1.Write(new MyClass()); IGenericWriter<MyClass> writer2 = tc.GetInstance<IGenericWriter<MyClass>>("gwriter4"); Sample XML configuration file is located in TypeC.Tests project. The file follows the standard reflection notation: https://msdn.microsoft.com/en-us/library/w3f99sx1(v=vs.110).aspx TypeContainer.GetRegistryAsXml() will dump the registry for easy configuration file creation and debugging. The returned XML string can be pasted into the configuration file so that complex generic types can be defined easily for dynamic binding. The sample xml configuration snippet returned by TypeContainer.GetRegistryAsXml()is shown below: //code snippet  TypeContainer tc = TypeContainer.Instance;tc.Register<IWriter, Lib1Writer1>("writer1");tc.Register<IWriter, Lib2Writer1>("writer2");tc.Register<IGenericWriter<string>, Lib1GenericWriter1>("gwriter1");tc.Register<IGenericWriter<string>, Lib2GenericWriter1>("gwriter2");tc.Register<IGenericWriter<MyClass>, Lib1GenericWriter2>("gwriter3");tc.Register<IGenericWriter<MyClass>, Lib2GenericWriter2>("gwriter4");  string xml = tc.GetRegistryAsXml(); //corresponding XML <typecmap> <mapping namespace="writer1" from="TypeC.Tests.Shared.IWriter,TypeC.Tests.Shared" to="TypeC.Tests.Lib1.Lib1Writer1, TypeC.Tests.Lib1"/> <mapping namespace="writer2" from="TypeC.Tests.Shared.IWriter,TypeC.Tests.Shared" to="TypeC.Tests.Lib1.Lib1Writer2, TypeC.Tests.Lib1"/> <mapping namespace="gwriter1" from="TypeC.Tests.Shared.IGenericWriter`1[[System.String, mscorlib]], TypeC.Tests.Shared" to ="TypeC.Tests.Lib1.Lib1GenericWriter1, TypeC.Tests.Lib1"/> <mapping namespace="gwriter2" from="TypeC.Tests.Shared.IGenericWriter`1[[System.String, mscorlib]], TypeC.Tests.Shared" to ="TypeC.Tests.Lib2.Lib2GenericWriter1, TypeC.Tests.Lib2"/> <mapping namespace="gwriter3" from="TypeC.Tests.Shared.IGenericWriter`1[[TypeC.Tests.Model.MyClass, TypeC.Tests.Model]], TypeC.Tests.Shared" to ="TypeC.Tests.Lib1.Lib1GenericWriter2, TypeC.Tests.Lib1"/> <mapping namespace="gwriter4" from="TypeC.Tests.Shared.IGenericWriter`1[[TypeC.Tests.Model.MyClass, TypeC.Tests.Model]], TypeC.Tests.Shared" to ="TypeC.Tests.Lib2.Lib2GenericWriter2, TypeC.Tests.Lib2"/> </typecmap> If you have complex nested generic types, hand coding XML can be error prone; build your registry using code and dump xml into the configuration file. Hope this helps.

Posted by on 28 March 2015 | 6:21 pm

Battleship Games - Small Basic Featured Programs

In the March Challenges, litdev included this challenge: Game Challenge Write a battleships game.  You will need to consider how it will work with 2 players or play against the computer.   Yan Grenier completed his game on 3/21: Hi all, This my solution for the Battleship against the computer :MRV593-2 More details in this forum discussion : https://social.msdn.microsoft.com/Forums/en-US/1ab990d7-c6c3-49d6-abba-693571262afa/my-new-game-battleship-la-bataille-navale-frfr?forum=smallbasic Have fun ;) Yanos   And then Nonki Takahashi also submitted an alpha 2 version of his battleship game on 3/25: This is my second step for game challenge: GZN668-0. It's still alpha version.  You can just draw a peg with mouse click.      Everyone, try out these great battleship games and let us know what you think! Thanks to LitDev for the great challenge and to Yan and Nonki for the games! PS: Have you heard that we launched Small Basic 1.1? Small Basic 1.1 is here! Have a Small and Basic day!    - Ninja Ed  

Posted by on 28 March 2015 | 5:44 pm

Отчет о списывании времени с задач

Team Foundation Server позволяет исполнителям ежедневно отчитываться о времени потраченном на свои задачи. Данная возможность позволяет команде и менеджеру проекта оперативно в целом оценивать ситуацию и понимать вкладываемся ли в итерацию, спринт или успеем мы отдать доработку к обещанному сроку. Но когда встает вопрос узнать об истории изменения времени или как списывалось время в конкретный день, то это стандартными возможностями через запросы по рабочим элементам не получить. Поучить можно ее с помощью отчетов, но стандартного такого отчета нет в коробке TFS, поэтому его необходимо создавать. Выполнять разработку отчета с чистого листа нет смыслы, т.к. есть возможность взять за основу отчеты, которые поставляются с TFS. Немного «почистив» стандартный отчет, можно получить типовой шаблон для всех последующих отчетов. Пример такого отчета можно скачать как zip-архив здесь. Данный отчет можно редактировать с помощью Report Builder. Отчет содержит некоторые параметры, которые динамически определяют название проекта, поэтому для того, чтоб он заработал его необходимо открыть и сохранить на Report Server в каталог необходимого командного проекта: Рисунок 1. Сохранение отчета на сервере отчетности Кроме этого необходимо убедитmся, что источник данных указывается на правильное соединение TFSReportDS: Рисунок 2. Свойства источника данных Далее нам необходимо получить данные о списании времени для рабочих элементов. Это необходимо сделать с помощью добавления нового источника данных: Рисунок 3. Свойства источника данных Текст запроса можно использовать ниже приведенный, он взят из руководства по отчетности от ALM Rangers. Этот запрос отбирает из таблицы WorkItemHistoryView необходимые данные, а также стразу подчитывает разницу времени, которe. исполнитель указал в рабочем элементе. SELECT [System_Id] As [Id],[System_Rev] As [Rev], [System_ChangedBy] As [Changed By], [Microsoft_VSTS_Scheduling_OriginalEstimate] AS [Original Estimate], [Microsoft_VSTS_Scheduling_RemainingWork] AS [Remaining Work], [Microsoft_VSTS_Scheduling_CompletedWork] AS [Completed Work], [System_Title] As [Title],[System_AssignedTo] As [Assigned To], [System_ChangedDate] As [Changed Date], [ProjectNodeName] AS [Team Project], [AreaName],[AreaPath], [IterationName], [IterationPath], [Microsoft_VSTS_Scheduling_RemainingWork] — (Select Top 1 IsNull([Microsoft_VSTS_Scheduling_CompletedWork],0) FROM [Tfs_Warehouse].[dbo].[WorkItemHistoryView] WITH(NOLOCK) WHERE [System_Id] = WIHV.[System_Id] AND [System_Rev] = WIHV.[System_Rev] — 1) as [Completed Diff] FROM [Tfs_Warehouse].[dbo].[WorkItemHistoryView] WIHV WITH(NOLOCK) WHERE /** Filter team project **/ [ProjectNodeName] LIKE @ProjectName /** Filter correction entries **/ AND [RevisionCount] IS NOT NULL /** Filter empty entries **/ AND ([Microsoft_VSTS_Scheduling_OriginalEstimate] IS NOT NULL OR [Microsoft_VSTS_Scheduling_RemainingWork] IS NOT NULL OR [Microsoft_VSTS_Scheduling_CompletedWork] IS NOT NULL) ORDER BY ID, Rev Ну и далее необходимо отразить результаты работы отчета. Для этого можно воспользоваться мастером вставки таблиц: Рисунок 4. Вставка таблицы результатов мастером Далее в новую таблицу мы добавляем поля, которые нам необходимы для отображения: Рисунок 5. Добавление новых полей И теперь мы уже можем проверить результат, нажав кнопку Выполнить в Report Builder. Но на текущий момент отчет будет отбирать все изменения, которые были выполнены в TFS. Нам же необходимо отобрать по конкретной дате. Для этого нам нужно добавить новый параметр в отчет и вставить его в тело запроса для нашего набора данных. Добавить параметр можно в соответствующем разделе отчета и указав следующие свойства: Рисунок 6. Свойства параметра Теперь сталось добавить данный параметр в тело запроса, где мы будем сравнивать задаваемую дату с датой изменения рабочего элемента. При этом нужно помнить, что данный параметр и значение поля рабочего элемента имеют тип Дата-Время, поэтому мы приве��ем их только к дате. Пример запроса в наборе данных ниже: Рисунок 7. Измененный запрос Теперь отчет готов к использованию и его можно скопировать во все проекты, где необходимо его использовать. Рисунок 8. Готовый отчет Дополнительные ссылки: Создание и настройка отчетов для Visual Studio ALM и управление ими TFS Reporting Guide

Posted by on 28 March 2015 | 9:27 am

[Sample Of Mar. 28] How to add checkbox and dropdownlist column in ASP.NET MVC WebGrid

Mar. 28 Sample : https://code.msdn.microsoft.com//How-to-add-checkbox-and-af1be797 This sample will show how to add checkbox to MVC web grid. You can find the answers to the following questions in the code sample: • How to extend WebGrid helper to support checkbox better? • How to add checkbox to web grid? You can find more code samples that demonstrate the most typical programming scenarios by using Microsoft All-In-One Code Framework Sample Browser...(read more)

Posted by on 28 March 2015 | 1:43 am

Online Proctored Exams Now Available for Microsoft Dynamics CRM

  Online proctored (OP) exams make certification convenient and accessible by allowing you to take an exam in the comfort of your home or office, often within 15 minutes of registering, while being monitored by an offsite proctor.  You can now take advantage of this option when taking any of the new Microsoft Dynamics CRM 2015 or Microsoft Dynamics Marketing exams.  Certain technical, system, and environment requirements apply, and it is currently only offered in certain countries.  To find out more, click here. Visit online proctored exams for CRM for more information! 

Posted by on 27 March 2015 | 10:56 pm

10 Minutos con Construct 2: Trucos II

Para empezar el fin de semana un poco más de mi serie 10 Minutos con Construct 2. En este video explico cómo usar las animaciones para lograr un efecto similar al de las familias de la versión paga de Construct 2. Agradezco sus comentarios y si quieren bajar algunos de mis plantillas de juego lo pueden hacer aquí: FREE Game Templates in Construct 2

Posted by on 27 March 2015 | 10:07 pm

The case of the non-responsive MVC Web Application

  A colleague (and friend) from Azure team asked me to help narrow down a strange case of a MVC Entity Framework application (hosted in Virtual machine) which occasionally stopped responding, requiring a IIS reset to work again. The products I support do not include IIS, MVC nor Entity Framework. I was invited to help as consultant for NetExt extension. This case study uses WinDbg with NetExt extension. See this to get started with WinDbg and NetExt: http://blogs.msdn.com/b/rodneyviana/archive/2015/03/10/getting-started-with-netext.aspx Verifying how many web application are running under the worker process Listing the .NET Application Domains can gives the number of web applications under the application pool. Just get the number and subtract 3. This technique was discussed here:: http://blogs.msdn.com/b/rodneyviana/archive/2015/03/12/the-strange-case-of-the-application-pool-recycling-causing-high-cpu.aspx 0:000> !wdomain Address Domain Name Modules Base Path & Config 747e0c08 System 43 747e0f60 Shared 01804078 DefaultDomain 10 Base Path: D:\Windows\SysWOW64\inetsrv\ Config: w3wp.exe.config 0184a7b0 /LM/W3SVC/2033431354/ROOT-1-130705968419350748 75 Base Path: D:\home\site\wwwroot\ Config: web.config Having only one web application to the application pool ruled out the problem of another web site locking this one. Ruling out is as imported as ruling in. Notice that default domain points to SysWOW64 which means that the w3wp process is running as 32-bits. To debug this dump file I had to use WinDbg 32-bits and the 32-bits version of NetExt. You should never run a Web Application as 32-bits unless it is necessary (i.e. if the application depends on a native 32-bits dll). IIS application  running as 32-bits will always run out of memory because of memory fragmentation. This is a frequent problem in 32-bit processes that run for long time. Memory is allocated and de-allocated all the time leaving “holes” in memory. In order to allocate, let’s say 10MB of memory, it is necessary at least one 10MB block of “contiguous” memory available. If there is 100 x 1MB free memory segments but not a single segment with 10MB free, your application will not be able to allocate 10MB of contiguous memory and will yield a “Out of Memory” exception. The maximum memory available for a 32-bits process is 4GB (because the OS is 64-bits, otherwise it would be only 2GB). However, memory fragmentation was not the problem in this case. Verifying how many requests were active To run commands requiring heap look up, you need to index the heap first. 0:000> !windex Starting indexing at 20:29:08 PM 1000000 objects... Indexing finished at 20:29:10 PM 97,208,569 Bytes in 1,490,134 Objects Index took 00:00:02     0:000> !wruntime Runtime Settings per Application Pool   ========================================================================= Address : 066C5404 First Request : 3/24/2015 1:14:35 PM App Pool User : IIS APPPOOL\contosofarm Trust Level : Full App Domnain Id : /LM/W3SVC/1264340133/ROOT-1-130716764614361954 Debug Enabled : False Active Requests : 0n548 Path : D:\home\site\wwwroot\ (local disk) Temp Folder : D:\local\Temporary ASP.NET Files Compiling Folder: D:\local\Temporary ASP.NET Files\root\7135b59b\46bce28c Shutdown Reason : Not shutting down We have 548 active connections. This is just another information we will need to find the problem, but the fact of having that many requests is not a problem per se. Checking the running requests pattern 0:000> !whttp -running HttpContext Thread Time Out Running Status Verb Url 02f1b334 -- 00:01:00 00:20:04 200 GET https://contosoapp.com:443/OrderSystem/Order 03095104 -- 00:01:00 00:21:22 200 GET https://contosoapp.com:443/OrderSystem/Order 030968ec -- 00:01:00 00:21:03 200 GET https://contosoapp.com:443/OrderSystem/Order 0309873c -- 00:01:00 00:21:11 200 GET https://contosoapp.com:443/OrderSystem/Order 030990b4 -- 00:01:00 00:21:11 200 GET https://contosoapp.com:443/OrderSystem/Order 0309f154 -- 00:01:00 00:21:40 200 GET https://contosoapp.com:443/OrderSystem/Order 030a2a70 -- 00:01:00 00:21:30 200 GET https://contosoapp.com:443/OrderSystem/Order 030a3404 -- 00:01:00 00:21:39 200 GET https://contosoapp.com:443/OrderSystem/Order 030a6d20 -- 00:01:00 00:21:39 200 GET https://contosoapp.com:443/OrderSystem/Order 030aa63c -- 00:01:00 00:21:39 200 GET https://contosoapp.com:443/OrderSystem/Order 030adf58 -- 00:01:00 00:21:39 200 GET https://contosoapp.com:443/OrderSystem/Order 030b1874 -- 00:01:00 00:21:38 200 GET https://contosoapp.com:443/OrderSystem/Order 030b5190 -- 00:01:00 00:21:38 200 GET https://contosoapp.com:443/OrderSystem/Order 030b8aac -- 00:01:00 00:21:38 200 GET https://contosoapp.com:443/OrderSystem/Order 030bc3c8 -- 00:01:00 00:21:38 200 GET https://contosoapp.com:443/OrderSystem/Order 030bfce4 -- 00:01:00 00:21:38 200 GET https://contosoapp.com:443/OrderSystem/Order 030c3600 -- 00:01:00 00:21:38 200 GET https://contosoapp.com:443/OrderSystem/Order 030c6f1c -- 00:01:00 00:21:38 200 GET https://contosoapp.com:443/OrderSystem/Order 030dbc34 -- 00:01:00 00:20:16 200 GET https://contosoapp.com:443/OrderSystem/Order 030dcaa0 -- 00:01:00 00:20:18 200 GET https://contosoapp.com:443/OrderSystem/Order 030df8a8 -- 00:01:00 00:21:37 200 GET https://contosoapp.com:443/OrderSystem/Order (... lines removed for brevity ...) 0f8461b0 -- 00:01:00 00:20:06 200 GET https://contosoapp.com:443/OrderSystem/Order 0f8471f4 -- 00:01:00 00:20:06 200 GET https://contosoapp.com:443/OrderSystem/Order 0f8503b0 -- 00:01:00 00:20:05 200 GET https://contosoapp.com:443/OrderSystem/Order 0f857058 -- 00:01:00 00:20:05 200 GET https://contosoapp.com:443/OrderSystem/Order 0f85e0e4 -- 00:01:00 00:20:05 200 GET https://contosoapp.com:443/OrderSystem/Order 0f8678f4 -- 00:01:00 00:20:05 200 GET https://contosoapp.com:443/OrderSystem/Order 0f871104 -- 00:01:00 00:20:04 200 GET https://contosoapp.com:443/OrderSystem/Order 0f874a40 -- 00:01:00 00:20:04 200 GET https://contosoapp.com:443/OrderSystem/Order 0f87b2c8 51 00:01:00 00:20:04 200 GET https://contosoapp.com:443/OrderSystem/Order   548 HttpContext object(s) found matching criteria   13 HttpContext object(s) skipped by filter Note that only one of the requests has an associated thread. The others have “---“ as thread which means that either IIS is waiting for a thread to be created or the thread was aborted and IIS was not informed yet. Normally it is because the request is queued. As you can see, the requests are running for over 20 minutes even though the time out is set to 1 minute. HttpContext the object wrapping an IIS request includes a field to tell the timeout state. You can verify most of .NET framework source code here: http://referencesource.microsoft.com/ HttpContext.cs private int _timeoutState; // 0=non-cancelable, 1=cancelable, -1=canceled   Running HttpContext are in a non-cancelable state (_timeoutState = 0)   0:000> !wselect * from 0f87b2c8 [System.Web.HttpContext] (int64)System.Int64 _timeoutStartTimeUtcTicks = 8d2347382c7e3c2 (0n635628168132682690) (int64)System.Int64 _timeoutTicks = 4190ab00 (0n1100000000) System.Web.IHttpAsyncHandler _asyncAppHandler = 00000000 System.Web.HttpApplication _appInstance = 0F878910 System.Web.IHttpHandler _handler = 0F22B824 System.Web.HttpRequest _request = 0F87B3C4 System.Web.HttpResponse _response = 0F87B48C System.Web.HttpServerUtility _server = 0717B2D8 System.Collections.Stack _traceContextStack = 00000000 System.Web.TraceContext _topTraceContext = 00000000 System.Collections.Hashtable _items = 0F165538 System.Collections.ArrayList _errors = 00000000 System.Exception _tempError = 00000000 System.Web.IPrincipalContainer _principalContainer = 0F87B5D4 System.Web.Profile.ProfileBase _Profile = 00000000 System.Web.HttpWorkerRequest _wr = 0F87B050 System.Web.VirtualPath _configurationPath = 00000000 System.Globalization.CultureInfo _dynamicCulture = 026D8EF8 System.Globalization.CultureInfo _dynamicUICulture = 026D8EF8 System.Collections.Stack _handlerStack = 00000000 System.Web.Instrumentation.PageInstrumentationService _pageInstrumentationService = 00000000 System.Collections.ObjectModel.ReadOnlyCollection _webSocketRequestedProtocols = 00000000 System.Web.Util.CancellationTokenHelper _timeoutCancellationTokenHelper = 038239C4 System.Web.Util.DoubleLink _timeoutLink = 0F1653E0 System.Threading.Thread _thread = 02FCE050 System.Web.CachedPathData _configurationPathData = 00000000 System.Web.CachedPathData _filePathData = 036B34C8 (string)System.String _sqlDependencyCookie = NULL System.Web.SessionState.SessionStateModule _sessionStateModule = 0F878AE0 System.Web.UI.TemplateControl _templateControl = 00000000 System.Web.NotificationContext _notificationContext = 038D7118 System.Web.ThreadContext IndicateCompletionContext = 038D6C90 System.Threading.Thread ThreadInsideIndicateCompletion = 02FCE050 System.Object ThreadContextId = 0f87b3b8 System.Web.AspNetSynchronizationContextBase _syncContext = 0F87B940 System.Threading.Thread _threadWhichStartedWebSocketTransition = 00000000 (string)System.String _webSocketNegotiatedProtocol = NULL System.Web.IHttpHandler _remapHandler = 0F22B824 System.Web.IHttpHandler _currentHandler = 0F22B824 System.Web.RootedObjects _rootedObjects = 0F87B5D4 System.Web.Security.CookielessHelperClass _CookielessHelper = 0F87B55C System.Security.Principal.IPrincipal k__BackingField = 00000000 (int32)System.Web.Configuration.AsyncPreloadModeFlags _asyncPreloadModeFlags = 0 (0n0) None (int32)System.Int32 _serverExecuteDepth = 0 (0n0) (int32)System.Int32 _timeoutState = 0 (0n0) (native int)System.IntPtr _rootedPtr = 0 (0n0) (int32)System.Web.SessionState.SessionStateBehavior <SessionStateBehavior>k__BackingField = 0 (0n0) Default (bool)System.Boolean _asyncPreloadModeFlagsSet = 1 (True) (bool)System.Boolean _errorCleared = 0 (False) (bool)System.Boolean _skipAuthorization = 0 (False) (bool)System.Boolean _preventPostback = 0 (False) (bool)System.Boolean _runtimeErrorReported = 0 (False) (bool)System.Boolean _threadAbortOnTimeout = 1 (True) (bool)System.Boolean _delayedSessionState = 0 (False) (bool)System.Boolean _isAppInitialized = 1 (True) (bool)System.Boolean _isIntegratedPipeline = 1 (True) (bool)System.Boolean _finishPipelineRequestCalled = 0 (False) (bool)System.Boolean _impersonationEnabled = 0 (False) (bool)System.Boolean HideRequestResponse = 0 (False) (bool)System.Boolean InIndicateCompletion = 1 (True) (uint8)System.Web.WebSocketTransitionState _webSocketTransitionState = 0x0 (0n0) (bool)System.Boolean _requiresSessionStateFromHandler = 1 (True) (bool)System.Boolean _readOnlySessionStateFromHandler = 0 (False) (bool)System.Boolean InAspCompatMode = 0 (False) (bool)System.Boolean _ProfileDelayLoad = 1 (True) (bool)System.Boolean <FirstRequest>k__BackingField = 0 (False) (bool)System.Boolean <DisableCustomHttpEncoder>k__BackingField = 0 (False) System.DateTime _utcTimestamp = -mt 725719B8 00000000 3/24/2015 5:40:12 PM System.Web.Util.SubscriptionQueue> _requestCompletedQueue = -mt 706898A8 00000000 System.Web.Util.SubscriptionQueue _pipelineCompletedQueue = -mt 70689990 00000000 static System.Reflection.Assembly SystemWebAssembly = 066C1B34 static (bool)System.Boolean s_eurlSet = 0 (False) static System.String s_eurl = 00000000 00000000 static System.Action CS$9__CachedAnonymousMethodDelegate3 = 00000000 static System.Func CS$9__CachedAnonymousMethodDelegate6 = 00000000 static System.Func CS$9__CachedAnonymousMethodDelegate8 = 0A92BE14 static System.Func CS$9__CachedAnonymousMethodDelegatea = 0F0449D4 So, this is why the request does not times out. The command below will show all requests that cannot be cancelled (i.e. it will not time out): 0:000> !wfrom -type System.Web.HttpContext where (_timeoutState==0) $addr() calculated: 02AE9C60 calculated: 02F1B334 calculated: 03095104 calculated: 030968EC calculated: 0309873C calculated: 030990B4 calculated: 0309F154 (...) calculated: 0FAF7AE4 calculated: 0FAFE02C   561 Object(s) listed So, that is it. Something is preventing the requests to go away, Looking at the stack trace of thread 51 (the only one running a http request) we found that the thread was waiting for a SQL request to finish. We also saw that this was happening in the custom Global.asax handler method Application_BeginRequest. In the HttpContext fields we can also see that this application is using session (_requiresSessionStateFromHandler = 1 (True)). Only one request per session can run at a time Now comes the theory. The request has timeout, is in pipeline compatibility mode and is relying on ASP.NET session. The session cookie is ASP.NET_SessionId. NetExt includes a command to check and summarize cookies. Let’s summarize cookies by the key and value pair. 0:000> !wcookie -summary Action Total Finished Cookie=Value ====================================================================================== (list) 561 13 ARRAffinity=7c89acbf92e4f1bf14a78494f66466c71fcb071249a85f5e303bf5149086b5bc (list) 548 0 ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe (list) 9 9 ASP.NET_SessionId=21oqjz1amz4bfkfgru5bheth (list) 1 1 ASP.NET_SessionId=ew1qbqsugeiglq5uisf0csw1 (list) 1 1 ASP.NET_SessionId=hwxatvsprf4c2nutxlanzcxl (list) 1 1 ASP.NET_SessionId=xqmy5iteqgosfmagesegpk1h (list) 559 11 SBFtest_cookie=test_cookie_value (list) 9 9 __RequestVerificationToken=IyKw3PREthJanOgCZLqTKzYAtXMyFgYFduNaXmT6xW42djDGVlH7HFGnB1ttFlnlUhz0eXHNOfJpWoBnG6g6Rp4PSGly0T6OFuXCNM0CgGMs_jxgyW-zSjXDVfMnr3vJn2aUEbAeEK8-RlTFgY2CGZmCC-F9FDRKgZHRIfE-tT01 (list) 1 1 __RequestVerificationToken=ToT-glFP2dW7U7AYtPjcjAT-7hWBe3iIiUYjRg4tMinWUhBN4Be8Qo36FyC-qL8_mOfY7MWSgET2M8kIpuX0MleYmLJn3-A6_E9FveN8j_36rcTjmuIV2pkZ9892luiRlHK2HgXepUPFDGqcVJmmdn-HCzC9YEbHEPH1OyDSWs41 (list) 548 0 __RequestVerificationToken=gbM2YmFRGi7yYZ0ic-ipw0umX3RtSz4Kn7y9yTsXbMRExnv-wX40MKKbgygNH01aPflh7rybsyYpIu9v1g-s1Hs-IIrpqPjw5ZndQNaUNfD_2Yx3XaaKUzl808dusffa7bpjVQa1HZ8VAz55L5w_7kUkYUQSfg2BmJaWM7aDTxU1 (list) 1 1 __RequestVerificationToken=mec5uGE2UTVP-iCM6mEMbYVsElHdeUZD7ay9XBkYfSzYYHkwqzeG3pbboAQQ7hiU2rZBh-wDuoLifMuGG6HYnr5Byo0A1EKaD6bwfIvk710pHGpq4A9QZrjWb2S7tPbpOHYqO3VB5ItaetJPrEHnlanToXD6wisV8s-d2Czo7-o1 (list) 1 1 __RequestVerificationToken=z6UahlNkt3UlEiCW5TnGmoORlues-U-O1cs7FihQQPlG52L7qLmWG3vkxQY6uQQRL6F4xzuet8zmZ-8I4aD9cMTYxfa64pf5sktHofl7p9ezJJ4cK2pDJqWrImK5gBTUkGrd1M3d-OAE6lwDx0gWuIeHCSOtDIEvVX3v2LeU_lU1 (list) 1 1 __ar_v4=NPVOPR4AB5FCPB2G4EOFPH%3A20150212%3A2%7CMXNG24JOKNCSXAEC45BD3K%3A20150212%3A2%7CNBPDN5WPCBGR3ATBF2EEHC%3A20150212%3A2 (list) 9 9 __ar_v4=UMR4R6WNO5A5XDYLDDQJ5W%3A20150008%3A2%7CNPVOPR4AB5FCPB2G4EYREW%3A20141117%3A6%7CMXNG24JOKNCSXAEC45BD3K%3A20141117%3A12%7CNBPDN5WPCBGR3ATBF2EEHC%3A20141117%3A12%7CHR63AHCPWBHH5LZ72UPYIS%3A20141117%3A3 (list) 1 1 __utma=35909538.1267946845.1427218502.1427218502.1427218502.1 (list) 1 1 __utma=35909538.154579644.1427202773.1427202773.1427202773.1 (list) 1 1 __utma=35909538.156555049.1423582295.1423582295.1423586012.2 (list) 9 9 __utma=35909538.360373432.1406151229.1425847161.1427219991.14 (list) 1 1 __utma=35909538.432412459.1427202844.1427202844.1427202844.1 (list) 548 0 __utma=35909538.596493886.1426607592.1426607592.1427218695.2   Bingo! There is a single session associated with 548 requests, the exact number of running requests. And unlike the other sessions, no request has finished. Clicking on (list) we see the very same 548 contexts we see in !whttp -running. 0:000> !wcookie -name ASP.NET_SessionId -value 0odyr1kc0cdqoaaomed1v4pe 02f1b334 https://contosoapp.com:443/OrderSystem/Order (200 NULL) Running (00:20:04) ====================================================================================== ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe   1 printed   ====================================================================================== 03095104 https://contosoapp.com:443/OrderSystem/Order (200 NULL) Running (00:21:22) ====================================================================================== ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe   1 printed   ====================================================================================== 030968ec https://contosoapp.com:443/OrderSystem/Order (200 NULL) Running (00:21:03) ====================================================================================== ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe   1 printed   ====================================================================================== 0309873c https://contosoapp.com:443/OrderSystem/Order (200 NULL) Running (00:21:11) ====================================================================================== ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe   1 printed   ====================================================================================== 030990b4 https://contosoapp.com:443/OrderSystem/Order (200 NULL) Running (00:21:11) ====================================================================================== ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe   1 printed   ====================================================================================== 0309f154 https://contosoapp.com:443/OrderSystem/Order (200 NULL) Running (00:21:40) ====================================================================================== ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe   1 printed   ====================================================================================== 030a2a70 https://contosoapp.com:443/OrderSystem/Order (200 NULL) Running (00:21:30) ====================================================================================== ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe   1 printed   ====================================================================================== 030a3404 https://contosoapp.com:443/OrderSystem/Order (200 NULL) Running (00:21:39) ====================================================================================== ASP.NET_SessionId=0odyr1kc0cdqoaaomed1v4pe   1 printed   (...) All the calls were coming from the same IP address. So, there are only two possibilities: this site is under a DoS (Denial of Service) attack or a cat is walking all over the keyboard. Let me know your thoughts in the comments.  

Posted by on 27 March 2015 | 9:42 pm

Small Basic 1.1 is here!

Starting last year, we began the journey of continuing development on Microsoft Small Basic. It's a new team assembled across Microsoft in a new world of devices and platforms. As you can imagine, we're taking one step at a time. This is not a large step, but it's an important step. Please join us in trying out Small Basic 1.1, and post your feedback in the comments below!   We now offer two choices for downloading Microsoft Small Basic: Small Basic 1.1 - If you're using Windows 7 / Windows Vista or newer operating systems Small Basic 1.0 - If you're using Windows XP or prior operating systems   Microsoft Small Basic 1.1 Small Basic 1.1 is upgraded to .NET Framework 4.5, and it includes a fix to the Flickr API bug (1.0-17). It is compatible with Windows 10 Tech Preview, Windows 8.1, Windows 8, Windows 7, Windows Server 2008 R2, and Windows Vista. If you have Windows XP, you'll need to download Small Basic 1.0. Any extensions built for Small Basic 1.0 will need to be rebuilt on Small Basic 1.1. You have two options to download: Direct English Download - After you download and run the MSI file, the other languages are still available through the English installation wizard. Download Center Page - You can directly select and download your language from this page. You'll also see more information about what's new.   You can also find the release information in the Microsoft Small Basic 1.1 Release Notes.   Microsoft Small Basic 1.0 Small Basic 1.0 is compatible with Windows XP and Windows Server 2003. and older operating systems. It requires .NET Framework 3.5 SP1. It does not include the Flickr API fix in Small Basic 1.1. You have two options to download: Direct English Download - After you download and run the MSI file, the other languages are available through the English installation wizard. Download Center Page - You can find more information about the installation. (The only language option is English.)   What's New in Microsoft Small Basic 1.1 New Updates NET Framework 4.5 - We upgraded to .NET Framework 4.5 from 3.5 SP1. Although this causes some breaking changes (see below), it's necessary in order to build out new objects that take advantage of new devices, operating systems, and capabilities. Language Downloads - You can now directly download your language from the Download Center. See the Download Center Page. Bug Fixes Flickr Object (1.0-17) - Flickr changed their API, which broke the Flickr Object. This has been fixed for Small Basic 1.1. Breaking Changes Windows XP - Due to the upgrade to .NET Framework 4.5, Small Basic 1.1 does not work on Windows XP and older operating systems. We will continue to offer Small Basic 1.0 for users of Windows XP and older operating systems. 1.0 Extensions - All extensions built for Small Basic 1.0 will need to be recompiled on Small Basic 1.1 and re-released. Other Changes We're experimenting with modernizing the graphics. Currently it affected the installation wizard, with some temporary modernized images. These will be updated again in future releases. System Requirements Supported Operating Systems:  Windows 10 Tech Preview, Windows 8.1, Windows 8, Windows 7, Windows Server 2008 R2, Windows Vista, Mini-Mac (Windows 8.1 / Parallels Desktop 10 for Mac / Mac OS X Yosemite), Lifebook (see installation instructions) .Net Framework 4.5:Required for Windows 7 and Windows Vista. It comes installed with Windows 8 and newer. Installation Instructions If you have Small Basic 1.0 installed, uninstall it. You'll need to delete all the files in the "smallbasic" folder. NOTE: If you're installing on Lifebook (Windows 8.1 J), you'll need to change the SYSTEM setting to allow access to the "C:\Users\xxx\AppData\Roaming\Microsoft" folder. Download and Install Microsoft Small Basic in your preferred language. Launch by clicking the Microsoft Small Basic program shortcut.      Thank you for joining us in our Small Basic journey. We've come a long way, but as you can see, we're just getting started! Small and Basically yours,    - Ninja Ed    Other Languages This blog post is also available in French: Small Basic 1.1 est arrivé ! (fr-FR)

Posted by on 27 March 2015 | 7:10 pm

RichEdit Colors

Occasionally people ask how foreground (text) and background colors work in RichEdit. This post gives an overview of RichEdit colors in a variety of scenarios including default coloring, formatted coloring, selection coloring (both normal and acetate), math-zone highlighting and special draft and high-contrast modes. It also describes refinements such as switching to XOR coloring when the foreground and background colors are too similar. Interestingly enough except for math-zone highlighting, all these coloring options work with RichEdit plain-text controls as well as with rich-text controls. The colors are character formatting properties and some of the discussion applies to all character formatting properties. Background colors for table cells are described in RichEdit's Nested Table facility. Default colors (autocolor) Unless overruled by explicit formatting, RichEdit gets its text and background colors by calling ITextHost::TxGetSysColor(iColor), where iColor is a color index like COLOR_WINDOW. Typically the RichEdit host delegates this call to the Windows GetSysColor() function, but the callback gives the RichEdit host the opportunity to return other colors instead. For example, by default the background color is given by calling ITextHost::TxGetSysColor(COLOR_WINDOW). The default text (foreground) color index is COLOR_WINDOWTEXT. These and some other color types are defined in winuser.h. In a windowless RichEdit control the host can choose all such colors. In a window’d RichEdit control, the built-in host’s ITextHost::TxGetSysColor(iColor) generally calls the operating system’s GetSysColor(iColor). There are two exceptions. 1) If an EM_SETBKGNDCOLOR message is received, the color supplied by that message is used for COLOR_WINDOW instead of calling GetSysColor(). 2) If the window style is disabled (WS_DISABLED), by default the text color is given by GetSysColor(COLOR_GRAYTEXT) and the background color is given by GetSysColor(COLOR_3DFACE). But if an EM_SETDISABLECOLORS message is received, the text color is given by the message’s wparam and the background color is given by the lparam. When a RichEdit control is instantiated, it creates a default character format structure CHARFORMAT2 with the foreground color effect CFE_AUTOCOLOR and the background color effect CFE_AUTOBACKCOLOR. Whenever these autocolor effect settings are active, RichEdit calls ITextHost::TxGetSysColor() for the default text and background colors, respectively. After initializing the CHARFORMAT2 structure, RichEdit calls ITextHost::TxGetCharFormat() to allow the host to overrule the default structure properties. For example, the host can reset the CFE_AUTOCOLOR and/or CFE_AUTOBACKCOLOR effects, which changes the default colors to be the default CHARFORMAT2::crTextColor and/or CHARFORMAT2::crBackColor colors, respectively, instead of those given by calling ITextHost::TxGetSysColor(). After initialization, the default character format can be changed by sending an EM_SETCHARFORMAT message (use ITextServices::TxSendMessage for windowless controls) with wparam = SCF_DEFAULT (but not SCF_SELECTION) and lparam = CHARFORMAT2 *. It can also be changed by calling ITextDocument2::SetDocumentFont(). Text run colors Similarly, an EM_SETCHARFORMAT message can set the text and/or background colors on the currently selected text run. For this, wparam = SCF_SELECTION and lparam = CHARFORMAT2 *. The text-run color can also be set by calling ITextFont::SetForeColor(), where the ITextFont object is obtained by calling ITextRange::GetFont() and the ITextRange selects the text run. Here any ITextRange can be used, which is handy since the call doesn’t change the user selection unless the ITextSelection range itself is used. The background color of a text run can be set on a run by calling ITextFont::SetBackColor(). Selection colors The text and background colors for selected text depend on whether acetate selection (described next) is active. If acetate selection isn’t active, the selection text color is obtained by calling ITextHost::TxGetSysColor(COLOR_HIGHLIGHTTEXT) and the selection background color is obtained by calling ITextHost::TxGetSysColor(COLOR_HIGHLIGHT). Acetate selection With acetate selection, the text color remains the same whether or not the text is selected except when the resulting text color is too close to the acetate background color to be read easily. The acetate background color is a blend of the background color and the color returned by ITextHost::TxGetSysColor(COLOR_HIGHLIGHT). More precisely, colors are defined by red, green and blue components in the COLORREF RGB DWORD defined by #define RGB(r,g,b)           ((COLORREF)(((BYTE)(r)|((WORD)((BYTE)(g))<<8))|(((DWORD)(BYTE)(b))<<16))) The acetate background red color is given by a fraction (f) of the background red (r) component plus the complementary fraction (1 − f) of the COLOR_HIGHLIGHT red component. Ditto for the green and blue components. Typically 39% of the COLOR_HIGHLIGHT RGB components are mixed with the corresponding background color components to get the acetate background color. Office applications use acetate selection, whereas Windows often doesn’t. One advantage of acetate selection for RichEdit is that partial ligature selection doesn’t get clipped by the rectangular selection background. This is illustrated in the following image where the f of an fi ligature is selected   Since the f’s text color doesn’t change when selected, the f’s underhang and overhang aren’t clipped. In contrast without acetate selection, RichEdit appears to select the whole fi ligature and clips the f’s underhang since RichEdit doesn’t have the code to render the ligature glyph three times with appropriate text colors. You can try out the selection with an Arabic ligature too, e.g., type a lam aleph (لا – gh with an Arabic keyboard) and then shift+→ to select the lam alone. You’ll see the acetate highlight go half way thru the لا. Acetate selection works the same way as in Word. Acetate selection is used by default in RichEdit. To disable acetate selection, send EM_SETEDITSTYLEEX with wparam = lparam = SES_EX_NOACETATESELECTION. Underline colors Underlines are displayed in the text color by default. But ITextFont::SetUnderline(value) can choose one of 16 COLORREFs as well as specifying an underline type. The MSDN documentation doesn’t yet say how the colors are defined, although the capability has been working for many years. Specifically the low byte of value specifies the underline type as documented in MSDN and the next byte has a color index. If that byte equals 0, then the text color is used for underlines. If it’s 1 up to 16, it’s a color index that accesses one of 16 COLORREFs defined in ITextDocument2::GetEffectColor(). The companion function ITextDocument2::SetEffectColor() can be used to change those color values if desired. As an example, ITextFont::SetUnderline(0x600 + tomDash) defines a red, dashed underline. Draft mode RichEdit has a special draft mode enabled by sending EM_SETEDITSTYLE with wparam = lparam = SES_DRAFTMODE. When enabled, all text is displayed with the font and font height given by ncm.lfMessageFont.lfFaceName and ncm. lfMessageFont.lfHeight, where ncm is obtained by                       NONCLIENTMETRICS ncm;                               ncm.cbSize = sizeof(NONCLIENTMETRICS);                SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(NONCLIENTMETRICS), &ncm, 0); The draft-mode text color is obtained by ITextHost::TxGetSysColor(COLOR_WINDOWTEXT). Place holder An empty RichEdit control without the UI focus can display place-holder text such as “Type answer here”. Such text is entered into the control by the EM_SETTEXTEX message with the ST_PLACEHOLDERTEXT flag (16) and it is displayed with the color for COLOR_GRAYTEXT. As soon as the control gets the focus, the placeholder text disappears. Temp formatting IMEs and proofing tools like to use character formatting such as squiggly underlines and special colors to indicate specialized text treatment, e.g., a spelling error. To avoid changing the underlying character formatting, RichEdit provides temporary formatting of underline type and color, and foreground and background colors. When such formatting is removed, the original formatting is used again for display. Temporary formatting isn’t persisted in file formats and can’t be read out by the client, only applied. To define temporary formatting properties, call ITextFont::Reset(tomApplyTmp) or ITextFont::Reset(tomApplyIMETmp for proofing or IME purposes, respectively. Then specify the temporary formatting colors by calling ITextFont::SetForeColor() and ITextFont::SetBackColor() as desired. Specify the temporary underline color and type by calling ITextFont::SetUnderline(value). Specifically if value = tomAutoColor, autocolor (default text color) is used. If (0xFF000000 & value) = 0xFF000000, the temporary underline color is set to 0x00FFFFFF & value. Else if value is a valid underline type, the temporary underline type is set to value. To apply the temporary formatting so defined, call ITextFont->Reset(tomApplyNow). If a temporary formatting property isn’t defined, the corresponding original property is used. High contrast and colored fonts RichEdit doesn’t have a special high contrast mode. So long as default colors are used, the RichEdit host can return high contrast colors for text, background and selection coloring. Furthermore in D2D/DWrite mode, the RichEdit host supplies an ID2D1RenderTarget (see ITextServices2::TxDrawD2D) that the host itself usually implements, calling D2D functions as necessary. If so the host can change the colors as desired on the fly. In particular, the host can force all text colors to be a specific high-contrast value and it can support colored fonts, such as Segoe UI Emoji. Too Similar If the text and background colors are too similar, the text color is changed to be visible relative to the background. The criterion for being too similar is that the squared length between the two colors in the three-dimensional RGB space is less than 4% of the maximum squared length. There may well be better criteria, but this seems to work pretty well in practice. If the colors are too similar, other possible text colors may be tried, but the ultimate choice is the XOR of the background color, i.e., use a text color given by the inverse of the background color (XOR each RGB bit with 1). This converts black into white, red into cyan, blue into yellow, etc., giving considerable contrast for most people. Math-zone highlighting and coloring When the selection is an insertion point (IP) in a math zone that has a default background color, relevant sections of the math zone are highlighted with a gray background. If the IP is not inside a math object, the whole math zone is highlighted with the light gray background RGB(232, 236, 239). If the IP is inside a math object, the object alone is highlighted with the light gray background and the argument of the object is highlighted with the slightly darker gray background RGB(215, 220, 230). That way the user can see which math object and argument are involved. For example, if the IP is in the numerator of a fraction, the numerator is highlighted with the darker gray background and the rest of the fraction is highlighted with the lighter gray background as in This differs from Word, which only displays the argument with a gray background. Word encloses the whole math zone in a border, which makes double highlighting less necessary. PowerPoint and OneNote use RichEdit to display math zones, so they have double highlighting. Selection inside a math zone uses the same coloring as outside a math zone. Math accents, fraction bars, enclosure borders, integral signs, etc. are displayed with the color assigned to the math object start delimiter. Hyperlinks RichEdit has automatic hyperlinks and friendly-name hyperlinks. Automatic hyperlink text is normally displayed in blue with a blue underline. But if blue is too similar to the background color, the color for COLOR_WINDOWTEXT is used. By default, friendly-name hyperlink text is also displayed in blue with a blue underline unless the name text is formatted with an explicit color. Explicit formatting takes precedence. The client can suppress the automatic blue coloring for friendly-name links by sending EM_SETEDITSTYLE with wparam = 0 and lparam = SES_EX_HANDLEFRIENDLYURL.    

Posted by on 27 March 2015 | 5:34 pm

MAT v4.0 Technical Preview Update 3 with Xamarin support

The Multilingual App Toolkit v4.0 Technical Preview Update 3 is available today (v4.0.1262.0).  The release continues to support Xamarin (Initial Announcement), bringing MAT’s streamlined localization workflow and services to Windows, iOS and Android platforms. This update adds support for Windows 10 Technical Preview Tools, support for Windows Store resource qualifiers, and exposes WinForm control values such as size and location. Universal App Platform Store resource qualifiers WinForm Size, Location, and TabIndex The list of key fixes are listed on the v4.0 Technical Preview article on our user voice site.  Please refer to http://aka.ms/matpreview for additional details and download links.  Of course, if you already have MAT v4.0 installed, Visual Studio will let you know that it’s time to install the update. Thank you, The Multilingual App Toolkit team multilingual@microsoft.com User voice site: http://aka.ms/matvoice v4.0 Technical Preview: http://aka.ms/matpreview

Posted by on 27 March 2015 | 4:52 pm