Results 1 to 2 of 2

Thread: Save File error

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Apr 2007
    Location
    Unspecifed
    Posts
    9

    Question Save File error

    im using vb6.0 for mmore info,
    ve got a problem in app, when you go to save a file, you have the option of the standerd SPR fomat which is the defualt for my app or you can have as an txt, doc or all files, but when i just put txt how i think it might be, it allows it, but then when i go into my docs (cos i have some notepad docs) i doesnt show them,
    heres the code ive got, tell me what i need to do for the txt format to be added:
    vb Code:
    1. Private Sub mnuFileSaveAs_Click()
    2.     Dim sFile As String
    3.    
    4.  
    5.     If ActiveForm Is Nothing Then Exit Sub
    6.    
    7.  
    8.     With dlgCommonDialog
    9.         .DialogTitle = "Save As"
    10.         .CancelError = False
    11.         'ToDo: set the flags and attributes of the common dialog control
    12.         .Filter = "SP Runtime Docs (*.spr)|*.spr"
    13.         .ShowSave
    14.         If Len(.FileName) = 0 Then
    15.             Exit Sub
    16.         End If
    17.         sFile = .FileName
    18.     End With
    19.     ActiveForm.Caption = sFile
    20.     ActiveForm.rtfText.SaveFile sFile
    21.  
    22. End Sub
    Last edited by si_the_geek; Apr 8th, 2007 at 12:34 PM. Reason: corrected VBCode tags

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width