Click here to Skip to main content
15,887,302 members
Home / Discussions / C#
   

C#

 
QuestionThe semaphore timeout period has expired. Pin
C-P-User-313-Dec-12 8:01
C-P-User-313-Dec-12 8:01 
QuestionTextChat works fine and users are added to the list but VoiceChat doesn't work Pin
sagarDuwal13-Dec-12 7:47
sagarDuwal13-Dec-12 7:47 
AnswerRe: TextChat works fine and users are added to the list but VoiceChat doesn't work Pin
OriginalGriff13-Dec-12 8:15
mveOriginalGriff13-Dec-12 8:15 
QuestionLogin Screen Pin
txmatt13-Dec-12 5:15
txmatt13-Dec-12 5:15 
AnswerRe: Login Screen Pin
OriginalGriff13-Dec-12 5:21
mveOriginalGriff13-Dec-12 5:21 
AnswerRe: Login Screen Pin
XsenseX13-Dec-12 5:28
XsenseX13-Dec-12 5:28 
GeneralRe: Login Screen Pin
OriginalGriff13-Dec-12 5:42
mveOriginalGriff13-Dec-12 5:42 
AnswerRe: Login Screen Pin
Matt U.13-Dec-12 7:00
Matt U.13-Dec-12 7:00 
The way I've always done this is by using a DialogResult from the login form. In the login form's "Button1_Click" event handler, where you have verified that the login info is correct, instead of "this.Close();" use "this.DialogResult = DialogResult.OK;" And then to use it, go to the Program.cs file. In the Main method, remove "Application.Run(new MainForm());" and replace it with:

C#
LoginForm login = new LoginForm();
if (login.ShowDialog() == DialogResult.OK)
{
    Application.Run(new MainForm());
}


That is, unless you want the user to "log out" and see the login screen again. But in this case, if you don't need that functionality, this will show the main form ONLY if the dialog result is "OK". It eliminates the need for a property (global or otherwise). Do you see what I'm doing here or do you need more explanation?
djj55: Nice but may have a permission problem
Pete O'Hanlon: He has my permission to run it.

GeneralRe: Login Screen Pin
txmatt13-Dec-12 7:04
txmatt13-Dec-12 7:04 
QuestionIs there an issue with this script? Pin
Vasudevan Deepak Kumar13-Dec-12 4:38
Vasudevan Deepak Kumar13-Dec-12 4:38 
AnswerRe: Is there an issue with this script? Pin
OriginalGriff13-Dec-12 5:00
mveOriginalGriff13-Dec-12 5:00 
GeneralRe: Is there an issue with this script? Pin
Vasudevan Deepak Kumar13-Dec-12 6:17
Vasudevan Deepak Kumar13-Dec-12 6:17 
AnswerRe: Is there an issue with this script? Pin
Eddy Vluggen13-Dec-12 6:43
professionalEddy Vluggen13-Dec-12 6:43 
Questionстрана говна Pin
WebMaster12-Dec-12 22:00
WebMaster12-Dec-12 22:00 
AnswerRe: страна говна Pin
Pete O'Hanlon12-Dec-12 22:41
mvePete O'Hanlon12-Dec-12 22:41 
GeneralRe: страна говна Pin
Killzone DeathMan12-Dec-12 23:30
Killzone DeathMan12-Dec-12 23:30 
GeneralRe: страна говна Pin
Richard MacCutchan13-Dec-12 2:50
mveRichard MacCutchan13-Dec-12 2:50 
AnswerRe: страна говна Pin
Keith Barrow13-Dec-12 0:40
professionalKeith Barrow13-Dec-12 0:40 
GeneralRe: страна говна Pin
Richard Deeming13-Dec-12 1:24
mveRichard Deeming13-Dec-12 1:24 
QuestionHOW TO WRITE IN CONNECTION captcha XML?? Pin
WebMaster12-Dec-12 21:23
WebMaster12-Dec-12 21:23 
AnswerRe: HOW TO WRITE IN CONNECTION captcha XML?? Pin
Mycroft Holmes12-Dec-12 22:20
professionalMycroft Holmes12-Dec-12 22:20 
QuestionProblem when loading dll file in my project: Unable to load DLL “…” The specified module could not be found. (Exception from HRESULT: 0x8007007E) Pin
taibc12-Dec-12 19:21
taibc12-Dec-12 19:21 
AnswerRe: Problem when loading dll file in my project: Unable to load DLL “…” The specified module could not be found. (Exception from HRESULT: 0x8007007E) Pin
Sivaraman Dhamodharan12-Dec-12 19:26
Sivaraman Dhamodharan12-Dec-12 19:26 
GeneralRe: Problem when loading dll file in my project: Unable to load DLL “…” The specified module could not be found. (Exception from HRESULT: 0x8007007E) Pin
taibc12-Dec-12 23:48
taibc12-Dec-12 23:48 
AnswerRe: Problem when loading dll file in my project: Unable to load DLL “…” The specified module could not be found. (Exception from HRESULT: 0x8007007E) Pin
Mycroft Holmes12-Dec-12 22:24
professionalMycroft Holmes12-Dec-12 22:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.