Click here to Skip to main content
15,896,727 members
Home / Discussions / C#
   

C#

 
AnswerRe: computer science Pin
Gerry Schmitz26-Apr-21 8:59
mveGerry Schmitz26-Apr-21 8:59 
AnswerRe: computer science Pin
SeanChupas26-Apr-21 9:38
SeanChupas26-Apr-21 9:38 
AnswerRe: computer science Pin
Eddy Vluggen26-Apr-21 11:07
professionalEddy Vluggen26-Apr-21 11:07 
AnswerRe: computer science Pin
Mycroft Holmes26-Apr-21 12:17
professionalMycroft Holmes26-Apr-21 12:17 
AnswerRe: computer science Pin
Pete O'Hanlon26-Apr-21 20:54
mvePete O'Hanlon26-Apr-21 20:54 
QuestionMultiple chart display in winforms devexpress Pin
Member 1466381123-Apr-21 13:34
Member 1466381123-Apr-21 13:34 
AnswerRe: Multiple chart display in winforms devexpress Pin
OriginalGriff23-Apr-21 18:56
mveOriginalGriff23-Apr-21 18:56 
AnswerRe: Multiple chart display in winforms devexpress Pin
Eddy Vluggen24-Apr-21 6:10
professionalEddy Vluggen24-Apr-21 6:10 
AnswerRe: Multiple chart display in winforms devexpress Pin
Gerry Schmitz27-Apr-21 11:03
mveGerry Schmitz27-Apr-21 11:03 
QuestionSeparating numbers joined by "," into an array Pin
Alex Dunlop23-Apr-21 5:50
Alex Dunlop23-Apr-21 5:50 
AnswerRe: Separating numbers joined by "," into an array Pin
Richard MacCutchan23-Apr-21 6:09
mveRichard MacCutchan23-Apr-21 6:09 
AnswerRe: Separating numbers joined by "," into an array Pin
Dave Kreskowiak23-Apr-21 6:12
mveDave Kreskowiak23-Apr-21 6:12 
GeneralRe: Separating numbers joined by "," into an array Pin
Alex Dunlop23-Apr-21 6:53
Alex Dunlop23-Apr-21 6:53 
AnswerRe: Separating numbers joined by "," into an array Pin
OriginalGriff23-Apr-21 8:26
mveOriginalGriff23-Apr-21 8:26 
QuestionSeeking a better understanding of .NET multithreading and the System.Threading.Tasks.Parallel methods Pin
pr1mem0ver23-Apr-21 1:36
pr1mem0ver23-Apr-21 1:36 
AnswerRe: Seeking a better understanding of .NET multithreading and the System.Threading.Tasks.Parallel methods Pin
Richard Deeming23-Apr-21 6:37
mveRichard Deeming23-Apr-21 6:37 
GeneralRe: Seeking a better understanding of .NET multithreading and the System.Threading.Tasks.Parallel methods Pin
pr1mem0ver24-Apr-21 4:09
pr1mem0ver24-Apr-21 4:09 
GeneralRe: Seeking a better understanding of .NET multithreading and the System.Threading.Tasks.Parallel methods Pin
Richard Deeming25-Apr-21 21:16
mveRichard Deeming25-Apr-21 21:16 
GeneralRe: Seeking a better understanding of .NET multithreading and the System.Threading.Tasks.Parallel methods Pin
pr1mem0ver24-Oct-21 11:49
pr1mem0ver24-Oct-21 11:49 
AnswerRe: Seeking a better understanding of .NET multithreading and the System.Threading.Tasks.Parallel methods Pin
Gerry Schmitz23-Apr-21 7:07
mveGerry Schmitz23-Apr-21 7:07 
QuestionIPC Implementation for sending an integer from C++ exe to C# exe Pin
LokeshVarman22-Apr-21 22:32
LokeshVarman22-Apr-21 22:32 
QuestionRe: IPC Implementation for sending an integer from C++ exe to C# exe Pin
Richard MacCutchan22-Apr-21 23:05
mveRichard MacCutchan22-Apr-21 23:05 
AnswerRe: IPC Implementation for sending an integer from C++ exe to C# exe Pin
Victor Nijegorodov22-Apr-21 23:11
Victor Nijegorodov22-Apr-21 23:11 
GeneralRe: IPC Implementation for sending an integer from C++ exe to C# exe Pin
LokeshVarman23-Apr-21 0:06
LokeshVarman23-Apr-21 0:06 
i tried using namedpipes it just sends and receives but, My goal is to pass the elements from C++ and get that Elements at runtime in C# and process them. Like, Get n inputs in c++ and process that n elements in C#.
Eg: I am entering 5 inputs, say 1,2,3,4,5 in C++
where c# should get that inputs and process ( eg: inputelement + 1 )
the output would be 2,3,4,5,6.

C++ file

#include <windows.h>
#include <iostream>

HANDLE fileHandle;

int main()
{

fileHandle = CreateFileW(TEXT("\\\\.\\pipe\\pipesample"), GENERIC_READ | GENERIC_WRITE, FILE_SHARE_WRITE, NULL, OPEN_EXISTING, 0, NULL);

const char* msg = "hello from c++\r\n";
WriteFile(fileHandle, msg, strlen(msg), nullptr, NULL);
}


C# File


static void Main(string[] args)
{
var namedPipeServer = new NamedPipeServerStream("pipesample", PipeDirection.InOut, 1, PipeTransmissionMode.Byte);
var streamReader = new StreamReader(namedPipeServer);
namedPipeServer.WaitForConnection();



Console.WriteLine($"read from pipe client: {streamReader.ReadLine()}");
namedPipeServer.Dispose();
}

modified 23-Apr-21 6:19am.

QuestionHow to access incrementing ID number in SQL CE? Pin
Alex Dunlop22-Apr-21 5:49
Alex Dunlop22-Apr-21 5:49 

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.