-
remove and duplicate bookmark
Hi,
I have two question regarding bookmark, kindly please help.
Question 1:
I have a bookmark called ?O_Eng_Title?, sometimes it have value but sometimes it is ?blank? (I don't know it is space or null value), the result is:-
If the value of ?O_Eng_Title? have value, it will return:
Mr. ?..
If the value of ?O_Eng_Title? haven?t value, it will return:
?. <= few space in the front
I would like to know how to remove/delete it (the space) if this bookmark value is ?blank??
Question 2:
I have another bookmark called ?Owner_EnglishName? that I need to use it twice in same template, since I have no authority to make one more duplicate bookmark at the database, is it possible ?copy? this bookmark to another field/bookmark or any idea to make this bookmark can use twice at same template?
Please reply me with complete code of macro as I am new to macros and don't know VB.
Thanks for all your help!
-
1. Could you specifiy if these are range bookmarks (created by Insert > Bookmark), or Formfields - which are ALSO listed as bookmarks. Formfields are created using Forms Toolbar. I am assuming these are range bookmarks, but i want to check. It is relevant to how you may be getting the values. So - how are you getting the values??
2. You can duplicate a bookmark easily with a Ref field. Go to where you want to duplicate. Inset > Field > Ref. There will be a listing of bookmark you can use. Select one and press OK. Alt-F9 will update and it will show the value of the selected bookmark.
-
Thanks for your reply, Gerry,
1. Sorry that I am not sure the type of bookmark it is, as it is created by MIS, I know the information generated into a data base (seems from SQL) and then the bookmark is get form there, after generated the new document, all data are put into the field of bookmark already. (Use Alt-F9, it changed to {FORMTEXT})
2. I still don’t know how to mark a ref field, could you please tell me more about that?
-
If Alt-F9 gets FORMTEXT, then it is a formfield. Put your cursor on it (select it really), and right click (or press Shift-F10 the right click keyboard equivalent). Select Properties. The Bookmark name is the name of the formfield.
Check to see if there is a macro associated with it. It will either be in the dropdown field "Exit" or "Entry" below "Run Macro on:"
If there is, that is the code that is doing whatever it is it is doing....which I am not sure you have described. However, it seems to be picking up spaces from somewhere. You do not say where this is. In any case, if there is a macro there, it will need to be edited.
2. As I described. Here it is again:
2. You can duplicate a bookmark easily with a Ref field. Go to where you want to duplicate. Insert > Field > Ref. There will be a listing of bookmark you can use. Select one and press OK. Alt-F9 will update and it will show the value of the selected bookmark.
I don't see how I can make it clearer. But let's see...
You have a bookmark “Owner_EnglishName”.
Go to where you want the value of that bookmark duplicated.
Go Insert > Field > Ref
Select the bookmark “Owner_EnglishName”
Press OK.
-
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules