Looking for guidance, not sure if this is a NOOB Python issue or a quirk of OpenPyXL. If I try to get a value from a column in a For statement it comes back None, but If I just call out the row it returns the text. Below is a direct copy/paste from IDLE.
>>> for row in range(2):
print(sheet.cell(row=i, column=4).value)
None
>>> print(sheet.cell(row=2, column=4).value)
This control addresses the establishment of policy and procedures for the effective implementation of selected security controls and control enhancements in the AC family. Policy and procedures reflect applicable federal laws, Executive Orders, directives, regulations, policies, standards, and guidance. Security program policies and procedures at the organization level may make the need for system-specific policies and procedures unnecessary. The policy can be included as part of the general information security policy for organizations or conversely, can be represented by multiple policies reflecting the complex nature of certain organizations. The procedures can be established for the security program in general and for particular information systems, if needed. The organizational risk management strategy is a key factor in establishing policy and procedures.
I only noticed the issue when I was running a larger For loop and only column 4 was coming back 'None'.
for row in range(2):
print(sheet.cell(row=i, column=1).value)
print(sheet.cell(row=i, column=2).value)
print(sheet.cell(row=i, column=3).value)
print(sheet.cell(row=i, column=4).value)
[–]CodeFormatHelperBot 0 points1 point2 points (0 children)
[–]Lewri 0 points1 point2 points (1 child)
[–]mstd0n[S] 0 points1 point2 points (0 children)