Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# ASP.NET
My project is offline examination system in that i developed server side coding fully. and mark calculation and timer controls are all working fine . login and logout controls are all fine.
 
But my problem is that now if i run that it will run only in one system , it will start the server and run in the browser. but since this is a offline examination system that is 20 systems will be attached over network and then that exam should be conducted. How to do that Frown | :(
 
I dont have any idea how to change it to client-server concept. something like multicasting
 
Can u help me out please :(
Posted 20-Feb-13 6:48am
Edited 22-Jun-13 5:09am
v5
Comments
Sandeep Mewara at 20-Feb-13 13:01pm
   
I assume by offline you meant no internet. By server, you have all 20 systems connected via LAN. Right?
Member 8780842 at 20-Feb-13 13:16pm
   
this is the connection i used
 
SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings["RegConnectionString"].ConnectionString);
Member 8780842 at 20-Feb-13 13:24pm
   
sandeep mewara yes
Member 8780842 at 20-Feb-13 14:30pm
   
Can you please help me
Member 8780842 at 21-Feb-13 7:25am
   
How Do I have to modify the database connection string :( sorry i am not aware of how to do it :( my old connection string is like this
 
SqlConnection con = newSqlConnection(ConfigurationManager.ConnectionStrings["RegConnectionString"].ConnectionString);

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

I assume by offline you meant no internet. By server, you have all 20 systems connected via LAN.
Based on this (that you already confirmed), you want to have database access through LAN.
 
Place your database on a server and all you need is correct connection string. Database server being on network, you should be easily able to connect to it. You don't need internet for it.
Database does not need to be on every system, just the connection string to the database and you are good to go.
  Permalink  
Comments
Member 8780842 at 21-Feb-13 7:34am
   
since i used sqldatasource while using that i got one connectionstring and so i used that to connect to the database but now since the database have to be in the server how to modify it . please
 
And another thing Sandeep Mewara your solution to keep database in network will solve my problem na orelse i have to perform any other thing or improvements too :( please
Sandeep Mewara at 21-Feb-13 7:38am
   
SqlConnection con = newSqlConnection(ConfigurationManager.ConnectionStrings["RegConnectionString"].ConnectionString);
is the way how you access the connection string.
 
Actual connection string will be in config file, modify that.
Member 8780842 at 21-Feb-13 7:40am
   
Yes Sandeep Mewara how should that string look like if it is to be accessed via network
 
syntax or any of that kind ? please
Sandeep Mewara at 21-Feb-13 7:42am
   
:doh:
Is the project you are working a copy-paste?
 
Even if you say you have worked on your system, you should be knowing how a connection string looks like for local system.
Member 8780842 at 21-Feb-13 7:45am
   
No sir i am a beginner i was asked to do a project in a new language and i took and did without hesitation . i saw some tutorial and developed a program fully . In that tutorial they used a sqldatasource and added a connectionString so i am not aware of that :( sorry to disturb you . since i am a beginner i am confused a lot :(
Sandeep Mewara at 21-Feb-13 7:47am
   
Doing things without understanding will not take you on long run. While following tutorial you should have understood what connection string is.
 
I have already shared the link with samples like:
Server=myServerAddress;Database=myDataBase;User Id=myUsername;Password=myPassword;
Member 8780842 at 21-Feb-13 7:50am
   
In this myServerAddress and userid and password how to set that please sir :(
Sandeep Mewara at 21-Feb-13 8:03am
   
I don't know and cannot give you that.
 
serveraddress is your database server machine name.
userid/passowrd is the access privilege permission to access that machine database.
 
Nothing more to share.
Member 8780842 at 21-Feb-13 8:05am
   
Ya thank you sir i got it . I should get these details in the SQLManagementStudio right :) thank you
Sandeep Mewara at 21-Feb-13 7:43am
   
Here, following should give you number of samples:
http://www.connectionstrings.com/sql-server-2012

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 278
1 Maciej Los 265
2 Nguyen.H.H.Dang 230
3 Peter Leow 195
4 arvind mepani 187


Advertise | Privacy | Mobile
Web01 | 2.8.140709.1 | Last Updated 22 Jun 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid