用打开对话框查找的那种,谢谢大虾们了

解决方案 »

  1.   

    public sub subOpenPicture(byref objPic as picture)    
        Dim strP As String
    On Error GoTo errSub
      
        With cdlPic
            .DialogTitle = "选择图片"
            .Filter = "(BMP文件)|*.bmp|(JPEG文件)|*.jpg"
            .InitDir = App.Path
            .ShowOpen
            strP = .FileName
            .FileName = ""
        End With
        If strP = "" Then Exit Sub
        objPic.picture=loadpictrue(strP)
    errSub:end funciton
      

  2.   

    把最后一句:end funciton改为:end Sub