View Single Post
 
Old 02-15-2015, 10:57 AM
rsrasc rsrasc is offline Windows 7 64bit Office 2010 64bit
Competent Performer
 
Join Date: Mar 2014
Location: Germany
Posts: 148
rsrasc is on a distinguished road
Default

Try your macro but did not work. Don't know why. I tried something different. The following code was given to me by "MACROPOD". This code was from a previous posting by changing the following code:

.Text = " ([a-e].)"

For:

.Text = " (Answer)"


HTML Code:
[PHP][/PHP]
Sub DemoAnswer()
Application.ScreenUpdating = False
With ActiveDocument.Range
  .InsertBefore " "
  With .Find
    .ClearFormatting
    .Replacement.ClearFormatting
    .Forward = True
    .Wrap = wdFindContinue
    .Format = False
    .MatchWildcards = True
    .Text = ".([0-9]{1,3}.)"
    .Replacement.Text = ". \1"
    .Execute Replace:=wdReplaceAll
    .Text = " (Answer)"
    .Replacement.Text = "^p\1"
    .Execute Replace:=wdReplaceAll
    .Replacement.Style = "Strong"
    .Text = " ([0-9]{1,3}.)"
    .Execute Replace:=wdReplaceAll
  End With
  .Characters.First.Delete
End With
Application.ScreenUpdating = True
End Sub

My intention when I asked for a code was to see if there was a way to insert a carriage return with a macro. With a little modification to the above macro I was able to get what I want.

Here is how the information looks before applying the macro:


1. (a) The requirement is to identify the categories of financial statement assertions. Answer (a) is correct because the professional standards establish financial statement assertions for account balances, classes of transactions and disclosures. Answer (b) is incorrect because financial statement assertions are established for disclosures. Answer (c) is incorrect because financial statement assertions are established for classes of transactions. Answer (d) is incorrect because financial statement assertions are established for both classes of transactions and disclosures.

Here is how the information looks after applying the macro (which I like):


1. (a) The requirement is to identify the categories of financial statement assertions.
Answer (a) is correct because the professional standards establish financial statement assertions for account balances, classes of transactions and disclosures.
Answer (b) is incorrect because financial statement assertions are established for disclosures.
Answer (c) is incorrect because financial statement assertions are established for classes of transactions.
Answer (d) is incorrect because financial statement assertions are established for both classes of transactions and disclosures.


The question is, is there any way to modify the macro so I can have more spaces between the answer choices. Here is how the information should looks like.

1. (a) The requirement is to identify the categories of financial statement assertions.

Answer (a) is correct because the professional standards establish financial statement assertions for account balances, classes of transactions and disclosures.

Answer (b) is incorrect because financial statement assertions are established for disclosures.

Answer (c) is incorrect because financial statement assertions are established for classes of transactions.

Answer (d) is incorrect because financial statement assertions are established for both classes of transactions and disclosures.


Thank you all for your help!
Reply With Quote