Question
Given an existing EXCEL file, write functions CountRows and CountCols that use the package openpyxl to perform each of the following tasks (make the worksheet
Given an existing EXCEL file, write functions CountRows and CountCols that use the package openpyxl to perform each of the following tasks (make the worksheet variable an input parameter):
a. Given the row and column numbers of a starting cell with a value in it, return the number of consecutive nonempty cells to the right of (and including) the starting cell, until finding the first empty cell.
b. Given the row and column numbers of a starting cell with a value in it, return the number of consecutive nonempty cells below (and including) the starting cell, until finding the first empty cell.
Include a main program that asks the user to enter the location and name of the EXCEL file and then allows the user to enter the row and column numbers of a starting cell and reports the number of consecutive cells both to the right and also below the starting cell.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started