留言簿

我要留言
留言搜索

2008-06-18 11:21  lvjin

如果用UrlPaging属性的话<br>默认获取的是FilePath,我改成RawUrl<br>也不行,翻页之后无法显示正确的纪录<br>或者您提供一下修改的思路<br>我自己改成使用UrlPaging属性,获取请求的原始URL,而不是当前的虚拟路径<br>目前看来使用UrlRewritePattern应该不合适,因为他必须指定重写的URL<br>而我的URL恰恰是不固定的
回复:对不起,我没看懂您的意思,“如果用UrlPaging属性的话 默认获取的是FilePath”怎么理解?,另外您所谓的“原始URL”和“当前的虚拟路径”指的是什么?您需要实现什么样的功能?

2008-06-18 10:46  lvjin

您好 ,我又来了。。<br>看过您的回复了,看来似乎您没搞清楚我的情况,我的意思是:<br>比如index.aspx?userid=1和index.aspx?userid=2,都是访问到了index.asp<br>但是userid的值不是固定的,而我想在index.aspx中做分页,UrlRewritePattern应该怎么写?因为我没法把userid在UrlRewritePattern固定成一个值,我应该怎么做?<br>再次感谢您抽空做的回复,希望能再次帮忙解决一下。。
回复:您好,在UrlRewritePattern属性中,用%userid%这个替换符来代替userid这个参数的值就行了,也就是UrlRewritePattern属性中的%userid%在运行时就是url中userid这个参数的值。谢谢!

2008-06-18 01:37  cuiyanxin

还要问一下,正确的版本下载下来,怎么用,有没有一个教程? 还请指点
回复:您好,下载页面有详细的示例项目可以下载,不过没有教程,因为控件比较简单,常见的问题可以在常见问题页面找到。另外您可以用搜索引擎搜一下,网上有一些网友写过相关的教程和使用方法等。谢谢!

2008-06-18 01:29  cuiyanxin

你好,我用的是vs2005 想用的你的分页,但不知道下哪个版本,看看了只有一个版本呢?谢谢指点.
回复:您好,最新的7.0.2版就可以。谢谢!

2008-06-17 14:53  yufan916

有个问题想请教一下.这是我的存储过程<br>create procedure WorkKindList <br>(@InfoName NVarChar(50),<br>@kind NVarChar(50),<br>@pagesize int,<br>@pageindex int<br>)<br>as<br>set nocount on<br><br><br>begin<br>declare @indextable table(id int identity(1,1),nid int)<br>declare @PageLowerBound int<br>declare @PageUpperBound int<br>set @PageLowerBound=(@pageindex-1)*@pagesize<br>set @PageUpperBound=@PageLowerBound+@pagesize<br>set rowcount @PageUpperBound<br>insert into @indextable(nid) select InfoID from InformationManage  where infoname like '%'+@infoname+'%' and infotype = @kind and ishide = '0' order by InfoID desc<br>select * from InformationManage O,@indextable t where O.InfoID=t.nid<br>and t.id between @PageLowerBound+1 and @PageUpperBound order by t.id<br>end<br>set nocount off<br><br>为什么在显示的时候,还是显示了全部的页码
回复:存储过程看不出有什么问题,您说的“显示了全部的页码”是什么意思呢?

2008-06-16 19:57  acheng

我刚才发现这个控件还有这个属性:<br>ShowPageIndex,我真是太愚蠢了,唉,打搅了,快闪吧。
回复:没关系,常来看看。

2008-06-16 19:44  acheng

我能不能只保留这些功能:<br>&quot;上一页&quot;,&quot;下一页&quot;<br>这些就足够了.<br>可以吗?吴老师?
回复:可以的,都有相关属性,将ShowPageIndex设为false就可以隐藏数字页码,将ShowFirstLast设为false就可以隐藏首页和尾页按钮。谢谢!

2008-06-16 16:55  lhchengru

你好老师 总是提示未知的服务器标记 代码如下:&lt;%<br>&lt;%@ Control Language=&quot;C#&quot; AutoEventWireup=&quot;true&quot; CodeFile=&quot;GuestBookList.ascx.cs&quot; Inherits=&quot;CnEnControl_GuestBookList&quot; %&gt;<br>&lt;%@ Register Assembly=&quot;AspNetPager&quot; Namespace=&quot;Wuqi.Webdiyer&quot; TagPrefix=&quot;webdiyer&quot; %&gt;<br><br> &lt;asp:Repeater ID=&quot;list&quot; runat=&quot;server&quot;&gt;<br> 。。。。。。<br>  &lt;/asp:Repeater&gt; <br>&lt;asp:Label ID=&quot;emptyText&quot; runat=&quot;server&quot;&gt;&lt;/asp:Label&gt;<br>&lt;div class=&quot;page_right&quot;&gt;<br>&lt;webdiyer:aspnetpager id=&quot;AspNetPager&quot; runat=&quot;server&quot; <br>  AlwaysShow=&quot;True&quot; ShowNavigationToolTip=&quot;True&quot; CenterCurrentPageButton=&quot;true&quot; <br>  SubmitButtonText=&quot;Go&quot; UrlPageIndexName=&quot;Abpage&quot;<br>UrlPaging=&quot;True&quot; CustomInfoSectionWidth=&quot; &quot; <br>Direction=&quot;LeftToRight&quot;<br>ShowCustomInfoSection=&quot;Left&quot; TextAfterPageIndexBox=&quot;&amp;nbsp;&quot; FirstPageText=&quot;&lt;&lt;&quot; LastPageText=&quot;&gt;&gt;&quot; NextPageText=&quot;&gt;&quot; PrevPageText=&quot;&lt;&quot; CurrentPageButtonClass=&quot;&quot; CurrentPageButtonStyle=&quot;&quot; CustomInfoClass=&quot;page_info&quot; ShowPageIndexBox=&quot;Always&quot; PagingButtonSpacing=&quot;4px&quot; <br>CustomInfoHTML=&quot;共&lt;font color=red&gt;%RecordCount%&lt;/font&gt;条记录 &lt;font color=red&gt;%CurrentPageIndex% / %PageCount%&lt;/font&gt;&quot; CssClass=&quot;links&quot; PageSize=&quot;15&quot; <br>&gt;<br> &lt;/webdiyer:aspnetpager&gt;<br>  &lt;/div&gt;
回复:您的bin目录下存在AspNetpager.dll文件吗?出错时详细信息显示的是哪一行代码出错了?试试把webdiyer:aspnetpager改为webdiyer:AspNetPager。谢谢!

2008-06-16 16:52  lhchengru

你好老师 总是提示未知的服务器标记 代码如下:&lt;%@ Control Language=&quot;C#&quot; AutoEventWireup=&quot;true&quot; CodeFile=&quot;GuestBookList.ascx.cs&quot; Inherits=&quot;CnEnControl_GuestBookList&quot; %&gt;<br>&lt;%@ Register Assembly=&quot;AspNetPager&quot; Namespace=&quot;Wuqi.Webdiyer&quot; TagPrefix=&quot;webdiyer&quot; %&gt;<br><br> &lt;asp:Repeater ID=&quot;list&quot; runat=&quot;server&quot;&gt;<br>                    &lt;ItemTemplate&gt;<br>                        &lt;div style=&quot;height:8px; overflow:hidden; background-color:#FFFFFF;&quot;&gt;&lt;/div&gt;<br>                        &lt;table cellpadding=&quot;0&quot; cellspacing=&quot;1&quot; border=&quot;0&quot; class=&quot;tk&quot;&gt;<br>                            &lt;tr&gt;<br>                                &lt;td class=&quot;g_title&quot;&gt; &lt;span class=&quot;bold&quot;&gt;&lt;%# Eval(&quot;title&quot;)%&gt;&lt;/span&gt;&lt;/td&gt;<br>                                &lt;td class=&quot;g_time&quot;&gt;&lt;%# Eval(&quot;intime&quot;)%&gt;&lt;/td&gt;<br>                            &lt;/tr&gt;<br>                            &lt;tr&gt;<br>                                &lt;td class=&quot;g_body&quot; colspan=&quot;2&quot;&gt;<br>                                    &lt;table cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; border=&quot;0&quot;&gt;<br>                                        &lt;tr&gt;<br>                                            &lt;td class=&quot;g_left&quot;&gt;<br>                                                &lt;div&gt;<br>                                                    &lt;asp:Image ID=&quot;imgFace&quot; ImageUrl='&lt;%# Eval(&quot;face&quot;)%&gt;' runat=&quot;server&quot; /&gt;<br>                                               &lt;/div&gt;<br>                                                &lt;div&gt;&lt;%# Eval(&quot;name&quot;)%&gt;&lt;/div&gt;<br>                                            &lt;/td&gt;<br>                                            &lt;td class=&quot;g_content&

2008-06-14 21:56  wyq29

我觉得这个控件在功能上已经很强了。但是大家开始要美观了。个人建议:改用table布局  增加数字页码单独样式名称,取消部分繁琐的样式属性 比如字体都不要了,在cssclass里自己去定义。 这样table、自定义区、数字页面导航、页码框、按钮都用独立样式class  尽量自己去定义。<br>可能作者没有想到 数字导航 会有更多属性需要自己定义 而不是光字体。
回复:谢谢您的建议,控件以前版本使用的就是table布局,应部分网友的要求后来改为div,引起现在的文本和按钮及文本框水平无法对齐的问题,下次升级我会再加上table布局,数字页码样式也可以考虑加上,谢谢!
;