Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have two challenges that I have been trying all night to overcome. I'm hoping the collective wisdom of the forum can help me break-through these issues.
First, I cannot figure out how to execute a VB sub that takes parameters from the Run Macro action. Without parameters, it is easy. But if the sub has one or more parameters, no amount of trial-and-error can get it to work and I couldn't find a single example in the user reference guide.
Second, I'm trying to use a macro to capture the current selection state of a given field, store it and clear it upon entering a sheet, then restore the value upon exiting that sheet. I almost had it working using a combo of ActiveDocument.Fields("x").GetSelectedValues and ActiveDocument.Fields("x").SelectValues. However, it only works when the user specifically selects values. If instead they use the search (*xyz*) function to select values, then my solution doesn't work.
Is there any way to ask what is the selection criteria for a given field, store it in a variable, then later select that same criteria. It needs to work regardless of how many values are selected (within reason) or whether they select values or use a search string.
I happily await your wisdom.
Regards,
James
For item 1, could you perhaps give an example, don't quite get you.
For item 2, can't you use (additive) bookmarks?
Rgds,
Joachim