R
Risky_Business
Hi All
I created a spreadsheet with checkboxes (controls) on it for reporting
purposes. I now need to import the data contained on the spreadsheets
into Access. The data is not laid out in neat columns or rows, it was
formated to be a stand alone report originally. My problem is not in
reading cells within the spreadsheet, I'm able to do that. My issue
is that I can't tell if a checkbox is checked or not.
What I've done:
If I execute the following code in Excel I return a boolean
partAM = CheckBox15.Value
I return true or false
Here is my access code:
Set xlapp = New Excel.Application
Set xlwb = xlapp.Workbooks.Open(f)
Set xlws = xlwb.Sheets("sheet1")
dte = Cells(4, 4)
adt = Cells(6, 4)
cse = Left(Cells(8, 4), 7)
cert = Mid(Cells(8, 4), 8, 4)
lname = Trim(Cells(10, 4))
fname = Trim(Cells(12, 4))
partAM = CheckBox15.Value
xlwb.Close
Set xlapp = Nothing
Set xlwb = Nothing
Set xlws = Nothing
Why does this code work in Excel but not Access???
Thanks a ton in advance
I created a spreadsheet with checkboxes (controls) on it for reporting
purposes. I now need to import the data contained on the spreadsheets
into Access. The data is not laid out in neat columns or rows, it was
formated to be a stand alone report originally. My problem is not in
reading cells within the spreadsheet, I'm able to do that. My issue
is that I can't tell if a checkbox is checked or not.
What I've done:
If I execute the following code in Excel I return a boolean
partAM = CheckBox15.Value
I return true or false
Here is my access code:
Set xlapp = New Excel.Application
Set xlwb = xlapp.Workbooks.Open(f)
Set xlws = xlwb.Sheets("sheet1")
dte = Cells(4, 4)
adt = Cells(6, 4)
cse = Left(Cells(8, 4), 7)
cert = Mid(Cells(8, 4), 8, 4)
lname = Trim(Cells(10, 4))
fname = Trim(Cells(12, 4))
partAM = CheckBox15.Value
xlwb.Close
Set xlapp = Nothing
Set xlwb = Nothing
Set xlws = Nothing
Why does this code work in Excel but not Access???
Thanks a ton in advance