public void ShowFirst( object s, EventArgs e) {
intCurrIndex.Text = "0";
DataBind();
}
public void ShowPrevious( object s, EventArgs e) {
intCurrIndex.Text = Cstr(Cint(intCurrIndex.Text) - CInt(intPageSize.Text));
if ( CInt(intCurrIndex.Text) < 0 ) {
intCurrIndex.Text = "0";
}
DataBind();
} public void ShowNext( object s, EventArgs e) {
if ( CInt(intCurrIndex.Text) + 1 < CInt(intRecordCount.Text) ) {
intCurrIndex.Text = CStr(CInt(intCurrIndex.Text) + CInt(intPageSize.Text));
}
DataBind();
} public void ShowLast( object s, EventArgs e) {
tmpInt as int; tmpInt = CInt(intRecordCount.Text) % CInt(intPageSize.Text);
if ( tmpInt > 0 ) {
intCurrIndex.Text = Cstr(CInt(intRecordCount.Text) - tmpInt);
} else {
intCurrIndex.Text = Cstr(CInt(intRecordCount.Text) - CInt(intPageSize.Text));
}
DataBind();
}没仔细看 直接手写的 自己调一下哈 :-)
intCurrIndex.Text = "0";
DataBind();
}
public void ShowPrevious( object s, EventArgs e) {
intCurrIndex.Text = Cstr(Cint(intCurrIndex.Text) - CInt(intPageSize.Text));
if ( CInt(intCurrIndex.Text) < 0 ) {
intCurrIndex.Text = "0";
}
DataBind();
} public void ShowNext( object s, EventArgs e) {
if ( CInt(intCurrIndex.Text) + 1 < CInt(intRecordCount.Text) ) {
intCurrIndex.Text = CStr(CInt(intCurrIndex.Text) + CInt(intPageSize.Text));
}
DataBind();
} public void ShowLast( object s, EventArgs e) {
tmpInt as int; tmpInt = CInt(intRecordCount.Text) % CInt(intPageSize.Text);
if ( tmpInt > 0 ) {
intCurrIndex.Text = Cstr(CInt(intRecordCount.Text) - tmpInt);
} else {
intCurrIndex.Text = Cstr(CInt(intRecordCount.Text) - CInt(intPageSize.Text));
}
DataBind();
}没仔细看 直接手写的 自己调一下哈 :-)
这些地方该成
public void ShowNext(object sender,EventArgs e)
{}if then
else
end if
改成
if()
{}
else
{}CInt(intCurrIndex.Text)之类的改成(int)(intCurrIndex.Text)所有的语句后面都加;
我是在这里来转化的