AlethZero basic contracts exploration

Running AlethZero/v0.5.17/Darwin/clang/

I can get it to plug into my local blockchain generated with Ethereal (0.6.0).

Now I want to explore some existing contracts, created from the Ethereal client (and notably their related storage).

The Panel called 'Contracts' is empty... :(
I guess it only shows contracts that are posted from my AlethZero client?

I should use instead the javascript console, right?
Is there any code snippet I can use?

What does turning on the 'Preview' mode should let me do?
I do not see any difference happening when I turn it on.

There is central panel which I believe is a webview.
There is an entry line at the top that I can fill with a path to a local html file:

Is the Javascript API in it the same than the Javascript API I would use for the Ethereal client?
They both have the 'eth' object operational.
But I cannot get the callbacks to work with AlethZero (which I -partially- can with Ethereal), only the synchronous calls work.

Where can I find an example html page (valid for this version of AlethZero!!!) that I could load in?

Help much appreciated!


  • AronVanAmmersAronVanAmmers Amsterdam, NetherlandsMember Posts: 40 ✭✭
    As I understand it, the JavaScript API of (the current version 0.5.17 of) AlethZero is slightly different from that of Ethereal (0.6.0). The signatures of the magic objects and methods are approximately the same, but no callbacks are used. The methods are synchronous and return the result of the operation directly.

    See the API description, specifically the small example at the bottom.

    In the JavaScript console, the following works for me (on the testnet):
    eth.storageAt("0x661005d2720d855f1d9976f88bb10c1a3398c77f", "0x0")
    This asks the "Config" contract (address 0x6610...77f) for the storage at index 0, the result being the address of the NameReg contract (address 0x5044...8ca).
Sign In or Register to comment.