opening a file

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • nivaz
    New Member
    • Feb 2008
    • 17

    opening a file

    i want to open a file that should be done with the help of common dialog box. so plz help as soon as possible ya.
    acording to my project the the text file should selected form the common dialog box from form1 and should display in form3(rich textbox) hope u guys understand
  • Ali Rizwan
    Banned
    Contributor
    • Aug 2007
    • 931

    #2
    Just add Microsoft Common Dialoge control in your project and write this control in a Button's click event.

    Code:
     CommonDialog1.Open
    open dialog box will show.

    For an example of this you can tell me.

    Regards
    >> ALI <<

    Comment

    • Bum
      New Member
      • Jan 2008
      • 19

      #3
      Yes,

      commondialog1.o pen

      but make sure you add a commondialog reference to your toolbox first.

      Comment

      • Killer42
        Recognized Expert Expert
        • Oct 2006
        • 8429

        #4
        I think it would help if we knew what version of VB we're talking about here.

        Comment

        • nivaz
          New Member
          • Feb 2008
          • 17

          #5
          Originally posted by Killer42
          I think it would help if we knew what version of VB we're talking about here.


          this s VB6.0 guys plz help those are not working

          Comment

          • debasisdas
            Recognized Expert Expert
            • Dec 2006
            • 8119

            #6
            try using this
            [code=vb]
            CommonDialog1.S howOpen
            If CommonDialog1.F ileName <> "" Then
            RichTextBox1.Lo adFile CommonDialog1.F ileName
            End If
            [/code]

            Comment

            • VACEPROGRAMER
              Banned
              New Member
              • Nov 2007
              • 167

              #7
              Yes! Insert the MicrosoftCommon Dialog 6.0 and put into the For. Tipe this code


              CommonDialalog1 .Filter = . . .. ' the file type you want to open
              CommonDialog1.S How open

              And other memebers have told you the reset of the code . . .

              VxE

              Comment

              Working...