Printing directory- and file lists | Bulk attachment saving

LandyMan

Honorary Master
Joined
Feb 28, 2005
Messages
13,358
Reaction score
3,185
Location
Centurion
Hi all,

I (ok, my wife) want to print a directory (folder for the younger folk) and all its subdirectories (subfolders). Now the piping of a dir command to a text file works like a charm -
Code:
dir /A:D /S /B > dirlist.txt
but I am looking for a program/utility to install so my wife can do it directly either from Windows Explorer or from the installed program.

I have found quite a few while googling, but is there a specific one you guys can recommend?

EDIT: And while we're at it, is it possible to select a bunch of e-mails in MS Outlook, and save all the attachments at once? If not, is there anything available to do it?

EDIT 2: For my first question, you can do this: http://support.microsoft.com/?kbid=321379

Thanks
 
Last edited:
Looks like the longer we leave you searching google with no reply your going to fix all the problems... well good luck, because thats all we would have done.
 
Person said:
Looks like the longer we leave you searching google with no reply your going to fix all the problems... well good luck, because thats all we would have done.
HAHAHA ... I was thinking that while typing the second Edit ... and it works like a charm by the way. Just make sure to make the registry changes as well ...

/me starting another search on Google :p

EDIT 3: HAHAHA. Ok, so I found a Macro to save multiple attachments from multiple e-mails. Only problem is that it 'strips' the attachments from the e-mails ... biiiaaatttccchh! Anyone know VB macros that might be able to modify it to leave the attachment in the e-mail?

EDIT 4: Never mind ... fixed it myself (so the money spent on Varsity did help in the end).

Here is the Macro if anyone is interested:
Code:
Sub SaveAttachments()

    'Declaration
    Dim myItems, myItem, myAttachments, myAttachment As Object
    Dim myOrt As String
    Dim myOlApp As New Outlook.Application
    Dim myOlExp As Outlook.Explorer
    Dim myOlSel As Outlook.Selection
    
    'Ask for destination folder
    myOrt = InputBox("Destination", "Save Attachments", "C:\")

    On Error Resume Next
    
    'work on selected items
    Set myOlExp = myOlApp.ActiveExplorer
    Set myOlSel = myOlExp.Selection
    
    'for all items do...
    For Each myItem In myOlSel
    
        'point on attachments
        Set myAttachments = myItem.Attachments
        
        'if there are some...
        If myAttachments.Count > 0 Then
        
            'add remark to message text
            myItem.Body = myItem.Body & vbCrLf & _
                "Removed Attachments:" & vbCrLf
                
            'for all attachments do...
            For i = 1 To myAttachments.Count
            
                'save them to destination
                myAttachments(i).SaveAsFile myOrt & _
                    myAttachments(i).DisplayName

                'add name and destination to message text
                myItem.Body = myItem.Body & _
                    "File: " & myOrt & _
                    myAttachments(i).DisplayName & vbCrLf
                    
            Next i
            
            'for all attachments do...
            ''While myAttachments.Count > 0
            
                'remove it (use this method in Outlook XP)
                'myAttachments.Remove 1
                
                'remove it (use this method in Outlook 2000)
                ''myAttachments(1).Delete
                
            ''Wend
            
            'save item without attachments
            ''myItem.Save
        End If
        
    Next
    
    'free variables
    Set myItems = Nothing
    Set myItem = Nothing
    Set myAttachments = Nothing
    Set myAttachment = Nothing
    Set myOlApp = Nothing
    Set myOlExp = Nothing
    Set myOlSel = Nothing
    
End Sub

And children, always remember: Google is your friend!
Landy, OUT!
/cue American Idols theme song
 
Last edited:
@Gunny: Thanks mate, e-mail in PM
@Claymore: I will have a look, thanks

Up to now the Microsoft 'fix' worked quite nicely, as it is only used occasionally.
 
Top
Sign up to the MyBroadband newsletter
X