I am trying to code a basic excel file (but if anyone can make an actual basic program and charge me $300) to essentially auto-write operation reports for a plastic surgeon. The reports consist of 3 parts (plus a header/footer with the patient and doctors names). The risks paragraphs before the patient has anything done and what COULD HAPPEN that they discussed, the anesthesia type they were given for the operation, and then the actual operation procedure that was done.
So if the patient has a nosejob and their pecs augmented, the operation report would say a few paragraphs about the risks discussed in getting a nosejob, then it would talk about the risks of getting pectoral augmentations. THEN, it would say they were put under general anesthesia or whatever type they were given. THEN, it would say a few paragraphs about how the nosejob was actually completed, and then a few paragraphs about the augmentation.
There are a total of about 30 different generic choices (plus 4 anesthesia types) which coincide with 30 different paragraph sets at the first half of the report, and likewise 30 different paragraph sets at the second half. A patient may have anywhere from 1 to 5 procedures or so, which then equals 1-5 sets of writings, a paragraph on the anesthesia ,and then 1-5 sets of what actually happened.
As of now, my excel file is about 90 percent done and I am stuck. I basically wrote a set of IF STATEMENTS to where if a 1 is put in the cell next to which procedures were going to be had and done, they pull data from some other cells and put them into cells on a new worksheet. Because there are 30 different options or so, there may be up to 29 blank cells in between the paragraphs, i.e. if they had the first procedure to choose from and also the last one. i.e. cells A2 to A29 would be empty.
Here’s the problem, I want to copy and paste the final excel document that populated the paragraphs but with blank cells that translates to 29 or more blank lines on a Microsoft word document that have to be deleted. How do I make the empty cells go away before I do a copy and paste? I tried a hide function, but that would just hide data from the cell but the cell still equals one more line I have to erase. I tried a trim function on blank cells but they aren’t REALLY blank because they have a formula for the if statements in them that just hadn’t been activated for this patient. Any thoughts? Much appreciated!!
Bookmarks