各位大侠:
      我想用asp把服务器端的一个程序下载到本地运行,这个程序是用vb写的,我想把asp中用到的用户登陆的信息传递到vb这个程序里面,想了好长时间没有结果,哪位大侠帮帮忙?

解决方案 »

  1.   

    利用程序参数,比如
    xxx.exe arg1 arg2
      

  2.   

    在vb中用command语句接受命令行参数
      

  3.   


    可以用COMMAND参数..MSDN中的例子.Function GetCommandLine(Optional MaxArgs)
       '声明变量。
       Dim C, CmdLine, CmdLnLen, InArg, I, NumArgs
       '检查是否提供了 MaxArgs 参数。
       If IsMissing(MaxArgs) Then MaxArgs = 10
       ' 使数组的大小合适。
       ReDim ArgArray(MaxArgs)
       NumArgs = 0: InArg = False
       '取得命令行参数。
       CmdLine = Command()
       CmdLnLen = Len(CmdLine)
       '以一次一个字符的方式取出命令行参数。
       For I = 1 To CmdLnLen
          C = Mid(CmdLine, I, 1)
          '检测是否为 space 或 tab。
          If (C <> " " And C <> vbTab) Then
             '若既不是 space 键,也不是 tab 键,
             '则检测是否为参数内含之字符。
             If Not InArg Then
             '新的参数。
             '检测参数是否过多。
                If NumArgs = MaxArgs Then Exit For
                   NumArgs = NumArgs + 1
    InArg = True
                End If
             '将字符连接到当前参数中。
             ArgArray(NumArgs) = ArgArray(NumArgs) & C
          Else
             '找到 space 或 tab。
             '将 InArg 标志设置成 False。
             InArg = False
          End If
       Next I
       '调整数组大小使其刚好符合参数个数。
       ReDim Preserve ArgArray(NumArgs)
       '将数组返回。
       GetCommandLine = ArgArray()
    End Function