How do I prevent multiple save dialogs loading when writing to users file system


#1

I have included the electron dialog and node fs module code (screenshot) that loads a save dialog and writes to a file respectively.

The issue I have is that multiple dialogs load when writing and saving to users file system.
For example the byte size of one file to save was 56299. 9 save dialogs loaded. It is really annoying.
I would show a screenshot but I am only allowed one.

Any suggestions would be appreciated.


#2

You can link to an external image. Or better, a gallery at a site like Imgur with full documentation of this phenomenon.

For example the byte size of one file to save was 56299. 9 save dialogs loaded.

I’m curious about why you felt that it was important to juxtapose these thoughts. Does the number of save dialogs scale with the size of the file?


#3

Thanks for replying.Yes it was a strange thought. I just threw it out there because on a smaller file size, less dialogs open.


#4

Can you identify a consistent relationship between file size and number of dialogs?


#5

No, there is no consistency but I missed a fundamental. I should have acted on my own comment //extract out saveXml.This was the issue - as I believe the data in the response is returned as a chunk. Am I right?


#6

I don’t know. Maybe someone else does.