Click here to Skip to main content
15,909,651 members
Home / Discussions / C#
   

C#

 
GeneralRe: Web Service Stack trace .. Pin
Pete O'Hanlon11-Sep-12 0:36
mvePete O'Hanlon11-Sep-12 0:36 
GeneralRe: Web Service Stack trace .. Pin
BobJanova11-Sep-12 0:44
BobJanova11-Sep-12 0:44 
GeneralRe: Web Service Stack trace .. Pin
Pete O'Hanlon11-Sep-12 1:56
mvePete O'Hanlon11-Sep-12 1:56 
GeneralRe: Web Service Stack trace .. Pin
Dave Kreskowiak11-Sep-12 2:03
mveDave Kreskowiak11-Sep-12 2:03 
QuestionHelp File Authoring Pin
Bart10-Sep-12 3:07
Bart10-Sep-12 3:07 
AnswerRe: Help File Authoring Pin
Pete O'Hanlon10-Sep-12 3:13
mvePete O'Hanlon10-Sep-12 3:13 
GeneralRe: Help File Authoring Pin
Bart10-Sep-12 3:42
Bart10-Sep-12 3:42 
GeneralRe: Help File Authoring Pin
Pete O'Hanlon10-Sep-12 3:47
mvePete O'Hanlon10-Sep-12 3:47 
GeneralRe: Help File Authoring Pin
Bart10-Sep-12 3:57
Bart10-Sep-12 3:57 
GeneralRe: Help File Authoring Pin
Pete O'Hanlon10-Sep-12 4:05
mvePete O'Hanlon10-Sep-12 4:05 
AnswerRe: Help File Authoring Pin
Bernhard Hiller10-Sep-12 22:07
Bernhard Hiller10-Sep-12 22:07 
AnswerRe: Help File Authoring Pin
BobJanova11-Sep-12 0:26
BobJanova11-Sep-12 0:26 
QuestionSystem.AccessViolationException openfiledialog win7 Pin
Rahul Sabharwal10-Sep-12 1:29
Rahul Sabharwal10-Sep-12 1:29 
AnswerRe: System.AccessViolationException openfiledialog win7 Pin
Eddy Vluggen10-Sep-12 1:40
professionalEddy Vluggen10-Sep-12 1:40 
GeneralRe: System.AccessViolationException openfiledialog win7 Pin
Rahul Sabharwal10-Sep-12 1:47
Rahul Sabharwal10-Sep-12 1:47 
GeneralRe: System.AccessViolationException openfiledialog win7 Pin
Eddy Vluggen10-Sep-12 2:31
professionalEddy Vluggen10-Sep-12 2:31 
QuestionNamedPipeServerStream.GetAccessControl Pin
True_Posi10-Sep-12 0:10
True_Posi10-Sep-12 0:10 
AnswerRe: NamedPipeServerStream.GetAccessControl Pin
Eddy Vluggen10-Sep-12 1:43
professionalEddy Vluggen10-Sep-12 1:43 
GeneralRe: NamedPipeServerStream.GetAccessControl Pin
True_Posi10-Sep-12 2:25
True_Posi10-Sep-12 2:25 
GeneralRe: NamedPipeServerStream.GetAccessControl Pin
Eddy Vluggen10-Sep-12 2:42
professionalEddy Vluggen10-Sep-12 2:42 
GeneralRe: NamedPipeServerStream.GetAccessControl Pin
True_Posi10-Sep-12 3:11
True_Posi10-Sep-12 3:11 
I think it simply does not connect (as far as i found out).

I also tried it with an AccessRole of a usergroup, i created only for users of my server. it does not work.


Code from the Server thread (As it works as with absolutely equal user accounts):

C#
private void NMP_ServerThread()
{
    int threadId = Thread.CurrentThread.ManagedThreadId; 

    try
    {
                
        // Create instance of the NMP-Server
        NamedPipeServerStream m_PipeServerStream = new NamedPipeServerStream(
            Properties.Settings.Default.PIPE_NAME
            , PipeDirection.InOut
            , SERVER_THREADS
            , PipeTransmissionMode.Byte
            , PipeOptions.Asynchronous
            , BUFFER_SIZE_kB
            , BUFFER_SIZE_kB);

        Console.WriteLine(string.Format("SERVER: Thread {0} :Waiting for child process connection...", threadId));
        pipeServerInstancePool.Add(threadId, m_PipeServerStream);
                
        this.State = ServerState.Started;
        pipeServerInstancePool[threadId].WaitForConnection();

        if (pipeServerInstancePool[threadId].IsConnected)
        {
            NMPEventArgs args = new NMPEventArgs();
            args.State = ClientState.Conneceted;
            RaiseOnClientSateChanged(this, args);

            while (State == ServerState.Started && pipeServerInstancePool[threadId].IsConnected)
            {
                StartAsyncReceive(threadId);
            }
        }
    }
    catch (ObjectDisposedException)
    {
        this.State = ServerState.Closed;
    }
    catch (IOException)
    {
        this.State = ServerState.Closed;
    }

    RaiseOnClientThreadFinished(this, new ClientThreadFinishedArgs(threadId));
} // END of void NMP_ServerThread()


Client Thread:

C#
private void NMP_ClientThread()
{
    pipeClient = new NamedPipeClientStream(
        Properties.Settings.Default.PIPE_SERVER
        , Properties.Settings.Default.PIPE_NAME
        ,PipeDirection.InOut
        ,PipeOptions.Asynchronous
        ,TokenImpersonationLevel.Impersonation);

    try
    {
        try
        {
            pipeClient.Connect();
        }
        catch (Exception ex)
        {
            Console.WriteLine(ex.ToString());
        }

        if (pipeClient.IsConnected)
        {
            RaiseOnStateChanged(this, new StateChangedEventArgs(ClientState.CONNECTED));
        }

        while (stopClient == false && pipeClient.IsConnected == true)
        {
            StartAsyncReceive();
        }
    }
    catch (Exception ex)
    {
        Console.WriteLine(ex.ToString());
    }

    RaiseOnConnectionLost(this, new EventArgs());
}

QuestionWhere clause in subcollection Pin
Mark Vloerjans9-Sep-12 21:18
Mark Vloerjans9-Sep-12 21:18 
QuestionRe: Where clause in subcollection Pin
Wayne Gaylard10-Sep-12 1:12
professionalWayne Gaylard10-Sep-12 1:12 
AnswerRe: Where clause in subcollection Pin
Pete O'Hanlon10-Sep-12 1:51
mvePete O'Hanlon10-Sep-12 1:51 
AnswerRe: Where clause in subcollection Pin
BobJanova11-Sep-12 0:31
BobJanova11-Sep-12 0:31 

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.