Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recommended way to clear an area in an existing Excel sheet #198

Open
Mastomaki opened this issue May 13, 2022 · 1 comment
Open

Recommended way to clear an area in an existing Excel sheet #198

Mastomaki opened this issue May 13, 2022 · 1 comment

Comments

@Mastomaki
Copy link

What is the recommended way to clear an area in an existing Excel sheet?

@nathanrboyer
Copy link
Contributor

nathanrboyer commented Aug 10, 2022

You could just write over the cells with empty strings.

XLSX.openxlsx("testfile.xlsx", mode="rw") do file
   sheet = file[1]
   for col in 3:4, row in 2:3
       sheet[row, col] = ""
   end
end

sheet[row, col] = missing also works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants