Is it possible to disable the new toolbar customization feature programatically?
As in we'd like to make a custom toolbar, save the configuration, load it on our user's machines, and disable the option for them to make changes to what's on the toolbars (the individual buttons, not which toolbars are shown or the order of them on the command bar.)
Disable Toolbar Customize Programatically
Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange
-
- User
- Posts: 518
- Joined: Thu Dec 06, 2007 8:13 pm
-
- Site Admin
- Posts: 2449
- Joined: Thu Jun 30, 2005 4:11 pm
Re: Disable Toolbar Customize Programatically
You can use for this:
SetProperty("View.LockAllBars", 1, 0);
SetProperty("Commands["LockAllCmdBars"].State", "Offline", 0);
SetProperty("View.LockAllBars", 1, 0);
SetProperty("Commands["LockAllCmdBars"].State", "Offline", 0);
PDF-XChange Co. LTD (Project Developer)
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
-
- User
- Posts: 518
- Joined: Thu Dec 06, 2007 8:13 pm
Re: Disable Toolbar Customize Programatically
Thank you very much!
Didn't work the exact way I wanted, but pointed me towards what I wanted to do.
Didn't work the exact way I wanted, but pointed me towards what I wanted to do.
-
- User
- Posts: 17
- Joined: Fri Jun 05, 2009 7:08 am
Re: Disable Toolbar Customize Programatically
hello
<question>
1. tell me VB.NET code of next code.
SetProperty("Commands["LockAllCmdBars"].State", "Offline", 0);
2. i have to write next 2 code?
SetProperty("View.LockAllBars", 1, 0);
SetProperty("Commands["LockAllCmdBars"].State", "Offline", 0);
3. i would like to hide find tool bar's customize function too.
4. i would like hide context menu.
but i found that it appear after i clicked zoom and pan tool.
regards,
nais1
<question>
1. tell me VB.NET code of next code.
SetProperty("Commands["LockAllCmdBars"].State", "Offline", 0);
2. i have to write next 2 code?
SetProperty("View.LockAllBars", 1, 0);
SetProperty("Commands["LockAllCmdBars"].State", "Offline", 0);
3. i would like to hide find tool bar's customize function too.
4. i would like hide context menu.
but i found that it appear after i clicked zoom and pan tool.
regards,
nais1
-
- User
- Posts: 664
- Joined: Tue Nov 14, 2006 12:23 pm
Re: Disable Toolbar Customize Programatically
Hi
<answer>
1. AxCoPDFXCview1.SetProperty("Commands[""LockAllCmdBars""].State", "Offline", 0)
2. If you want to lock all toolbars then yes.
3. LockAllCmdBars command will deny any customization of any toolbar.
4. What exactly context menu you want to hide?
HTH
<answer>
1. AxCoPDFXCview1.SetProperty("Commands[""LockAllCmdBars""].State", "Offline", 0)
2. If you want to lock all toolbars then yes.
3. LockAllCmdBars command will deny any customization of any toolbar.
4. What exactly context menu you want to hide?
HTH
-
- User
- Posts: 17
- Joined: Fri Jun 05, 2009 7:08 am
Re: Disable Toolbar Customize Programatically
i wrote VB.NET code as following.
i would like to set disable on the any toolbar's customize function and context menu.
but context menu appered when i left-clicked on PDF after i right-click on "pan & zoom menuitem"
>4. What exactly context menu you want to hide?
AxCoPDFXCview1.SetProperty("View.LockAllBars", 1, 0)
AxCoPDFXCview1.SetProperty("Commands[""LockAllCmdBars""].State", "Offline", 0)
func_PDF(33132) 'context menu off
regards,
nais1
i would like to set disable on the any toolbar's customize function and context menu.
but context menu appered when i left-clicked on PDF after i right-click on "pan & zoom menuitem"
>4. What exactly context menu you want to hide?
AxCoPDFXCview1.SetProperty("View.LockAllBars", 1, 0)
AxCoPDFXCview1.SetProperty("Commands[""LockAllCmdBars""].State", "Offline", 0)
func_PDF(33132) 'context menu off
regards,
nais1
-
- User
- Posts: 664
- Joined: Tue Nov 14, 2006 12:23 pm
Re: Disable Toolbar Customize Programatically
You can disble all context menu by using next code:
AxCoPDFXCview1.SetProperty("General.DenyAllContextMenus", 1, 0);
AxCoPDFXCview1.SetProperty("General.DenyAllContextMenus", 1, 0);
-
- User
- Posts: 17
- Joined: Fri Jun 05, 2009 7:08 am
Re: Disable Toolbar Customize Programatically
thanks for your support.
i finally set disable the context menu.
nais1
i finally set disable the context menu.
nais1
-
- Site Admin
- Posts: 5223
- Joined: Tue Jun 29, 2004 10:34 am
Re: Disable Toolbar Customize Programatically
Excellent - thanks nais1.
If posting files to this forum - you must archive the files to a ZIP, RAR or 7z file or they will not be uploaded - thank you.
Best regards
Tracker Support
http://www.tracker-software.com
Best regards
Tracker Support
http://www.tracker-software.com