Do You Know How Hackers Steal Your Credentials? Join us and Skyport Systems to learn how hackers steal your credentials and why Active Directory must be secure to stop them. Thursday, July 13, 2017 10:00 A.M. PDT
Option Explicit Private Sub CommandButton1_Click() Dim objExcel As New Excel.Application Dim wb As Excel.Workbook Dim FName As Variant Dim x As Long Dim LastRow As Long FName = objExcel.GetOpenFilename("Excel Files (*.xls), *.xls") If FName = "" Or FName = False Then GoTo Canceled: End If Set wb = objExcel.Workbooks.Open(FName) With wb.Sheets(1) LastRow = .Range("A65536").End(xlUp).Row For x = 1 To LastRow Me.ComboBox1.AddItem (.Range("A" & x).Text) Next x End With Canceled: objExcel.Quit End Sub
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.