thank you very much my friend.it worked perfectly .the only problem was when i run it ,it didn t happen anything so i changed the third line from false to true(OpenAfterExport)
Now when i run it ,it opens directly the document in pdf form
Again thank you very much