Microsoft Office Excel ® Kod Kılavuzu

Microsoft Office Excel® Code Guide

10 Temmuz 2006 Pazartesi

FileType Property


'UserForm1

Option Explicit
Dim i As Single
Dim DosyaSeçimi

Private Sub UserForm_Initialize()
On Error Resume Next
Me.Caption = "[PBİD®] MsoFileType Arşivi..."
Call MsoFileTypeArşivi
ListBox1.ListIndex = 0
End Sub
Private Sub ListBox1_Change()
On Error Resume Next
Set DosyaSeçimi = Application.FileSearch
With DosyaSeçimi
.LookIn = "C:\Windows"
.FileType = ListBox1.List(ListBox1.ListIndex, 0)
If .Execute > 0 Then
Label4.Caption = .FoundFiles.Count
For i = 1 To .FoundFiles.Count
ListBox2.AddItem .FoundFiles(i)
Next i
Else
ListBox2.Clear
Label4.Caption = 0
End If
End With
End Sub
Sub MsoFileTypeArşivi()
On Error Resume Next
ListBox1.AddItem msoFileTypeAllFiles: ListBox1.List(0, 1) = "msoFileTypeAllFiles"
ListBox1.AddItem msoFileTypeBinders: ListBox1.List(1, 1) = "msoFileTypeBinders"
ListBox1.AddItem msoFileTypeCalendarItem: ListBox1.List(2, 1) = "msoFileTypeCalendarItem"
ListBox1.AddItem msoFileTypeContactItem: ListBox1.List(3, 1) = "msoFileTypeContactItem"
ListBox1.AddItem msoFileTypeDatabases: ListBox1.List(4, 1) = "msoFileTypeDatabases"
ListBox1.AddItem msoFileTypeDataConnectionFiles: ListBox1.List(5, 1) = "msoFileTypeDataConnectionFiles"
ListBox1.AddItem msoFileTypeDesignerFiles: ListBox1.List(6, 1) = "msoFileTypeDesignerFiles"
ListBox1.AddItem msoFileTypeDocumentImagingFiles: ListBox1.List(7, 1) = "msoFileTypeDocumentImagingFiles"
ListBox1.AddItem msoFileTypeExcelWorkbooks: ListBox1.List(8, 1) = "msoFileTypeExcelWorkbooks"
ListBox1.AddItem msoFileTypeJournalItem: ListBox1.List(9, 1) = "msoFileTypeJournalItem"
ListBox1.AddItem msoFileTypeMailItem: ListBox1.List(10, 1) = "msoFileTypeMailItem"
ListBox1.AddItem msoFileTypeNoteItem: ListBox1.List(11, 1) = "msoFileTypeNoteItem"
ListBox1.AddItem msoFileTypeOfficeFiles: ListBox1.List(12, 1) = "msoFileTypeOfficeFiles"
ListBox1.AddItem msoFileTypeOutlookItems: ListBox1.List(13, 1) = "msoFileTypeOutlookItems"
ListBox1.AddItem msoFileTypePhotoDrawFiles: ListBox1.List(14, 1) = "msoFileTypePhotoDrawFiles"
ListBox1.AddItem msoFileTypePowerPointPresentations: ListBox1.List(15, 1) = "msoFileTypePowerPointPresentations"
ListBox1.AddItem msoFileTypeProjectFiles: ListBox1.List(16, 1) = "msoFileTypeProjectFiles"
ListBox1.AddItem msoFileTypePublisherFiles: ListBox1.List(17, 1) = "msoFileTypePublisherFiles"
ListBox1.AddItem msoFileTypeTaskItem: ListBox1.List(18, 1) = "msoFileTypeTaskItem"
ListBox1.AddItem msoFileTypeTemplates: ListBox1.List(19, 1) = "msoFileTypeTemplates"
ListBox1.AddItem msoFileTypeVisioFiles: ListBox1.List(20, 1) = "msoFileTypeVisioFiles"
ListBox1.AddItem msoFileTypeWebPages: ListBox1.List(21, 1) = "msoFileTypeWebPages"
ListBox1.AddItem msoFileTypeWordDocuments: ListBox1.List(22, 1) = "msoFileTypeWordDocuments"
End Sub

Hiç yorum yok:

Blog Arşivi

Bu gadget'ta bir hata oluştu

Bu Blogda Ara

Contributor

Contributor
Mustafa ULUSARAÇ İstanbul, TÜRKİYE
free counters
T. C. Central Bank Indicative Exchange Rates
Currency Exchange Rate Widget,Currency Converter Widget
Borsa İstanbul