![]() ![]() Selection. Selection.MoveDown Unit:=wdLine, Count:=1 Selection.MoveRight Unit:=wdCharacter, Count:=1 ' Macro recorded þ16þ/08þ/2010 by Majid FouladpourĪ Range:=Selection.Range, NumRows:=4, NumColumns:= _Ĥ, DefaultTableBehavior:=wdWord9TableBehavior, AutoFitBehavior:= _ Here is the code generated by the recorder for my small test: Sub MakeTable() I just tested the second approach and it works just fine. ![]() ![]() When you have shaped and formatted the table end recording and you have captured all the required steps to place the exact same table wherever you want. Select the macro name that you assigned in Step 2 and click Edit. On the Developer ribbon, click Stop Recording. On the Home menu, click the Increase Indent button. Change the default macro name to a name of your choice and click OK to start the recorder. Press Ctrl+V to paste the copied table which will replace yourĪnother approach is to start macro recording and then create the table from scratch, that way you will not need a pre-existing table for the macro to work. On the Developer ribbon, click Record Macro.When you have your placeholder text found and selected, press Esc.Type the placeholder text into Find what box ( _table_goes_here_).Press Ctrl + F to bring up the Find dialog.Hold down Shift and press down arrow key enough times until the.Press Ctrl + Home to go to the beginning of the document (just.Then turn recording on and complete the following steps: To get it work, the table should exist before you run the macro.īefore you start recording the following conditions should be met: But note that macro recorder does not save the contents of the clipboard, so the markup that creates the table will not be saved with the macro. Invoke the recorder, then complete the steps to copy and paste the table, then you can edit it to see the macro's actual instructions. ![]()
0 Comments
Leave a Reply. |