哪位朋友能帮我详细说明,并最好赋上例子。顺便问下,VB当中有没有一个函数,它能把一个字符串插入到另外一个字符串当中的任何位置。

解决方案 »

  1.   


    Function Insert(ByVal Source As String, ByVal SubStr As String, ByVal iBegin As Long) As String  If Len(Source) < 1 Then Insert = SubStr: Exit Function
      If iBegin > Len(Source) Then iBegin = Len(Source) + 1
      If iBegin < 1 Then iBegin = 1  Insert = Left(Source, iBegin - 1) & SubStr & Right(Source, Len(Source) - iBegin + 1)
    End Function  
      

  2.   

    你用shell就可以调用了
    shell "c:\b.com"
      

  3.   

    在vb中可以直接运行其他程序,但是要调用其他程序就比较难,主要看这个其他程序是否支持被调用。比如Word,Excel等都提供了调用的接口。