{"id":805,"date":"2010-06-28T14:25:28","date_gmt":"2010-06-28T14:25:28","guid":{"rendered":"http:\/\/www.erbugkaya.com\/?p=805"},"modified":"2014-01-16T23:20:59","modified_gmt":"2014-01-16T23:20:59","slug":"expression-ile-wpf-uygulamasi-ii-proje-database-expression-blend-2","status":"publish","type":"post","link":"http:\/\/erbugkaya.com\/?p=805","title":{"rendered":"Expression ile WPF Uygulamas\u0131 &#8211; II &#8211; Proje, Database (Expression Blend 2)"},"content":{"rendered":"<p>6\/3\/2009<br \/>\nMerhaba Expression ile WPF Uygulamas\u0131n\u0131n 2. makalesiyle devam ediyoruz. Bu makalede Expression Blend ile yeni bir WPF projesi olu\u015fturup, Expression Design ile haz\u0131rlad\u0131\u011f\u0131m\u0131z tasar\u0131m\u0131 bu projeye aktaraca\u011f\u0131z ve XML&#8217;i kullanarak kontrol\u00fcm\u00fcze veri \u00e7ekece\u011fiz.<\/p>\n<p><!--more--><br \/>\nBa\u015flayal\u0131m. Expression Blend 2 yi a\u00e7\u0131n. File&gt;New Project&#8217;e bas\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_01.jpg\" width=\"220\" height=\"265\" \/><\/p>\n<p>New Project penceresinden &#8220;WPF Application (.exe)&#8221; yi se\u00e7in. Proje isminizi, proje klas\u00f6r\u00fcn\u00fcz\u00fc, kod dilinizi (bu makale dizisinde kod kullanmayaca\u011f\u0131z) ve framework&#8217;u belirleyin.<\/p>\n<p><a href=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_02.jpg\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_02.jpg\" width=\"299\" height=\"197\" \/><\/a><\/p>\n<p>Projeniz a\u00e7\u0131l\u0131nca sa\u011fdaki Project tab\u0131na bas\u0131p, proje isminizin oldu\u011fu ba\u015fl\u0131\u011fa sa\u011f klik yap\u0131n ve &#8220;Add Existing Item&#8221; a t\u0131klay\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_03.jpg\" width=\"292\" height=\"330\" \/><\/p>\n<p>Haz\u0131rlam\u0131\u015f oldu\u011funuz XML&#8217;i ve Expression Design&#8217;dan \u00e7\u0131kan XAML&#8217;\u0131n\u0131z\u0131 s\u0131rayla projeye ekleyin.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_04.jpg\" width=\"294\" height=\"233\" \/><\/p>\n<p>Yine ayn\u0131 yere sa\u011f klik yap\u0131p bu sefer &#8220;Add New Folder&#8221; a bas\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_05.jpg\" width=\"300\" height=\"334\" \/><\/p>\n<p>Bu klas\u00f6re images ad\u0131n\u0131 verin.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_06.jpg\" width=\"298\" height=\"280\" \/><\/p>\n<p>images klas\u00f6r\u00fcne sa\u011f t\u0131klay\u0131n ve &#8220;Add Existing Item&#8221; a bas\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_07.jpg\" width=\"283\" height=\"239\" \/><\/p>\n<p>Veriler i\u00e7in haz\u0131rlam\u0131\u015f oldu\u011funuz imajlar\u0131 projenize ekleyin.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_08.jpg\" width=\"313\" height=\"274\" \/><\/p>\n<p>Project penceresi \u015fu durumdad\u0131r.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_09.jpg\" width=\"191\" height=\"609\" \/><\/p>\n<p>Solution sat\u0131r\u0131na sa\u011f t\u0131klay\u0131p projenizden Visual Studio ya da ge\u00e7i\u015f yapabilirsiniz.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_10.jpg\" width=\"289\" height=\"281\" \/><\/p>\n<p>Blend\u00a0 ve Visual Studio ayn\u0131 proje penceresine sahipler.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_11.jpg\" width=\"283\" height=\"558\" \/><\/p>\n<p>Blend&#8217;de her zaman <strong>F5<\/strong> e basarak projeyi \u00e7al\u0131\u015ft\u0131rabilir ve sonucu g\u00f6rebilirsiniz.<\/p>\n<p><a href=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_12.jpg\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_12.jpg\" width=\"397\" height=\"298\" \/><\/a><\/p>\n<p>&#8220;Objects and Timeline&#8221; kutusunda Window layer \u0131na \u00e7ift t\u0131klay\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_13.jpg\" width=\"256\" height=\"140\" \/><\/p>\n<p>Window se\u00e7iliyken sa\u011f tarafta Properties tab\u0131ndaki Layout\u00a0 k\u0131sm\u0131nda a\u00e7\u0131lacak pencerenin boyunun ve y\u00fcksekli\u011fini ayarlay\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_14.jpg\" width=\"280\" height=\"238\" \/><\/p>\n<p>Proje penceresinde FRPKitap.xaml&#8217; e \u00e7ift t\u0131klay\u0131p a\u00e7\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_15.jpg\" width=\"166\" height=\"26\" \/><\/p>\n<p>Blend&#8217;de FRPKitap.xaml g\u00f6r\u00fcnt\u00fcs\u00fc. Design&#8217;de nas\u0131l haz\u0131rlad\u0131ysak \u00f6yle g\u00f6z\u00fck\u00fcyor.<\/p>\n<p><a href=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_16.jpg\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_16.jpg\" width=\"480\" height=\"349\" \/><\/a><\/p>\n<p>FRPKitap.xaml da Background layer\u0131na sa\u011f klik yap\u0131p onu kopyalay\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_17.jpg\" width=\"303\" height=\"406\" \/><\/p>\n<p>\u00dcst taraftaki tab sistemini kullanarak Blend&#8217;le olu\u015fturdu\u011funuz XAML&#8217;e geri d\u00f6n\u00fcn.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_18.jpg\" width=\"201\" height=\"20\" \/><\/p>\n<p>LayoutRoot layer\u0131n\u0131 \u00e7ift t\u0131klayarak se\u00e7in ve art board da bo\u015f bir yere t\u0131klay\u0131p CTRL+V yap\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_18-b.jpg\" width=\"249\" height=\"135\" \/><\/p>\n<p>Sonu\u00e7. Altta.<\/p>\n<p><a href=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_19.jpg\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_19.jpg\" width=\"450\" height=\"349\" \/><\/a><\/p>\n<p><strong>F5 <\/strong>e basarsan\u0131z uygulaman\u0131z\u0131n durumunu g\u00f6rebilirsiniz.<\/p>\n<p><a href=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_20.jpg\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_20.jpg\" width=\"450\" height=\"349\" \/><\/a><\/p>\n<p>Layer d\u00fczeni \u015fu \u015fekilde olmal\u0131d\u0131r.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_21.jpg\" width=\"261\" height=\"237\" \/><\/p>\n<p>Genel tasar\u0131m\u0131 tamamlad\u0131\u011f\u0131m\u0131za g\u00f6re \u015fimdi i\u00e7eri\u011fimizi olu\u015fturabiliriz. Bunun i\u00e7in Tool Box&#8217;dan &#8220;Asset Library&#8221; ikonuna t\u0131kl\u0131yoruz ve a\u00e7\u0131lan pencereden ListBox kontrol\u00fcn\u00fc se\u00e7iyoruz. ListBox kontrol\u00fc g\u00f6z\u00fckm\u00fcyorsa sa\u011f \u00fcst k\u00f6\u015fedeki &#8220;Show All&#8221; kutucu\u011funu i\u015faretleyin.<\/p>\n<p><a href=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_22.jpg\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_22.jpg\" width=\"394\" height=\"226\" \/><\/a><\/p>\n<p>ListBox kontrol\u00fcn\u00fc \u00e7al\u0131\u015fma alan\u0131nda s\u00fcr\u00fckleyerek olu\u015fturuyoruz.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_25.jpg\" width=\"400\" height=\"309\" \/><\/p>\n<p>Layer d\u00fczeni alttaki gibi olu\u015fmu\u015f olmal\u0131d\u0131r.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_24.jpg\" width=\"250\" height=\"87\" \/><\/p>\n<p>ListBox&#8217;\u0131m\u0131mz haz\u0131r oldu\u011funa g\u00f6re \u015fimdi onun i\u00e7ine veri \u00e7ekebiliriz. Tabi \u00f6nce XML e ba\u011flanmal\u0131y\u0131z. Bunun i\u00e7in Project sekmesindeki Data kutusundaki &#8220;+XML&#8221; e t\u0131klay\u0131n.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_26.jpg\" width=\"293\" height=\"110\" \/><\/p>\n<p>A\u00e7\u0131lan pencerede isimi belirleyin ve XML dosyan\u0131z\u0131 HD&#8217;den bulun.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_27.jpg\" width=\"457\" height=\"164\" \/><\/p>\n<p>XML t\u00fcm d\u00fc\u011f\u00fcmleriyle Blend&#8217;de g\u00f6z\u00fckmektedir.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_27-b.jpg\" width=\"291\" height=\"337\" \/><\/p>\n<p>KITAP d\u00fc\u011f\u00fcm\u00fcnden tutup ListBox&#8217;\u0131n \u00fczerine s\u00fcr\u00fckleyin. Bunu yap\u0131nca bir men\u00fc a\u00e7\u0131lacak. (Bind &#8220;KITAP&#8221; to &#8220;ListBox&#8221;) \u0131 se\u00e7in.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_28.jpg\" width=\"256\" height=\"160\" \/><\/p>\n<p>Gelen pencereye OK deyin.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_29.jpg\" width=\"440\" height=\"144\" \/><\/p>\n<p>Create Data Template penceresine de OK deyin.<\/p>\n<p><a href=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_30.jpg\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_30.jpg\" width=\"478\" height=\"341\" \/><\/a><\/p>\n<p>XML&#8217;imiz ListBox i\u00e7inde listelenmi\u015ftir.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" alt=\"\" src=\"http:\/\/www.yazgelistir.com\/Makaleler\/Resimler\/1000002138_31.jpg\" width=\"400\" height=\"309\" \/><\/p>\n<p>&#8220;Expression ile WPF Uygulamas\u0131&#8221; makale serisinin bu ad\u0131m\u0131nda Blend&#8217;le proje olu\u015fturup, tasar\u0131m\u0131 bu projeye oturttuk. XML ile ba\u011flant\u0131 kurup, veri \u00e7ektik. Sonraki ad\u0131mda WPF kontrollerimizi d\u00fczenleyece\u011fiz.<\/p>\n<p>\u0130yi \u00e7al\u0131\u015fmalar<\/p>\n<p>Te\u015fekk\u00fcrler.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>6\/3\/2009 Merhaba Expression ile WPF Uygulamas\u0131n\u0131n 2. makalesiyle devam ediyoruz. Bu makalede Expression Blend ile yeni bir WPF projesi olu\u015fturup, Expression Design ile haz\u0131rlad\u0131\u011f\u0131m\u0131z tasar\u0131m\u0131 bu projeye aktaraca\u011f\u0131z ve XML&#8217;i kullanarak kontrol\u00fcm\u00fcze veri \u00e7ekece\u011fiz.<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[68],"tags":[41,21,47],"class_list":["post-805","post","type-post","status-publish","format-standard","hentry","category-kitaplar","tag-expression-blend","tag-expression-studio","tag-wpf"],"_links":{"self":[{"href":"http:\/\/erbugkaya.com\/index.php?rest_route=\/wp\/v2\/posts\/805","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/erbugkaya.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/erbugkaya.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/erbugkaya.com\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/erbugkaya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=805"}],"version-history":[{"count":5,"href":"http:\/\/erbugkaya.com\/index.php?rest_route=\/wp\/v2\/posts\/805\/revisions"}],"predecessor-version":[{"id":2453,"href":"http:\/\/erbugkaya.com\/index.php?rest_route=\/wp\/v2\/posts\/805\/revisions\/2453"}],"wp:attachment":[{"href":"http:\/\/erbugkaya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=805"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/erbugkaya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=805"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/erbugkaya.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=805"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}