C
Camilla
I have a template for 20 different localoffice. The user
choose in a form which office they belong and then click
OK and it will be correct inserted in the pagehader. I
have all officeaddress as autotext, the code choose
correct address and put it in the textbox with this code:
ActiveDocument.Bookmarks("dn_Adress").Select
SaveSetting "DN", "Configuration", "DefaultAdress",
Me.CombAdresser.Text
Select Case Me.CombAdresser.Text
Case "Falun" '/Falun
ActiveDocument.AttachedTemplate.AutoTextEntries
("dn_Adr_Falun").Insert Selection.Range, True
Case "Gävle" '/Gävle
ActiveDocument.AttachedTemplate.AutoTextEntries
("dn_Adr_Gävle").Insert Selection.Range, True.
The bookmark is placed in pageheader in a textbox.
My very big problem is that I must reload the userform to
let the user change the address and when I do that will
the new officeaddress appear after the first one, I need
help how I can select and replace the text with the new
address. Can anyone help me with this?
Thanks for any help
Camilla
choose in a form which office they belong and then click
OK and it will be correct inserted in the pagehader. I
have all officeaddress as autotext, the code choose
correct address and put it in the textbox with this code:
ActiveDocument.Bookmarks("dn_Adress").Select
SaveSetting "DN", "Configuration", "DefaultAdress",
Me.CombAdresser.Text
Select Case Me.CombAdresser.Text
Case "Falun" '/Falun
ActiveDocument.AttachedTemplate.AutoTextEntries
("dn_Adr_Falun").Insert Selection.Range, True
Case "Gävle" '/Gävle
ActiveDocument.AttachedTemplate.AutoTextEntries
("dn_Adr_Gävle").Insert Selection.Range, True.
The bookmark is placed in pageheader in a textbox.
My very big problem is that I must reload the userform to
let the user change the address and when I do that will
the new officeaddress appear after the first one, I need
help how I can select and replace the text with the new
address. Can anyone help me with this?
Thanks for any help
Camilla