您现在的位置: 中国悠悠网 >> 文档中心 >> 论文中心 >> 计算机类 >> 文章正文
学生档案管理系统 教育论文 | 免费论文
 
seltext = "" ''清选择的文本
end sub

private sub edit_click()
''当程序显示“编辑”子菜单前,触发该程序
if text1.sellength > 0 then
''文本框中有选中的文本
cut.enabled = true
copy.enabled = true
delete.enabled = true
else
cut.enabled = false
copy.enabled = false
delete.enabled = false
end if

if len(clipboard.gettext()) > 0 then
''剪裁板中有文本数据
paste.enabled = true
else
''没有可粘贴的文本
paste.enabled = false
end if
end sub

private sub exit_click()
unload me
end sub

private sub findtext_keypress(keyascii as integer)
dim beginpos as long

if keyascii = 13 then
beginpos = instr(1, text1.text, findtext.text, vbtextcompare)
if beginpos > 0 then
text1.selstart = beginpos - 1
text1.sellength = len(findtext.text)
end if
end if
end sub

private sub fontcolor_click()
commondialog1.showcolor
text1.forecolor = commondialog1.color
end sub

private sub form_load()
dim i as integer

''加载图像
imgnew.picture = imageup.listimages("new").picture
imgopen.picture = imageup.listimages("open").picture
imgsave.picture = imageup.listimages("save").picture
imgundo.picture = imagedisable.listimages("undo").picture
check_imgpaste
check_imgcutcopy

''加载系统字体
for i = 0 to screen.fontcount - 1
combofont.additem screen.fonts(i)
next i
end sub

private sub form_resize()
dim texttop as long

''修改工具条大小
coolbar1.top = me.scaletop
?????????????????????????????
??????????????????????????????????
???????????
????????????????????????????
??????????
????????????????????????????????????????????
????????
???????????????????
??????????
?????????????????????????????????????
???????????????? me.scaleleft
text1.width = me.scalewidth
if me.scaleheight > coolbar1.height then
text1.height = me.scaleheight - texttop
else
text1.height = 0
end if
end sub

private sub imgcopy_click()
copy_click ''复制
check_imgpaste
check_imgcutcopy
end sub

private sub imgcopy_mousedown(button as integer, shift as integer, x as single, y as single)
''“按下”按钮
if button = 1 then
imgcopy.picture = imagedown.listimages("copy").picture
end if
end sub

private sub imgcopy_mousemove(button as integer, shift as integer, x as single, y as single)
label1 = "将选择的文本复制到剪裁板"

上一页  [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] 下一页