雅安人才网

求大神帮忙,VB解析

    发布时间:2018-07-27 10:34

    Private Sub Form_Click()
    Dim i%, s% 'i 循环变量,s 保存累加和
    for i=1 to 100
    if i mod 7=0 then s=s+i
    next
    print s
    wwjt s
    End Sub

    Private Sub wwjt(i As Integer)
    Dim OUT As Integer
    OUT = FreeFile
    Open App.Path & "\1.out" For Output As #OUT
    Print #OUT, i
    Close #OUT
    End Sub

    回复:

    多看书,多上机练习

    回复:

    Private Sub Form_Click() Dim i%, s% 'i 循环变量,s 保存累加和 for i=1 to 100 if i mod 7=0 then s=s+i next print s wwjt s End Sub Private Sub wwjt(i As Integer) Dim OUT As Integer OUT = FreeFile Open App.Path & "\1.out" For Outp...

    回复:

    代码: Dim t As SinglePrivate Sub Command1_Click() Dim d() As String t = t + Val(Text2.Text) d() = Split(Text1.Text, "-") Label3.Caption = Label3.Caption + "20" + d(0) + "年" + d(1) + "月" + d(2) + "日" + vbCrLf Label4.Caption ...

    回复:

    C CW 8 k=1,t=t & Chr(Asc(Mid(s, m, 1)) + k) ="" & Chr(Asc("B") + 1) =Chr(66 + 1) ="C" k=k+1=2 Mid(s,k,1)="A" m=m+k=3 Print t结果:C k=4,t=t & Chr(Asc(Mid(s, m, 1)) + k) ="C" & Chr(Asc("S") + 4) ="C" & Chr(83 + 4) ="CW" k=k+1=5 M...

    回复:

    x=InputBox(请输入)'弹窗,[inputBox]为输入框 For i=1 To x-1 '进行循环[For...Next],从i=1开始到i=x-1结束,间隔省缺为1 if x mod i = 0 then '条件语句[If...End if],假如X能被i整除,则进行If到End if 之间的语句 print i '打印i的值 n=n+...

    回复:

    Private Sub btnHide_Click() Label1.Visible = Flase btnShow.Enabled = True btnHide.Enabled = Flase Form1.Caption = "单击“显示”按钮显示文字" End Sub Private Sub btnShow_Click() Label1.Visible = True btnShow.Enabled = False btnHi...

    回复:

    Private Sub Form_Click()Dim max, min, aver As Integer a = Array(15, 23, 72, 43, 96, 23, 3, 65, 88, 17) max = a(0): min = a(0): Sum = a(0) For i = 1 To 9 If a(i) > max Then max = a(i) If a(i) < min Then min = a(i) Sum = Sum + a(...

    回复:

    8、输入一个数X,如果X>=0,则Y=1-2*X,否则的话Y=1+X 9、循环,直到i大于7,每次循环i增加3,X增加5 10、RND函数是返回一个0—1之间的随机数,所以取整后X为4(只取整数部分),输出结果必为GOOD 11、循环,每一次循环X=(X+3)*(X+4),N为循环次...

    回复:

    很简单 你加一个判断 wscript.scriptfullname 这是自身文件路径 你只要和 PT这个变量里来对比下 是否在文件夹中

    回复:

    '第一行是:X=4 第二行是:26 第三行是:15 15Private Sub Command1_Click() Dim X As Integer, Y As Integer, S As Integer X = 12: Y = 18 If X > Y Then S = Fun(X, Y, 1) Else S = Fun(Y, X, 1) End If Print S '打印S值为:26 Print X, Y '打印...

      上一篇:什么部门管物流行业 下一篇:手机壁纸啊啊啊啊

      返回主页:雅安人才网

      本文网址:http://0835job.cn/view-207664-1.html
        信息删除