Skip to content

Functions to detect use of formulas, macros and cell merging #944

Answered by JanMarvin
Jeff-White-AZ asked this question in Q&A
Discussion options

You must be logged in to vote

Checking for merged cells is simply comparing if the worksheet contains a mergedCells xml tag. In the code above I use this to identify the merged cells from the selected sheet.

Macros as in Excel macros that are run able from xlsm files are binary blobs that live in wb$bin or something like this, not really sure atm (but these are only those that are loadable with spreadsheet macros). Since xlsx files are zip files, you could embed anything inside them. And then there are excel addins and probably hundreds of other things I haven’t yet stumbled over.

For formulas, you can use the formulas part from the snipped above to check if there are any inside of the spreadsheet. That way your cases…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@Jeff-White-AZ
Comment options

@JanMarvin
Comment options

Answer selected by Jeff-White-AZ
@Jeff-White-AZ
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #941 on February 14, 2024 21:16.