I'm a true beginner at VBA, so please excuse my lack of vocabulary.
I'm using merge fields from excel to populate a 'paragraph' in word. Here it is.
084113 Exterior Storefront – Total «SF1T» Labor «SF1L»
«SF1Manu» «SF1Name» | «SF1Finish» with «SF1Year» Year Warranty | 1” Insulated Clear SolarBan70XL | 2 Beads of Caulk
«SF1Q» Total Openings | Approx. «SF1SF» SF
I've bookmarked the entire selection as SF1. Also, I've bookmarked the mail merge field <<SF1Q>> as SF1R. What I'm trying to accomplish is to delete SF1 entirely if SF1R is equal to 0. I'm struggling with Declaring (Dim) SF1R as an Interger or Long. I'm not sure if it is required. I'm attempting to create an if statement that looks like this: If ActiveDocument.Bookmarks("SF1R") = 20 Then Delete SF1 and I'm getting all kinds of errors! If someone can let me know what kind of declarations are required and help in constructing my if statement it would be greatly appreciated!