-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: How to Database connection string in runtime
PostPosted: Wed Jun 02, 2010 5:15 am 
Newbie

Joined: Wed Jun 02, 2010 5:01 am
Posts: 2
I am using Nhibernate with c# & sql server 2005. How to Database connection string in runtime without using web.config?


Top
 Profile  
 
 Post subject: Re: How to Database connection string in runtime
PostPosted: Wed Jun 02, 2010 6:06 am 
Beginner
Beginner

Joined: Fri Feb 27, 2009 6:07 am
Posts: 38
Location: Moscow,Russia
Code:
Configuration configuration =new Configuration().Configure();
configuration.SetProperty("connection.connection_string", "Server=(local);Database=Test;Integrated Security=True");


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.