I have been trying to execute my code on remix or ethereum wallet. But to deploy my smart contract, how can I execute the code without any gas and ether. I dont need it to be online. I just need to deploy for my project and it would be good if its offline and limit to local host to my computer.
Executing a smart contract (or even deploying it) costs gas (which is paid in ether), so there's no way to do what you are asking.
Now, you can setup testrpc to locally test your contracts. The test accounts will come with 100eth each.
Executing the contract will still cost gas/ether, but it is not real ether you are using in the test environment.