<?xml version="1.0" encoding="iso-8859-9" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Clomosy | Forum : prolistview&#039;e jsondan gerekli kısımların çekilmesi</title>
  <link>https://forum.clomosy.com.tr/</link>
  <description><![CDATA[XML içerik linki; Clomosy | Forum : Genel &#304;&#351;lemler : prolistview&#039;e jsondan gerekli kısımların çekilmesi]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Mon, 04 May 2026 16:04:12 +0000</pubDate>
  <lastBuildDate>Thu, 21 Nov 2024 09:19:46 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.07</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>https://forum.clomosy.com.tr/RSS_post_feed.asp?TID=961</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Clomosy | Forum]]></title>
   <url>https://forum.clomosy.com.tr/forum_images/logo.png</url>
   <link>https://forum.clomosy.com.tr/</link>
  </image>
  <item>
   <title><![CDATA[prolistview&#039;e jsondan gerekli kısımların çekilmesi : Merhaba K&#252;r&#351;at, ListView1.clL...]]></title>
   <link>https://forum.clomosy.com.tr/forum_posts.asp?TID=961&amp;PID=1898#1898</link>
   <description>
    <![CDATA[<strong>Yazar:</strong> <a href="https://forum.clomosy.com.tr/member_profile.asp?PF=142">BilalCndn</a><br /><strong>Konu:</strong> 961<br /><strong>Gönderim Zamanı:</strong> 21&nbsp;Kasım&nbsp;2024 Saat 09:19<br /><br />Merhaba Kürşat,<div><br></div><div><table width="99%"><tr><td><pre class="BBcode"></div><div>ListView1.clLoadProListViewDataFromDataset(Clomosy.ClDataSetFromJSON(<span style=": rgb251, 251, 253;">clRest.Response</span>));</div><div></pre></td></tr></table></div><div>Sadece bu satır ile bağlarsan sorunun çözülecektir. Tek tek FieldByName ile ayırmana gerek yok.</div><div><br></div><div><br></div><div>Statik JSON Kullanılmış Örnek Kod:</div><div><table width="99%"><tr><td><pre class="BBcode"></div><div><div>Var&nbsp; &nbsp;</div><div>&nbsp; Form1:TclForm;</div><div>&nbsp; ListView1 : TClProListView;</div><div>&nbsp; DesignerPanel1 : TClListViewDesignerPanel;</div><div>&nbsp; carI_KODU, carI_ADI, carI_IL : TclProLabel;</div><div>&nbsp;&nbsp;</div><div>void TaskClick;</div><div>{</div><div>&nbsp; ShowMessage(' Item: ' + ListView1.clSelectedItemData(clText));</div><div>}</div><div><br></div><div>void CreateListView</div><div>{</div><div>&nbsp; ListView1 = Form1.AddNewProListView(Form1,'ListView1');</div><div>&nbsp; ListView1.Align = AlClient;</div><div>&nbsp; ListView1.Margins.Bottom = 20;</div><div>&nbsp; ListView1.Margins.Top = 20;</div><div>&nbsp; ListView1.Margins.Right = 20;</div><div>&nbsp; ListView1.Margins.Left = 20;</div><div>&nbsp; ListView1.clProSettings.ViewType = lvIcon; //(lvList, lvIcon, lvWaterFall)</div><div>&nbsp; ListView1.clProSettings.ColCount = 1;</div><div>&nbsp; ListView1.clProSettings.ItemHeight = 100;</div><div>&nbsp; ListView1.clProSettings.ItemSpace = 10;</div><div>&nbsp; ListView1.clProSettings.BackgroundColor = clAlphaColor.clHexToColor('#FFFCFF');</div><div>&nbsp; ListView1.clProSettings.BorderColor = clAlphaColor.clHexToColor('#66FF7F');</div><div>&nbsp; ListView1.clProSettings.BorderWidth = 2;</div><div>&nbsp; ListView1.clProSettings.RoundHeight = 5;</div><div>&nbsp; ListView1.clProSettings.RoundWidth = 5;</div><div>&nbsp; ListView1.SetclProSettings(ListView1.clProSettings);</div><div>}</div><div><br></div><div>void CreateDesignerPanel</div><div>{</div><div>&nbsp; DesignerPanel1 = Form1.AddNewProListViewDesignerPanel(ListView1, 'DesignerPanel1');</div><div>&nbsp; DesignerPanel1.Height = 100;</div><div>&nbsp; DesignerPanel1.Width = 150;</div><div>&nbsp; DesignerPanel1.clProSettings.BackgroundColor = clAlphaColor.clHexToColor('#B3FCE5');</div><div>&nbsp; DesignerPanel1.clProSettings.BorderColor = clAlphaColor.clHexToColor('#16FF8C');</div><div>&nbsp; DesignerPanel1.clProSettings.BorderWidth = 2;</div><div>&nbsp; DesignerPanel1.clProSettings.RoundHeight = 20;</div><div>&nbsp; DesignerPanel1.clProSettings.RoundWidth = 20;</div><div>&nbsp; DesignerPanel1.SetclProSettings(DesignerPanel1.clProSettings);</div><div>&nbsp;&nbsp;</div><div>&nbsp; ListView1.SetDesignerPanel(DesignerPanel1);</div><div>}</div><div><br></div><div>void CreateData;</div><div>{</div><div>&nbsp; carI_KODU = Form1.AddNewProLabel(DesignerPanel1, 'carI_KODU', 'test');</div><div>&nbsp; carI_KODU.Align = AlVertCenter;</div><div>&nbsp; carI_KODU.Height =30;</div><div>&nbsp; carI_KODU.Margins.Bottom = 10;</div><div>&nbsp; carI_KODU.Margins.Top = 10;</div><div>&nbsp; carI_KODU.Margins.Left = 10;</div><div>&nbsp; carI_KODU.clProSettings.FontColor = clAlphaColor.clHexToColor('#000000');</div><div>&nbsp; carI_KODU.clProSettings.FontSize = 20;</div><div>&nbsp; DesignerPanel1.AddPanelObject(carI_KODU, clText);</div><div>&nbsp;&nbsp;</div><div>&nbsp;&nbsp;</div><div>&nbsp; carI_ADI = Form1.AddNewProLabel(DesignerPanel1, 'carI_ADI', 'test');</div><div>&nbsp; carI_ADI.Align = AlVertCenter;</div><div>&nbsp; carI_ADI.Height =30;</div><div>&nbsp; carI_ADI.Margins.Bottom = 10;</div><div>&nbsp; carI_ADI.Margins.Top = 10;</div><div>&nbsp; carI_ADI.Margins.Left = 100;</div><div>&nbsp; carI_ADI.clProSettings.FontColor = clAlphaColor.clHexToColor('#000000');</div><div>&nbsp; carI_ADI.clProSettings.FontSize = 20;</div><div>&nbsp; DesignerPanel1.AddPanelObject(carI_ADI, clText1);</div><div>&nbsp;&nbsp;</div><div>&nbsp;&nbsp;</div><div>&nbsp; carI_IL = Form1.AddNewProLabel(DesignerPanel1, 'carI_IL', 'test');</div><div>&nbsp; carI_IL.Align = AlVertCenter;</div><div>&nbsp; carI_IL.Height =30;</div><div>&nbsp; carI_IL.Margins.Bottom = 10;</div><div>&nbsp; carI_IL.Margins.Top = 10;</div><div>&nbsp; carI_IL.Margins.Left = 400;</div><div>&nbsp; carI_IL.clProSettings.FontColor = clAlphaColor.clHexToColor('#000000');</div><div>&nbsp; carI_IL.clProSettings.FontSize = 20;</div><div>&nbsp; DesignerPanel1.AddPanelObject(carI_IL, clText2);</div><div>&nbsp; &nbsp; &nbsp;&nbsp;</div><div>&nbsp; &nbsp;&nbsp;</div><div>&nbsp; Form1.AddNewEvent(ListView1,tbeOnItemClick,'TaskClick');</div><div>}</div><div><br></div><div>void AddDataToListView;</div><div>{</div><div>&nbsp; ListView1.clLoadProListViewDataFromDataset(Clomosy.ClDataSetFromJSON('&#091;</div><div>&nbsp; {</div><div>&nbsp; &nbsp; "carI_KODU": "1",</div><div>&nbsp; &nbsp; "carI_ADI": "Deneme Sanayi ve Ticaret Ltd. Şti.",</div><div>&nbsp; &nbsp; "carI_TIPI": "B",</div><div>&nbsp; &nbsp; "carI_ADRES": "Yıldırım Mh. Demir Sk. No:12",</div><div>&nbsp; &nbsp; "carI_ILCE": "Osmangazi",</div><div>&nbsp; &nbsp; "carI_IL": "Ankara",</div><div>&nbsp; &nbsp; "vergI_DAIRESI": "Bursa Vergi Dairesi",</div><div>&nbsp; &nbsp; "vergI_NO": "1234567890",</div><div>&nbsp; &nbsp; "tC_NO": "",</div><div>&nbsp; &nbsp; "carI_POSTAKODU": "16200",</div><div>&nbsp; &nbsp; "carI_TELEFON": "(224) 335-45-67",</div><div>&nbsp; &nbsp; "carI_YETKILI": "Ahmet Çalışkan",</div><div>&nbsp; &nbsp; "carI_EPOSTA": "info@mertotomotiv.com",</div><div>&nbsp; &nbsp; "carI_WEBSITE": "<a href="http://www.mertotomotiv.com" target="_blank" rel="nofollow">www.mertotomotiv.com"</a>,</div><div>&nbsp; &nbsp; "aciklamA1": "Yeni müşteri",</div><div>&nbsp; &nbsp; "aciklamA2": "Özel indirim uygulanacak",</div><div>&nbsp; &nbsp; "aciklamA3": "",</div><div>&nbsp; &nbsp; "borC_TOPLAM": 153000.0,</div><div>&nbsp; &nbsp; "alacaK_TOPLAM": 120000.0,</div><div>&nbsp; &nbsp; "giB_EFATURA_MUKELLEFI": true</div><div>},</div><div>{</div><div>&nbsp; &nbsp; "carI_KODU": "45",</div><div>&nbsp; &nbsp; "carI_ADI": "Mert Otomotiv Yedek Parça Sanayi ve Ticaret Ltd. Şti.",</div><div>&nbsp; &nbsp; "carI_TIPI": "B",</div><div>&nbsp; &nbsp; "carI_ADRES": "Yıldırım Mh. Demir Sk. No:12",</div><div>&nbsp; &nbsp; "carI_ILCE": "Osmangazi",</div><div>&nbsp; &nbsp; "carI_IL": "Bursa",</div><div>&nbsp; &nbsp; "vergI_DAIRESI": "Bursa Vergi Dairesi",</div><div>&nbsp; &nbsp; "vergI_NO": "1234567890",</div><div>&nbsp; &nbsp; "tC_NO": "",</div><div>&nbsp; &nbsp; "carI_POSTAKODU": "16200",</div><div>&nbsp; &nbsp; "carI_TELEFON": "(224) 335-45-67",</div><div>&nbsp; &nbsp; "carI_YETKILI": "Ahmet Çalışkan",</div><div>&nbsp; &nbsp; "carI_EPOSTA": "info@mertotomotiv.com",</div><div>&nbsp; &nbsp; "carI_WEBSITE": "<a href="http://www.mertotomotiv.com" target="_blank" rel="nofollow">www.mertotomotiv.com"</a>,</div><div>&nbsp; &nbsp; "aciklamA1": "Yeni müşteri",</div><div>&nbsp; &nbsp; "aciklamA2": "Özel indirim uygulanacak",</div><div>&nbsp; &nbsp; "aciklamA3": "",</div><div>&nbsp; &nbsp; "borC_TOPLAM": 153000.0,</div><div>&nbsp; &nbsp; "alacaK_TOPLAM": 120000.0,</div><div>&nbsp; &nbsp; "giB_EFATURA_MUKELLEFI": true</div><div>}</div><div>&nbsp; &#093;'));</div><div>}</div><div><br></div><div>{</div><div>&nbsp; Form1 = TclForm.Create(Self);</div><div>&nbsp; CreateListView;</div><div>&nbsp; CreateDesignerPanel;</div><div>&nbsp; CreateData;</div><div>&nbsp; AddDataToListview;</div><div>&nbsp; Form1.Run;</div><div>}</div></div><div><br></div><div></pre></td></tr></table></div><div><br></div><div>İyi çalışmalar dilerim.</div>]]>
   </description>
   <pubDate>Thu, 21 Nov 2024 09:19:46 +0000</pubDate>
   <guid isPermaLink="true">https://forum.clomosy.com.tr/forum_posts.asp?TID=961&amp;PID=1898#1898</guid>
  </item> 
  <item>
   <title><![CDATA[prolistview&#039;e jsondan gerekli kısımların çekilmesi : void addDataToComponent; var...]]></title>
   <link>https://forum.clomosy.com.tr/forum_posts.asp?TID=961&amp;PID=1893#1893</link>
   <description>
    <![CDATA[<strong>Yazar:</strong> <a href="https://forum.clomosy.com.tr/member_profile.asp?PF=184">kursat</a><br /><strong>Konu:</strong> 961<br /><strong>Gönderim Zamanı:</strong> 14&nbsp;Kasım&nbsp;2024 Saat 11:56<br /><br /><div>&nbsp; void addDataToComponent;</div><div>&nbsp; var</div><div>&nbsp; &nbsp; JSONObject: TCLJSONQuery;</div><div>&nbsp; &nbsp; clRest&nbsp; : TCLRest;</div><div>&nbsp; {</div><div>&nbsp; &nbsp; clRest=TCLRest.Create;</div><div>&nbsp; &nbsp; JSONObject = TCLJSONQuery.Create(nil);&nbsp;</div><div>&nbsp; &nbsp;&nbsp;</div><div>&nbsp; &nbsp; try</div><div>&nbsp; &nbsp; &nbsp; clRest.BaseURL = 'http://xxx:5050/ClApi/api/SABITCARI';</div><div>&nbsp; &nbsp; &nbsp; clRest.Accept = 'application/json';</div><div>&nbsp; &nbsp; &nbsp; clRest.Method = rmGET;</div><div>&nbsp; &nbsp; &nbsp; clRest.Execute;</div><div>&nbsp; &nbsp; &nbsp;&nbsp;</div><div>&nbsp; &nbsp; &nbsp; JSONObject = Clomosy.ClDataSetFromJSON(clRest.Response);</div><div>&nbsp; &nbsp; &nbsp;&nbsp;</div><div>&nbsp; &nbsp; &nbsp; if(JSONObject.Found){</div><div>&nbsp; &nbsp; &nbsp; &nbsp; while (not JSONObject.Eof)</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; PPListView1.clLoadProListViewDataFromDataset(Clomosy.ClDataSetFromJSON('&#091;' +</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '{"carI_KODU": "' + JSONObject.FieldByName('carI_KODU').AsString + '",' +</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '"carI_ADI": "' + JSONObject.FieldByName('carI_ADI').AsString + '",' +</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '"carI_IL": "' + JSONObject.FieldByName('carI_IL').AsString + '"}' +</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '&#093;'));</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; JSONObject.Next;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; //PPListView1.clLoadProListViewDataFromDataset(Clomosy.ClDataSetFromJSON(JSONObject));</div><div>&nbsp; &nbsp; &nbsp; }</div><div>&nbsp; &nbsp; &nbsp; else</div><div>&nbsp; &nbsp; &nbsp; &nbsp; ShowMessage('cari bulunamadi');</div><div>&nbsp; &nbsp; except</div><div>&nbsp; &nbsp; &nbsp; ShowMessage('Exception class: '+LastExceptionClassName+' Exception Message2: ' +LastExceptionMessage);</div><div>&nbsp; &nbsp; }</div><div>&nbsp; }<br><br>bu fonksiyon ile verileri prolistview içerisindeki carI_KODU,carI_ADI,carI_IL labellerine çekmek istiyorum ancak json yapısındaki <b><font size="4">son</font></b> değeri çekiyor.<br><br>eğer aşağıdaki gibi çekmek istersem sadece <b><font size="4">ilk</font></b> veriyi çekiyor.<br><div>PPListView1.clLoadProListViewDataFromDataset(Clomosy.ClDataSetFromJSON('&#091;' +</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '{"carI_KODU": "' + JSONObject.FieldByName('carI_KODU').AsString + '",' +</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '"carI_ADI": "' + JSONObject.FieldByName('carI_ADI').AsString + '",' +</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '"carI_IL": "' + JSONObject.FieldByName('carI_IL').AsString + '"}' +</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '&#093;'));</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; JSONObject.Next;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br><br>apide bulunan json aşağıdaki gibidir.<br><div>{</div><div>&nbsp; &nbsp; "carI_KODU": "45",</div><div>&nbsp; &nbsp; "carI_ADI": "Mert Otomotiv Yedek Parça Sanayi ve Ticaret Ltd. Şti.",</div><div>&nbsp; &nbsp; "carI_TIPI": "B",</div><div>&nbsp; &nbsp; "carI_ADRES": "Yıldırım Mh. Demir Sk. No:12",</div><div>&nbsp; &nbsp; "carI_ILCE": "Osmangazi",</div><div>&nbsp; &nbsp; "carI_IL": "Bursa",</div><div>&nbsp; &nbsp; "vergI_DAIRESI": "Bursa Vergi Dairesi",</div><div>&nbsp; &nbsp; "vergI_NO": "1234567890",</div><div>&nbsp; &nbsp; "tC_NO": "",</div><div>&nbsp; &nbsp; "carI_POSTAKODU": "16200",</div><div>&nbsp; &nbsp; "carI_TELEFON": "(224) 335-45-67",</div><div>&nbsp; &nbsp; "carI_YETKILI": "Ahmet Çalışkan",</div><div>&nbsp; &nbsp; "carI_EPOSTA": "info@mertotomotiv.com",</div><div>&nbsp; &nbsp; "carI_WEBSITE": "<a href="http://www.mertotomotiv.com" target="_blank" rel="nofollow">www.mertotomotiv.com"</a>,</div><div>&nbsp; &nbsp; "aciklamA1": "Yeni müşteri",</div><div>&nbsp; &nbsp; "aciklamA2": "Özel indirim uygulanacak",</div><div>&nbsp; &nbsp; "aciklamA3": "",</div><div>&nbsp; &nbsp; "borC_TOPLAM": 153000.0,</div><div>&nbsp; &nbsp; "alacaK_TOPLAM": 120000.0,</div><div>&nbsp; &nbsp; "giB_EFATURA_MUKELLEFI": true</div><div>}</div><div><br></div><div>tempJSON oluşturup döngü ile gerekli kısımları tek tek ona alıp gerekli verileri çekebileceğim bir fonksiyon örneği mevcut mu?</div><br></div></div>]]>
   </description>
   <pubDate>Thu, 14 Nov 2024 11:56:19 +0000</pubDate>
   <guid isPermaLink="true">https://forum.clomosy.com.tr/forum_posts.asp?TID=961&amp;PID=1893#1893</guid>
  </item> 
 </channel>
</rss>