- Katılım
- 13 Temmuz 2016
- Mesajlar
- 613
- Excel Vers. ve Dili
- Excel 2010 & 2016 Türkçe
DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
Altın Üyelik Hakkında Bilgi
Private Sub CommandButton1_Click()
Label1.Caption = Application.ExecuteExcel4Macro("'" & ThisWorkbook.Path & _
"\[" & TextBox1.Value & ".xlsx]Sayfa1'!r1c2")
Label2.Caption = Application.ExecuteExcel4Macro("'" & ThisWorkbook.Path & _
"\[" & TextBox1.Value & ".xlsx]Sayfa1'!r2c2")
Label3.Caption = Application.ExecuteExcel4Macro("'" & ThisWorkbook.Path & _
"\[" & TextBox1.Value & ".xlsx]Sayfa1'!r3c2")
Label4.Caption = Application.ExecuteExcel4Macro("'" & ThisWorkbook.Path & _
"\[" & TextBox1.Value & ".xlsx]Sayfa1'!r4c2")
End Sub
Teşekkürler yarın dener bilgi veririm
Sayın Orion1 Kodlar sorunsuz çalışıyor tekrar Teşekkürler
Buyurun.
Dosyanız ektedir.
Kod:Private Sub CommandButton1_Click() Label1.Caption = Application.ExecuteExcel4Macro("'" & ThisWorkbook.Path & _ "\[" & TextBox1.Value & ".xlsx]Sayfa1'!r1c2") Label2.Caption = Application.ExecuteExcel4Macro("'" & ThisWorkbook.Path & _ "\[" & TextBox1.Value & ".xlsx]Sayfa1'!r2c2") Label3.Caption = Application.ExecuteExcel4Macro("'" & ThisWorkbook.Path & _ "\[" & TextBox1.Value & ".xlsx]Sayfa1'!r3c2") Label4.Caption = Application.ExecuteExcel4Macro("'" & ThisWorkbook.Path & _ "\[" & TextBox1.Value & ".xlsx]Sayfa1'!r4c2") End Sub
If Dir(ThisWorkbook.Path & "\" & TextBox1.Value & ".xls*") = "" Then
MsgBox "dosya yolu yok"
Exit Sub
End If