locked
Link a bookmark.. RRS feed

  • Question

  • Hi!
          Is this possible , if I can link a bookmark with a macro, I'm using Word 2003 , and I want a bookmark to be linked to a macro, please tell me how can I do that.

    Best Regards.

    Rashdan
    Thursday, May 28, 2009 1:45 PM

Answers

  • Hello Rashdan,

    Well this solution may be helpful to you. Because it not exact and use can use it and it works without any issue.

    Please follow below steps :
    • Open new word document
    • move vb editor
    • insert new module
    • create test() Macro as show below
    • Sub test()
      MsgBox "Test"
      End Sub

    • Now move to word document.
    • From Menu select Insert--> field
    • Now from fields Name select "Macro Button ".
    • In Display Text apply proper text
    • In the Macro Name select "test" (find macro name test which we had created in new module)
    • Click on ok.
    Now from Main Word Document. Click it and call your macro, as many time you like to call.

    Best wishes.

    Hope it will be useful to you.
    Thanks.


     Selection.Fields.Add Range:=Selection.Range, Type:=wdFieldEmpty, Text:= _
            "MACROBUTTON  test hello", PreserveFormatting:=False
    Rgrds, Brij http://accessvbadeveloper.wordpress.com
    • Proposed as answer by WPF_Rock Thursday, May 28, 2009 2:03 PM
    • Marked as answer by Rashdan Thursday, May 28, 2009 2:03 PM
    Thursday, May 28, 2009 1:55 PM