<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Sniper &#187; msaccess</title>
	<atom:link href="http://tuncay.kinali.net/etiketler/msaccess/feed" rel="self" type="application/rss+xml" />
	<link>http://tuncay.kinali.net</link>
	<description>Hafızamın bir kısmı</description>
	<lastBuildDate>Sat, 22 May 2010 10:22:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>ASP ile MS Access verilerini sayfalama</title>
		<link>http://tuncay.kinali.net/asp-ile-ms-access-verilerini-sayfalama.html</link>
		<comments>http://tuncay.kinali.net/asp-ile-ms-access-verilerini-sayfalama.html#comments</comments>
		<pubDate>Tue, 10 Mar 2009 18:23:10 +0000</pubDate>
		<dc:creator>Sniper</dc:creator>
				<category><![CDATA[ASP]]></category>
		<category><![CDATA[access]]></category>
		<category><![CDATA[msaccess]]></category>
		<category><![CDATA[sayfalama]]></category>

		<guid isPermaLink="false">http://kinali.net/?p=8</guid>
		<description><![CDATA[MS Access veritabanından gelen verileri sayfalamak, MySQL veritabanına oranla çok daha basittir. Bu basitliğin nedeni Recordset nesnesi tarafından desteklenmesinden kaynaklanmaktadır. Bu yazımda sizlere MS Access vertabanından gelen verileri, Recordset nesnesini kullanarak sayfalama konusundan bahsedeceğim. Aşağıdaki kodlardan faydalanmak için sniper.mdb.zip dosyasını indirip kodlarla aynı dizine eklemeniz gerekmektedir. Lafı fazla uzatmadan hemen kodlara giriyorum. Öncelikle her zaman [...]]]></description>
			<content:encoded><![CDATA[<p>MS Access veritabanından gelen verileri sayfalamak, MySQL veritabanına oranla çok daha basittir. Bu basitliğin nedeni Recordset nesnesi tarafından desteklenmesinden kaynaklanmaktadır. Bu yazımda sizlere MS Access vertabanından gelen verileri, Recordset nesnesini kullanarak sayfalama konusundan bahsedeceğim. Aşağıdaki kodlardan faydalanmak için sniper.mdb.zip dosyasını indirip kodlarla aynı dizine eklemeniz gerekmektedir. Lafı fazla uzatmadan hemen kodlara giriyorum.<br />
<span id="more-8"></span><br />
Öncelikle her zaman olduğu gibi değişkenlerimizi tanımlıyoruz, bağlantı ve Recordset nesnemizi açarak sayfalamak istediğimiz verilerimizi çekiyoruz:</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p8code6'); return false;">View Code</a> ASP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p86"><td class="code" id="p8code6"><pre class="asp" style="font-family:monospace;"><span style="color: #990099; font-weight: bold;">Option</span> <span style="color: #990099; font-weight: bold;">Explicit</span>
<span style="color: #990099; font-weight: bold;">Dim</span> Bag, Rs, i, s, Sayfa, SQL
&nbsp;
<span style="color: #990099; font-weight: bold;">Set</span> Bag <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #990099; font-weight: bold;">Server</span>.<span style="color: #330066;">CreateObject</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;ADODB.Connection&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span>
<span style="color: #990099; font-weight: bold;">Set</span> Rs <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #990099; font-weight: bold;">Server</span>.<span style="color: #330066;">CreateObject</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;ADODB.Recordset&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span>
&nbsp;
Bag.<span style="color: #330066;">Open</span> <span style="color: #cc0000;">&quot;Provider=Microsoft.Jet.OLEDB.4.0; Data Source=&quot;</span> <span style="color: #006600; font-weight: bold;">&amp;</span> <span style="color: #990099; font-weight: bold;">Server</span>.<span style="color: #330066;">MapPath</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;sniper.mdb&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span>
&nbsp;
SQL <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #cc0000;">&quot;SELECT * FROM tblSiteler&quot;</span>
Rs.<span style="color: #330066;">Open</span> SQL, Bag, <span style="color: #800000;">1</span>, <span style="color: #800000;">3</span></pre></td></tr></table></div>

<p>Bağlantımızı açtıktan sonra kayıt setimizden veri dönüp dönmediğini kontrol etmeliyiz. Bu sayfalama kodunda kullanacağımız Recordset nesnesinin AbsolutePage özelliğinin hata vermemesi için önemlidir. AbsolutePage özelliği, kayıtsetine hangi sayfada olduğumuzu söyleyen kontrolümüzdür. Kontrolümüzü yaptıktan sonra nesnemizin PageSize özelliğiyle bir sayfada görüntülenecek kayıt sayısını belirleyip tablomuzu sayfamıza çizdiriyoruz.</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p8code7'); return false;">View Code</a> ASP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p87"><td class="code" id="p8code7"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
<span style="color: #990099; font-weight: bold;">If</span> <span style="color: #990099; font-weight: bold;">Not</span> Rs.<span style="color: #0000ff; font-weight: bold;">EOF</span> <span style="color: #990099; font-weight: bold;">Then</span>
  <span style="color: #008000;">'Bir sayfada gösterilecek kayıt sayısını belirliyoruz</span>
  Rs.<span style="color: #9900cc;">PageSize</span> <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #800000;">2</span>
&nbsp;
  <span style="color: #008000;">'Eğer QueryString'de sayfa değişkeni tanımlanmışsa</span>
  <span style="color: #990099; font-weight: bold;">If</span> <span style="color: #990099; font-weight: bold;">Request</span>.<span style="color: #330066;">QueryString</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;s&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span> <span style="color: #006600; font-weight: bold;">&lt;&gt;</span> <span style="color: #cc0000;">&quot;&quot;</span> <span style="color: #990099; font-weight: bold;">Then</span>
    <span style="color: #008000;">'Bulunduğumuz sayfayı bu değişkenin değeri olarak atayalım</span>
    Sayfa <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #990099; font-weight: bold;">CInt</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #990099; font-weight: bold;">Request</span>.<span style="color: #9900cc;">QueryString</span><span style="color: #006600; font-weight: bold;">&lt;</span> font<span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;s&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span><span style="color: #006600; font-weight:bold;">&#41;</span>
  <span style="color: #990099; font-weight: bold;">Else</span>
    <span style="color: #008000;">'Değilse başlangıç sayfa numaramızı 1 olarak atayalım</span>
    Sayfa <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #800000;">1</span>
  <span style="color: #990099; font-weight: bold;">End</span> <span style="color: #990099; font-weight: bold;">If</span>
&nbsp;
  <span style="color: #008000;">' ve Kayıtsetimize hangi sayfada bulunduğumuzu söyleyelim.</span>
  Rs.<span style="color: #9900cc;">AbsolutePage</span> <span style="color: #006600; font-weight: bold;">=</span> Sayfa
<span style="color: #000000; font-weight: bold;">%&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>table border<span style="color: #cc0000;">&quot;1&quot;</span> bordercolor<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;#C0C0C0&quot;</span> style<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;border-collapse:collapse; font:normal normal normal 11px verdana;&quot;</span> width<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;500&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>td width<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;5&quot;</span> bgcolor<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;#FFFBDF&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span>b<span style="color: #006600; font-weight: bold;">&gt;</span>S<span style="color: #006600; font-weight: bold;">&lt;/</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;&lt;&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>td width<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;245&quot;</span> bgcolor<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;#FFFBDF&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span>b<span style="color: #006600; font-weight: bold;">&gt;</span>Site Adı<span style="color: #006600; font-weight: bold;">&lt;/</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>td width<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;250&quot;</span> bgcolor<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;#FFFBDF&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span>b<span style="color: #006600; font-weight: bold;">&gt;</span>URL
<span style="color: #006600; font-weight: bold;">&lt;/</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;/</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>table<span style="color: #006600; font-weight: bold;">&gt;</span></pre></td></tr></table></div>

<p>Şimdi elimizdekileri verileri, bir sayfada gösterilecek kayıt sayısınca sayfamıza bastıracak olan döngümüzü yazıyoruz:</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p8code8'); return false;">View Code</a> ASP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p88"><td class="code" id="p8code8"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
  i<span style="color: #006600; font-weight: bold;">=</span><span style="color: #800000;">0</span>
  <span style="color: #008000;">'Kayıtsetimizi bir sayfada gösterilecek kayıt sayısı adedince döndürelim.</span>
&nbsp;
  <span style="color: #990099; font-weight: bold;">Do</span> <span style="color: #990099; font-weight: bold;">While</span> <span style="color: #990099; font-weight: bold;">Not</span> Rs.<span style="color: #0000ff; font-weight: bold;">EOF</span> <span style="color: #0000ff; font-weight: bold;">And</span> i<span style="color: #006600; font-weight: bold;">&lt;</span>Rs.<span style="color: #9900cc;">PageSize</span>
<span style="color: #000000; font-weight: bold;">%&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>td align<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;center&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span> <span style="color: #006600; font-weight: bold;">%=</span>i+<span style="color: #800000;">1</span><span style="color: #000000; font-weight: bold;">%&gt;</span><span style="color: #006600; font-weight: bold;">&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>td<span style="color: #006600; font-weight: bold;">&gt;&lt;</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;</span> <span style="color: #006600; font-weight: bold;">%=</span>Rs<span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;fldSiteAdi&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span><span style="color: #000000; font-weight: bold;">%&gt;</span><span style="color: #006600; font-weight: bold;">&lt;/</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>td<span style="color: #006600; font-weight: bold;">&gt;&lt;</span>a href<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;&lt;%=Rs(&quot;</span>fldURL<span style="color: #cc0000;">&quot;)%&gt;&quot;</span> style<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;color:#0000FF&quot;</span> target<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;_blank&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span> <span style="color: #006600; font-weight: bold;">%=</span>Rs<span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;fldURL&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span><span style="color: #000000; font-weight: bold;">%&gt;</span><span style="color: #006600; font-weight: bold;">&lt;/</span>a<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;/</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
  i<span style="color: #006600; font-weight: bold;">=</span>i+<span style="color: #800000;">1</span>
  Rs.<span style="color: #330066;">MoveNext</span>
<span style="color: #990099; font-weight: bold;">Loop</span>
<span style="color: #000000; font-weight: bold;">%&gt;</span></pre></td></tr></table></div>

<p>Veriler istediğimiz sayıda sayfaya yazıldı. Şimdi sıra sayfa numaralarını linklendirmeye geldi:</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p8code9'); return false;">View Code</a> ASP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p89"><td class="code" id="p8code9"><pre class="asp" style="font-family:monospace;">  <span style="color: #006600; font-weight: bold;">&lt;</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;</span>td colspan<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;3&quot;</span> align<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;right&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
  <span style="color: #008000;">' ve son olarak ta sayfaların linklerini sayfamıza bastıralım.</span>
  <span style="color: #990099; font-weight: bold;">If</span> Rs.<span style="color: #9900cc;">PageCount</span> <span style="color: #006600; font-weight: bold;">&gt;</span> <span style="color: #800000;">0</span> <span style="color: #990099; font-weight: bold;">Then</span>
    <span style="color: #990099; font-weight: bold;">For</span> s<span style="color: #006600; font-weight: bold;">=</span><span style="color: #800000;">1</span> <span style="color: #990099; font-weight: bold;">To</span> Rs.<span style="color: #9900cc;">PageCount</span>
      <span style="color: #990099; font-weight: bold;">Response</span>.<span style="color: #330066;">Write</span> <span style="color: #cc0000;">&quot;&lt;a href=&quot;</span><span style="color: #cc0000;">&quot;?s=&quot;</span> <span style="color: #006600; font-weight: bold;">&amp;</span> s <span style="color: #006600; font-weight: bold;">&amp;</span> <span style="color: #cc0000;">&quot;&quot;</span><span style="color: #cc0000;">&quot;&gt;&quot;</span> <span style="color: #006600; font-weight: bold;">&amp;</span> s <span style="color: #006600; font-weight: bold;">&amp;</span> <span style="color: #cc0000;">&quot;&lt;/a&gt; &quot;</span>
    <span style="color: #990099; font-weight: bold;">Next</span>
  <span style="color: #990099; font-weight: bold;">End</span> <span style="color: #990099; font-weight: bold;">If</span>
<span style="color: #000000; font-weight: bold;">%&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
  <span style="color: #006600; font-weight: bold;">&lt;/</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
&nbsp;
<span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
  <span style="color: #008000;">' Bitti, hayırlı olsun...</span>
<span style="color: #990099; font-weight: bold;">End</span> <span style="color: #990099; font-weight: bold;">If</span>
<span style="color: #000000; font-weight: bold;">%&gt;</span></pre></td></tr></table></div>

<p>Ms Access ile sayfalama işlemi bu kadar basit. Kaliteli sitelerde kullanmanız dileğinde bulunduktan sonra yazımı kodların tamamıyla kapatıyorum&#8230;</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p8code10'); return false;">View Code</a> ASP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p810"><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
</pre></td><td class="code" id="p8code10"><pre class="asp" style="font-family:monospace;"><span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
<span style="color: #990099; font-weight: bold;">Option</span> <span style="color: #990099; font-weight: bold;">Explicit</span>
<span style="color: #990099; font-weight: bold;">Dim</span> Bag, Rs, i, s, Sayfa, SQL
&nbsp;
<span style="color: #990099; font-weight: bold;">Set</span> Bag <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #990099; font-weight: bold;">Server</span>.<span style="color: #330066;">CreateObject</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;ADODB.Connection&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span>
<span style="color: #990099; font-weight: bold;">Set</span> Rs <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #990099; font-weight: bold;">Server</span>.<span style="color: #330066;">CreateObject</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;ADODB.Recordset&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span>
&nbsp;
Bag.<span style="color: #330066;">Open</span> <span style="color: #cc0000;">&quot;Provider=Microsoft.Jet.OLEDB.4.0; Data Source=&quot;</span> <span style="color: #006600; font-weight: bold;">&amp;</span> <span style="color: #990099; font-weight: bold;">Server</span>.<span style="color: #330066;">MapPath</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;sniper.mdb&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span>
&nbsp;
SQL <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #cc0000;">&quot;SELECT * FROM tblSiteler&quot;</span>
Rs.<span style="color: #330066;">Open</span> SQL, Bag, <span style="color: #800000;">1</span>, <span style="color: #800000;">3</span>
<span style="color: #990099; font-weight: bold;">If</span> <span style="color: #990099; font-weight: bold;">Not</span> Rs.<span style="color: #0000ff; font-weight: bold;">EOF</span> <span style="color: #990099; font-weight: bold;">Then</span>
&nbsp;
<span style="color: #008000;">'Bir sayfada gösterilecek kayıt sayısını belirliyoruz   Rs.</span>
PageSize <span style="color: #006600; font-weight: bold;">=</span> <span style="color: #800000;">2</span>
&nbsp;
<span style="color: #008000;">'Eğer QueryString'de sayfa değişkeni tanımlanmışsa  </span>
<span style="color: #990099; font-weight: bold;">If</span> <span style="color: #990099; font-weight: bold;">Request</span>.<span style="color: #330066;">QueryString</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;s&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span> <span style="color: #006600; font-weight: bold;">&lt;&gt;</span> <span style="color: #cc0000;">&quot;&quot;</span> <span style="color: #990099; font-weight: bold;">Then</span>    
<span style="color: #008000;">'Bulunduğumuz sayfayı bu değişkenin değeri olarak atayalım     Sayfa =</span>
<span style="color: #990099; font-weight: bold;">CInt</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #990099; font-weight: bold;">Request</span>.<span style="color: #9900cc;">QueryString</span><span style="color: #006600; font-weight: bold;">&lt;</span> font<span style="color: #006600; font-weight: bold;">&gt;</span><span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;s&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span><span style="color: #006600; font-weight:bold;">&#41;</span>  
<span style="color: #990099; font-weight: bold;">Else</span>    
<span style="color: #008000;">'Değilse başlangıç sayfa numaramızı 1 olarak atayalım     Sayfa = 1</span>
&nbsp;
<span style="color: #990099; font-weight: bold;">End</span> <span style="color: #990099; font-weight: bold;">If</span>
&nbsp;
<span style="color: #008000;">' ve Kayıtsetimize hangi sayfada bulunduğumuzu söyleyelim.   Rs.</span>
AbsolutePage <span style="color: #006600; font-weight: bold;">=</span> Sayfa
<span style="color: #000000; font-weight: bold;">%&gt;</span> <span style="color: #006600; font-weight: bold;">&lt;</span>table border<span style="color: #cc0000;">&quot;1&quot;</span> bordercolor<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;#C0C0C0&quot;</span> style<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;border-collapse:collapse; font:normal normal normal 11px verdana;&quot;</span> width<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;500&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>td width<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;5&quot;</span> bgcolor<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;#FFFBDF&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span>b<span style="color: #006600; font-weight: bold;">&gt;</span>S<span style="color: #006600; font-weight: bold;">&lt;/</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;&lt;&gt;</span>   <span style="color: #006600; font-weight: bold;">&lt;</span>td width<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;245&quot;</span> bgcolor<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;#FFFBDF&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span>b<span style="color: #006600; font-weight: bold;">&gt;</span>Site Adı<span style="color: #006600; font-weight: bold;">&lt;/</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>td width<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;250&quot;</span> bgcolor<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;#FFFBDF&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span>b<span style="color: #006600; font-weight: bold;">&gt;</span>URL
<span style="color: #006600; font-weight: bold;">&lt;/</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
i<span style="color: #006600; font-weight: bold;">=</span><span style="color: #800000;">0</span>
<span style="color: #008000;">'Kayıtsetimizi bir sayfada gösterilecek kayıt sayısı adedince döndürelim.</span>
&nbsp;
<span style="color: #990099; font-weight: bold;">Do</span> <span style="color: #990099; font-weight: bold;">While</span> <span style="color: #990099; font-weight: bold;">Not</span> Rs.<span style="color: #0000ff; font-weight: bold;">EOF</span> <span style="color: #0000ff; font-weight: bold;">And</span> i<span style="color: #006600; font-weight: bold;">&lt;</span>Rs.<span style="color: #9900cc;">PageSize</span> <span style="color: #000000; font-weight: bold;">%&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>td align<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;center&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span> <span style="color: #006600; font-weight: bold;">%=</span>i+<span style="color: #800000;">1</span><span style="color: #000000; font-weight: bold;">%&gt;</span><span style="color: #006600; font-weight: bold;">&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>   <span style="color: #006600; font-weight: bold;">&lt;</span>td<span style="color: #006600; font-weight: bold;">&gt;&lt;</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;</span> <span style="color: #006600; font-weight: bold;">%=</span>Rs<span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;fldSiteAdi&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span><span style="color: #000000; font-weight: bold;">%&gt;</span><span style="color: #006600; font-weight: bold;">&lt;/</span>b<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>td<span style="color: #006600; font-weight: bold;">&gt;&lt;</span>a href<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;&lt;%=Rs(&quot;</span>fldURL<span style="color: #cc0000;">&quot;)%&gt;&quot;</span> style<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;color:#0000FF&quot;</span> target<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;_blank&quot;</span><span style="color: #006600; font-weight: bold;">&gt;&lt;</span> <span style="color: #006600; font-weight: bold;">%=</span>Rs<span style="color: #006600; font-weight:bold;">&#40;</span><span style="color: #cc0000;">&quot;fldURL&quot;</span><span style="color: #006600; font-weight:bold;">&#41;</span><span style="color: #000000; font-weight: bold;">%&gt;</span><span style="color: #006600; font-weight: bold;">&lt;/</span>a<span style="color: #006600; font-weight: bold;">&gt;&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
i<span style="color: #006600; font-weight: bold;">=</span>i+<span style="color: #800000;">1</span>
Rs.<span style="color: #330066;">MoveNext</span>
<span style="color: #990099; font-weight: bold;">Loop</span> <span style="color: #000000; font-weight: bold;">%&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span>td colspan<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;3&quot;</span> align<span style="color: #006600; font-weight: bold;">=</span><span style="color: #cc0000;">&quot;right&quot;</span><span style="color: #006600; font-weight: bold;">&gt;</span> <span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
<span style="color: #008000;">' ve son olarak ta sayfaların linklerini sayfamıza bastıralım.</span>
<span style="color: #990099; font-weight: bold;">If</span> Rs.<span style="color: #9900cc;">PageCount</span> <span style="color: #006600; font-weight: bold;">&gt;</span> <span style="color: #800000;">0</span> <span style="color: #990099; font-weight: bold;">Then</span>
<span style="color: #990099; font-weight: bold;">For</span> s<span style="color: #006600; font-weight: bold;">=</span><span style="color: #800000;">1</span> <span style="color: #990099; font-weight: bold;">To</span> Rs.<span style="color: #9900cc;">PageCount</span>
<span style="color: #990099; font-weight: bold;">Response</span>.<span style="color: #330066;">Write</span> <span style="color: #cc0000;">&quot;&lt;a href=&quot;</span><span style="color: #cc0000;">&quot;?s=&quot;</span> <span style="color: #006600; font-weight: bold;">&amp;</span> s <span style="color: #006600; font-weight: bold;">&amp;</span> <span style="color: #cc0000;">&quot;&quot;</span><span style="color: #cc0000;">&quot;&gt;&quot;</span> <span style="color: #006600; font-weight: bold;">&amp;</span> s <span style="color: #006600; font-weight: bold;">&amp;</span> <span style="color: #cc0000;">&quot;&lt;/a&gt; &quot;</span>
<span style="color: #990099; font-weight: bold;">Next</span>
<span style="color: #990099; font-weight: bold;">End</span> <span style="color: #990099; font-weight: bold;">If</span>
<span style="color: #000000; font-weight: bold;">%&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>td<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>tr<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;/</span>table<span style="color: #006600; font-weight: bold;">&gt;</span>
<span style="color: #006600; font-weight: bold;">&lt;</span> <span style="color: #006600; font-weight: bold;">%</span>
<span style="color: #008000;">' Bitti, hayırlı olsun...</span>
<span style="color: #990099; font-weight: bold;">End</span> <span style="color: #990099; font-weight: bold;">If</span>
<span style="color: #000000; font-weight: bold;">%&gt;</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://tuncay.kinali.net/asp-ile-ms-access-verilerini-sayfalama.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
