数字后端cellpadding(数字后端培训)

http://www.itjxue.com  2023-01-26 20:29  来源:未知  点击次数: 

高分问2个问题,答出一个就送

1:VBScript脚本语言的IF...THEN...或者Select...CASE语句编写一个页面

根据分数变量Grade值输出不同的等级(Grade=90 :优秀 Grade=80:良好Grade=70 中等 Grade=60 合格 Grade〈60 不及格 ,Grade 初值自定

答案:

select case grade

case =90

msgbox("成绩为优秀")

case =80

msgbox("成绩为优良")

case =70

msgbox("成绩为中等")

case=60

msgbox("成绩为合格")

case60

msgbox("成绩为不合格")

end case

2:现有一ACEESS数据库student.mdb有一名为“学生表”的数据表,试用ODBC驱动或者OLEDB连接字符串访问数据库方式编程实现在表格输出“学生表”的全部纪录内容

Dim blnok As Boolean = False

Dim myconn As New OleDbConnection

Dim mycomm As New OleDbCommand

Dim myadpt As New OleDbDataAdapter

Dim myds As New DataSet

dim dtg as new datagrid

myconn.ConnectionString= "provider=microsoft.jet.oledb.4.0;data source=" Application.StartupPath "\student.mdb"

myconn.Open()

mycomm.CommandText = "select * from 学生表 "

mycomm.Connection = myconn

myadpt.SelectCommand = mycomm

myadpt.Fill(myds)

dtg.datasource=myds.tables(0)

asp代码问题 在线求救

按照你的代码修改的,你写的太复杂了,很乱

%

'首页和上页分页代码

if Page1 then

response.write "a href=introduction.asp?page=1img src=/faq/photo/ico_5.gif border=0 //a "

response.write "a href=introduction.asp?page=" Page-1 "img src=/faq/photo/ico_2.gif border=0 //a "

else

response.write "img src=/faq/photo/ico_5.gif border=0 / img src=/faq/photo/ico_2.gif border=0 / "

end if

'数字分页代码

c1=page-5 '显示当前页的前5页,可以根据自己需要修改

c2=page+5 '显示当前页的后5页,可以根据自己需要修改

cc1=page-1

cc2=page+1

if c11 then c1=1

if c2rs.PageCount then c2=rs.PageCount

for i=c1 to cc1

Response.Write"a href=introduction.asp?page="i"["i"]/a "

next

Response.Write"font color=red ["page"] /font"

for j=cc2 to c2

Response.Write" a href=introduction.asp?page="j"["j"]/a"

next

'数字分页结束

'下页和尾页分页代码

if pagers.pagecount then

response.write "a href=introduction.asp?page=" (page+1) ""

response.write "img src=/faq/photo/ico_3.gif border=0 //a a href=introduction.asp?page="rs.pagecount"img src=/faq/photo/ico_4.gif border=0 //a"

else

response.write "img src=/faq/photo/ico_3.gif border=0 / img src=/faq/photo/ico_4.gif /"

end if

%

翻译一下代码

TABLE

cellSpacing=0 单元格间距

cellPadding=0 单元格边距

width=710 表格宽度

align=center 居中对齐

border=0 表格边框宽度

(责任编辑:IT教学网)

更多

推荐网站策划文章