马上注册,结交更多好友,享用更多功能,让你轻松玩转闽南师范大学。
您需要 登录 才可以下载或查看,没有账号?立即加入
×
< > 在ACCESS中,VAB编写这段代码,怎么会出现这种错误呢?!</P>5 Y) V$ R; e6 c7 w- `2 K5 \
< >谁帮我瞧瞧。先谢了·····</P>5 U: f% K" w A6 `* O
< > rivate Sub List2_Click()
& X$ m. b& P# h9 O3 u. b3 T7 A Dim str As String. E0 \5 J2 [6 U8 B1 A) E
Dim con As ADODB.Connection '声名数据库对象0 D' x8 c2 V' z! p3 X
Dim rscA As ADODB.Recordset '声名记录集对象
0 U$ `) a+ C1 v$ s) r. e ' Set con = New ADODB.Connection '数据库对象实例化例 dim con as new adodb.connection
6 G0 M0 c. p4 I Set con = CurrentProject.Connection '指定当前数据库为打开数据库
" f) N# g5 t! K5 @" { Set rscA = New ADODB.Recordset '记录集对象实例化 dim rec as new recordset
+ j" X$ e# s! W% i" X9 W7 P S6 j t N! w4 H* w4 z8 ]7 E1 i) [3 i7 u
str = "SELECT * FROM 专业 where 专业名称='" & List2.<I>value</I> & "'"
% q4 g8 W3 Z, [1 Q6 g. h rscA.Open str, con, 1, 3
% u, n3 j; ~+ n# @! R8 y1 x% R% u Text4.SetFocus7 {% Z3 q# h0 m8 Q: \/ S Z# @; i& m
Text4.Text = rscA("专业代号")
0 j5 U0 B1 Z+ z# ?$ q rscA.Close5 \0 }% |; v) q5 U+ }5 r
Set rscA = Nothing
! ?4 Z. v3 n8 iEnd Sub</P>" w" _9 Z8 l- Z/ ~' O/ a/ x
< >错误提示</P><img src="attachments/dvbbs/2004-5/200451712445786.bmp" border="0" onload="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=\'Click here to open new window\nCTRL+Mouse wheel to zoom in/out\';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor=\'hand\'; this.alt=\'Click here to open new window\nCTRL+Mouse wheel to zoom in/out\';}" onclick="if(!this.resized) {return true;} else {window.open(\'attachments/dvbbs/2004-5/200451712445786.bmp\');}" onmousewheel="return imgzoom(this);" alt="" /> |