- You will need to download and install the SolidityProject.vsix from the link you have provided.
Once installed, you will be able to create a new DecentralizedApplication which can be found under the Solidity folder.
The extension provides a sample structure, contracts and a readme file with instructions for integration with BlockApps.
Right clicking in a contract allows you to Compile and/or deploy a contract to BlockApps.
Compiling a contract mainly calls solc (which is embedded as a resource in the extension) and outputs the .abi and .bin files in the bin folder. You will need to use Explorer to view the files.
To deploy using Blockapps, follow the instructions on the readme file for installation and configuration of your project.
Note: If after creating a new project you have issues with the readme file continuously reopening, restart visual studio.
Syntax highlighting is not yet implemented, but work in progress. If you require this now there are extensions for Visual Studio Code and Sublime.
To deploy a contract a new transaction is created which will include the bytecode as part of the Data and no address. If you have parameters in the constructor this will need to be encoded correctly and appended at the end.
The are different libraries that simplify the process, depending on the programming language you are using to interact with Ethereum.
1. C#
As per the code generated in the question. Just use the function DeployContractAsync. You will have to create a .net project and add Nethereum as a reference using Nuget.
2. Javascript:
This is the most common language used to interact with Ethereum, you will need Web3 js, the abi used here can be found on the abi file, and the code is the bytecode.
web3.eth.contract(abi).new({data: code}, function (err, contract) {
if(err) {
console.error(err);
return;
// callback fires twice, we only want the second call when the contract is deployed
} else if(contract.address){
myContract = contract;
console.log('address: ' + myContract.address);
document.getElementById('status').innerText = 'Mined!';
document.getElementById('call').style.visibility = 'visible';
}
});
3. Java
To deploy the contract using Java you can use
Web3j, there is a console application which will allow you to create a code generated contract wrapper using the abi and bytecode as an input. Then you should be able to do something as follows:
YourSmartContract contract = YourSmartContract.deploy(
, , GAS_PRICE, GAS_LIMIT,
,
, ..., );
4. Truffle:
Last but not least, you can install truffle which will take care of the deployment for you using migrations.
Best Answer
Not sure on specific VS tutorials, but this is a generic tutorial for solidity: http://solidity.readthedocs.org/en/latest/
which should work on: https://visualstudiogallery.msdn.microsoft.com/96221853-33c4-4531-bdd5-d2ea5acc4799