You can do this with Smart Dialing. Go to the Phone app. Hit the menu key and go to Options >Smart Dialing. Setup your office number and the appropriate extension length and wait time before entering the extension. Then, all you have to do is dial x1234 on the BB and it will automatically dial the number and enter the extension after the set wait time.