Reputation: 63
I have the following neo4j server running on localhost, and I cannot figure out what the Uri string should be:
My database location is: "c:\users...\Documents\Neo4j\tutorial.graphdb"
My status says "Neo4j is ready. Browse to http://localhost:7474/"
class Program
{
static void Main(string[] args)
{
var client = new GraphClient(new Uri("http://localhost:7474/db/data/tutorial.graphdb"));
client.Connect();
Console.WriteLine("Done");
}
}
Browser works at: "http://localhost:7474/browser/"
Upvotes: 0
Views: 2407
Reputation: 1395
URI of connection string should include username and password.
So your code should look like this :
class Program
{
static void Main(string[] args)
{
var client = new GraphClient(new Uri("http://localhost:7474/db/data"),"neo4j","password");
client.Connect();
Console.WriteLine("Done");
}
}
Upvotes: 0