Change voicemailmain menu structure

is there any way to change voicemailmain menu structure . for example i dont need “change directory option” ( whenever user press 2 in voicemailmain ) .how i can disable this option ?
whether i must change voicemail application source code for this ?

Yup, you will have to change the code.

I’m just starting to experiment with this myself. If you’re familiar with C, or you’re going to contract out to someone who is, I can save you a lot of time by giving you these pointers:

in the source file apps/app_voicemail.c in Asterisk 1.2.1 source code:

vm_instructions (begins line 4523)
Contains code that tells the PBX how to “speak” the menu structure.

vm_execmain (begins line 5026)
Contains the code that tells the PBX what to do when certain options are selected.

Then you can recompile, but copy only the app_voicemail.so module to /usr/lib/asterisk/modules. If you make more changes, you can simply delete that one .so file and run a make again. It should skip over the stuff that’s already done, and save you a lot of time.

i tried to change code of the file app_voicemail.c or remove the file tottally but no effect, the only effect appears when i make changes in the file voicemail.conf.

also is there a way to delete all messages in a certain folder??