18 Eylül 2014 Perşembe

Visual Studio 2013 Yeni Ozellikler

Quick lunch
Browser seçimli debug (2012de vardı sanıyorum, bizim için yeni olacak)
Tfs Bağlantısı – Detaylı Kod  Tarihçesi, Referanslar
Referanslar
CodeMap – Visual Debugging
Debug ta iken, code map’i tıklayınız. F10 / 11 ile ilerleyiniz.

Peek Definition – Alt+F12

İçinde olduğumuz class’ı kapatmadan, “navigate” penceresi açar. Açılan pencere içinden ALTf12 ile yeni  “peek” ler yapmaya devam edilebilir. Zincirleme çağrıları takip etmek, bulunduğumuz class’ı terketmeden bi bakıp çıkmak için ideal.

Code Lens   (ALT-2)

Roaming Settings

MSDN hesabınızla SIGN-IN olursanız, IDE ayarlarınızı istediğiniz makineye taşıyabilirsiniz.

Browsing Link

YNA da kapatmak zorunda kaldık. Gridler dağıldı.
Birden fazla browser açıp, aynı anda güncelleme ve görüntüleme sağlıyor.

Examine return values of method calls

Metod dönen değeri bir değişkene atanmamış olsa dahi AUTO penceresinden izlenebiliyor. (örnekte aramayın, kodda örnek bulamadım. Çıkacağı yerin görüntüsünü koydum)

Find Matching Clones

Sonuç

DİP NOT Sonuçları inceleyince, 2 metodun içinin %99 aynı olduğunu keşfettim. Yani gayet faydalı bir özellik olmuş.
TypeScript
TypeScript, JavaScript geliştirme sürecine sınıflar, modüller ve opsiyonel statik tipleri getiriyor. Visual Studio’da bu, yazma sırasında hata bildirimi, IntelliSense ve Rename tekrar düzenleme gibi zengin araçlar sağlıyor.

10 Eylül 2014 Çarşamba

5 Eylül 2014 Cuma

windows service olusturma ve kurulum

Selamlar,

 

Windows service olusturma ve install ile ilgili guzel bir msdn yazısı.

http://msdn.microsoft.com/en-us/library/zt39148a(v=vs.110).aspx

 

Ayrı bir install paketi icin VS2010 projelerinde setup ve deployment proje yaratıyorduk.

2012 de kaldırılmış. Installshield Limited Edition Template’i gelmiş.

http://msdn.microsoft.com/en-us/library/2kt85ked(v=vs.110).aspx

 

26 Ağustos 2014 Salı

SSRS The request failed with HTTP status 401: Unauthorized

SSRS  “The request failed with HTTP status 401: Unauthorized”

SOLVED

(Advanced Settings) ApplicationPool à  (Process Model)   NetworkService à Identity à NetworkService

Server Error in '/' Application.


The request failed with HTTP status 401: Unauthorized.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Net.WebException: The request failed with HTTP status 401: Unauthorized.

Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[WebException: The request failed with HTTP status 401: Unauthorized.]
   Microsoft.Reporting.WebForms.Internal.Soap.ReportingServices2005.Execution.RSExecutionConnection.GetSecureMethods() +192
   Microsoft.Reporting.WebForms.Internal.Soap.ReportingServices2005.Execution.RSExecutionConnection.IsSecureMethod(String methodname) +51
   Microsoft.Reporting.WebForms.Internal.Soap.ReportingServices2005.Execution.RSExecutionConnection.SetConnectionSSLForMethod(String methodname) +12
   Microsoft.Reporting.WebForms.Internal.Soap.ReportingServices2005.Execution.ProxyMethodInvocation.Execute(RSExecutionConnection connection, ProxyMethod`1 initialMethod, ProxyMethod`1 retryMethod) +417
   Microsoft.Reporting.WebForms.Internal.Soap.ReportingServices2005.Execution.RSExecutionConnection.LoadReport(String Report, String HistoryID) +180
   Microsoft.Reporting.WebForms.ServerReport.EnsureExecutionSession() +79
   Microsoft.Reporting.WebForms.ServerReport.GetParameters() +49
  


   YnaDialogBasePage.Page_Load(Object sender, EventArgs e) +130
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +51
   System.Web.UI.Control.OnLoad(EventArgs e) +92
   System.Web.UI.Control.LoadRecursive() +54
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +772



Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.17929

12 Ağustos 2014 Salı

TELERIK 2014.2.618.35 GEÇİŞİNDE ORTAYA ÇIKAN SORUNLAR VE ÇÖZÜMLERİ

TELERİK 2014.2.618.35 GEÇİŞİNDE ORTAYA ÇIKAN SORUNLAR VE ÇÖZÜMLERİ

HTML Hataları

<![if !supportLists]>·       <![endif]>Hataları ortaya çıkarmak için Internet Explorer Document Mode 7 ye geçmek gereklidir.
<![if !supportLists]>·       <![endif]>Maddeler kontrol önceliğine göre sıralanmıştır.
1))  RadGrid içindeki kolonların UniqeName değerlerinin farklı  (tekrar etmiyor) olması gerekiyor. Özelllikle Hem template column’a hem bound column’a aynı UniqeName verildiği örnekler var. Ayrıca birerbir aynı (kopyala/yapıstır) bound column tanımlanmış örneklere de rastladık.  TemplateColumnlar için Kolon ismini  =”TutarTemplateColumn” gibi verilebilir. Code behind’da bu yeniden adlandırılan (unique name ‘i değiştirilen ) kolonu kullanan yerlerde refactor yapılması gerekiyor.
 
2))  Bir kolonun DataField=”” alanında, bind edilen data da olmayan bir alan adı yazıyor ise, grid kolonları eksik gösteriyor. Örneğimizde bir kolonda DataField=”KumpanyaID” yazılmış. Halbuki bind edilen tabloda “KumpanyaID” diye alan yok “KumpanyaId” olmalı.
 
3))  <GridBoundColumn  Display=”false”> olan kolonlar, <columns></columns> bloğunun en altında yer alması gerekiyor.
 
4))  GridBoundColumn sayısı, griddeki diğer kolonlardan fazla olduğunda Grid’in kolonlarında bozukluk oluyor. Bu sayı aşmasa dahi kullanılmayan databoundcolumnlar silinmelidir.
<GridBoundColumn  Display=”false”> alan adedini azaltmak için
BoundColumn’u silip, Multiple datakeyname kullanabiliriz.
Griddten çektiğimiz Id ile, güncel bilgiye VT den erişecek bir yapıya geçeriz.
 
 


 
(Yukarıdaki maddelerin yol açabildiği kolonların eksik gösterildiği RadGrid’in görüntüsü)
 
5))          RadGrid’te detayları açan kolonun gözükmediği durumlarda, code behind’e ekleme yapmak gerekiyor.
 
 
 
6))          Html içinde bozukluk var ise görüntüde bozukluklar meydana geliyor.
<![if !supportLists]>                                                               i.      <![endif]>Aynı tablonun TR lerinde, TD lere farklı Width’ ler vermek.
<![if !supportLists]>                                                             ii.      <![endif]><TD> lerin %Width’lerin toplamının 100 yapmaması.
<![if !supportLists]>                                                            iii.      <![endif]>Kapanmamış veya hiç açılmamış “tag” ler
 


 

Breaking Changes

 
<![if !supportLists]>1.       <![endif]>Breaking Change : Visible yerine Display özelliği kullanılması gerekiyor. Visible false kalırsa item’dan değer gelmez. <telerik:GridBoundColumn DataField="BookingId" UniqueName="BookingId" Visible="false"   Display="false">
 
<![if !supportLists]>2.       <![endif]>Breaking Change : NoRecoudsTemplate grid’in en sağında yeni bir kolon olarak gözüküyordu. Arka planda colspan a değer atandığı için. Bu bir Bug. Bunu YNAMasterPage.master dosyasına aşağıdaki eklemeyi yaparak çözdük. Bu madde için başka bir müdehale yapılmasına artık gerek yok.
 
<![if !supportLists]>3.       <![endif]>Breaking Change : Uploaded file content lenght int->long
 

11 Temmuz 2014 Cuma

IIS subpath'te ayrı bir uygulama çalıştırmak

Merhaba,

 

IIS 7 ve üzerinde host edilen uygulamalarımızda, aynı domain ve subpath’lerinde farklı uygulamalar çalıştırmamız gereken durumlar olacaktır.

 

Örneğin;

xyz.fabrikam.com isimli dns’ten yayın yapan bir web application var. Klasik bir asp.net uygulaması. Forms authentication ile çalışıyor.

xyz.fabrikam.com\ozelservis isimli bir adresten web servis ile farklı uygulamalara data yayınlamak istiyoruz.

 

Mevcut durum:

 

İstenilen:

1)      Sağ click, add application

 

2)      Alias tanımlama ve web servis path’i gösterme

 

3)      Sonuç

Çalışma ortamını hazırladık.

Devamında yaşanan en büyük sorun, child uygulamanın, master uygulamanın web.config dosyasından etkilenmesi (en sık yaşanan örnek, site forms authenticationlı, web servis’e erişimde sıkıntı yaşanır).

Bunu yönetmek için en yaygın çözüm yöntemi inheritInChildApplications kullanımı.

Tag’in kullanımı ile ilgiye aşağıdaki linkten bakabilirsiniz.

http://msdn.microsoft.com/tr-tr/library/system.configuration.sectioninformation.inheritinchildapplications(v=vs.110).aspx

 

İyi çalışmalar

9 Temmuz 2014 Çarşamba

The report parameter is read-only and cannot be modified. (rsReadOnlyReportParameter)

The report parameter 'Parametre İsmi' is read-only and cannot be modified. (rsReadOnlyReportParameter)
1)) Rapor get latest alınır.
2)) Proje içinden rapor paremetresi Visible ve Prompt dolu hale getirilmelidir.

       3)) Hangi sunucuya devreye alım yapılacak ise,  sunucudan o rapor silinir ( yetki yoksa sildirilir.)

      4))  proje içinden rapor "deploy" yapılır.

1 Temmuz 2014 Salı

Telerik 2014.2.618.35 2014 Q2 Walkthrough

Telerik 2014.2.618.35 2014 Q2 Walkthrough

1- Fix Html Bugs
a) no "not opened tag", no "not closed tag" etc.,
b) same width for the same <td> in different <tr>
c) no duplicate UniqueName   between  <columns></columns> tags
d) GridColumns'  DataFields must exist in the data source  ( is DataField is set to ="XXX" , the datasource must have "XXX" field before the binding)

2- GridBoundColumn Property Tag Rename : Visible to Display
<telerik:GridBoundColumn DataField="BookingId" UniqueName="BookingId" Visible="false"   Display="false">
(Visible="false" columns are no more in the view state)

3- <GridBoundColumn… Display=false >
a) Number of these columns must fewer than other columns number.
b) These columns must be stated at bottom of <columns></columns> block

4- Web Config Settings

Add / Change

<appSettings>
    <add key="Telerik.Grid.Skin" value="2011"/>
    <add key="Telerik.Grid.EnableEmbeddedSkins" value="false"/>
    <add key="Telerik.GridFilterMenu.Skin" value="2011"/>
    <add key="Telerik.GridFilterMenu.EnableEmbeddedSkins" value="false"/>
    <add key="Telerik.Dock.Skin" value="Yna"/>
..
..
..

<controls>
        <add tagPrefix="telerik" namespace="Telerik.Web.UI" assembly="Telerik.Web.UI, Version=2014.2.618.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4"/>
      </controls>
5- if the GridExpandColumn does  not rendered properly

protected void BookingListesiGridView_ColumnCreated(object sender, GridColumnCreatedEventArgs e)
        {
            if (e.Column.ColumnType == "GridExpandColumn")
            {
                e.Column.HeaderStyle.Width = Unit.Pixel(35);
            }
        }

6- RadUpload ContentLenght property is long now. You may need to remove, change or add  the "conversion" code.

7 -Test your pages for different ie versions especially for Document mode 7 (f12 developer tools)

26 Haziran 2014 Perşembe

Telerik.Web.UI.WebResource.Exists System.NullReferenceException dynatrace

1. Check
 
Telerik.Web.UI.dll is in the GAC:
<system.webserver>
<handlers>
    … 
    <add name="Telerik.Web.UI.WebResource"  path="Telerik.Web.UI.WebResource.axd" verb="*"    type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Version=[ASSEMBLY_VERSION], Culture=neutral, PublicKeyToken=121fae78165ba3d4" />
    …
</handlers>
</system.webserver>
 
 
Telerik.Web.UI.dll is not in the GAC:
              
<system.webserver>
<handlers>
    … 
    <add name="Telerik.Web.UI.WebResource"  path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI" />
    …
</handlers>
</system.webserver>
 
 
<httpHandlers>
      <add path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI" validate="false"/>
      <add verb="POST,GET,HEAD" path="elmah.axd" type="Elmah.ErrorLogPageFactory, Elmah"/>
    </httpHandlers>
 
 
 
2. Check
 
IIS7 Integrated Mode: The following statement should be present in the <handlers> section instead of <httpHandlers>:
<handlers> 
<add name="Telerik.Web.UI.WebResource" 
path="Telerik.Web.UI.WebResource.axd" verb="*"  
type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Culture=neutral, PublicKeyToken=121fae78165ba3d4"/>
 
 <handlers>
      <add name="TelerikHandler" path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI" />
      <add name="Elmah" path="elmah.axd" verb="POST,GET,HEAD" type="Elmah.ErrorLogPageFactory, Elmah" preCondition="integratedMode" />
      <add name="ReportViewerWebControlHandler" preCondition="integratedMode" verb="*" path="Reserved.ReportViewerWebControl.axd" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
    </handlers>
  </system.webServer>
 

13 Haziran 2014 Cuma

Publish Sırasinda web.config Nasıl Exclude Yapılır

Visual Studio ile çalışıyorsunuz ve canlı ortamdaki web.config dosyanızı publish sırasında ezmek istemiyorsunuz.

 

Çözümü oldukça basit;

Simply select the web.config properties and change 'Build Action' to 'None' and 'Copy To Output Directory' to 'Do Not copy'

 

Kolay gelsin..