如何用vb编程设置msflexgrid控键的字段内容显示的是text1中的 内容

2025-04-28 09:56:08
推荐回答(2个)
回答1:

Private Sub MSFlexGrid1_Click()
text1.move msflexgrid1.cellleft+msflexgrid1.left,msflexgrid1.celltop+msflexgrid1.top,msflexgrid1.cellwidth,msflexgrid1.cellheight
text1=""
if trim(msflexgrid1.text)<>"" then
text1=msflexgrid1.text
text1.selstart=0
text1.sellength=len(text1)
end if
text1.setfocus
End Sub

回答2:

with myflexgrid
.TextMatrix(.row,.col) = text1.text
end with