Click here to Skip to main content
15,886,199 members
Home / Discussions / Managed C++/CLI
   

Managed C++/CLI

 
AnswerRe: medical store management Pin
Richard MacCutchan24-Feb-14 21:21
mveRichard MacCutchan24-Feb-14 21:21 
QuestionMODBUS TCP in C Pin
JJ_201016-Feb-14 21:13
JJ_201016-Feb-14 21:13 
QuestionRe: MODBUS TCP in C Pin
Richard MacCutchan16-Feb-14 22:56
mveRichard MacCutchan16-Feb-14 22:56 
AnswerRe: MODBUS TCP in C Pin
JJ_201016-Feb-14 23:14
JJ_201016-Feb-14 23:14 
GeneralRe: MODBUS TCP in C Pin
Richard MacCutchan17-Feb-14 0:35
mveRichard MacCutchan17-Feb-14 0:35 
GeneralRe: MODBUS TCP in C Pin
JJ_201017-Feb-14 0:48
JJ_201017-Feb-14 0:48 
GeneralRe: MODBUS TCP in C Pin
sathish_blr7-Jul-14 21:22
sathish_blr7-Jul-14 21:22 
Questionredirecting output of CMD with administrator privileges Pin
camillo8715-Feb-14 22:13
camillo8715-Feb-14 22:13 
Hello!
I have following problem. I want to create a application, which is using Netsh. I have created following code:

C++
private: System::Void button1_Click( System::Object ^ sender, System::EventArgs ^ e ) {
   
    Process ^ mojProces = gcnew Process();
    ProcessStartInfo ^ startInfo = gcnew ProcessStartInfo( "cmd.exe" );
    startInfo->Verb = "runas";
    startInfo->Arguments =( "Administrator /c \"netsh wlan start hostednetwork\" " );
    startInfo->UseShellExecute = false;
    startInfo->CreateNoWindow = true;
    startInfo->RedirectStandardOutput = true;
    startInfo->RedirectStandardInput = true;
    info->Text = "Sieć została uruchomiona.";
    mojProces->StartInfo = startInfo;
    mojProces->Start();
   
    StreamReader ^ wynik = mojProces->StandardOutput;
    String ^ wynik_konsoli = wynik->ReadToEnd();
    wynik_wysw->Text = wynik_konsoli;
    mojProces->WaitForExit();
    mojProces->Close();


Now I would like to redirect output of CMD, but there is following problem. When I set UseShellExecute=false, I cannot run CMD with administrator privileges, which is required to use Netsh. But when I set true I cannot redirect output. Could you please help, how can I solve this problem? Thank you in advance!
Questionhow to lock function used by thread? Pin
jone201324-Feb-14 20:43
jone201324-Feb-14 20:43 
AnswerRe: how to lock function used by thread? Pin
Malli_S4-Feb-14 23:28
Malli_S4-Feb-14 23:28 
QuestionHow to model endless-loop with states in UML-state-diagram Pin
Frygreen26-Jan-14 0:24
Frygreen26-Jan-14 0:24 
AnswerRe: How do model endless-loop in UML Pin
Richard MacCutchan26-Jan-14 1:11
mveRichard MacCutchan26-Jan-14 1:11 
AnswerRe: How to model endless-loop with states in UML-state-diagram Pin
jschell26-Jan-14 12:37
jschell26-Jan-14 12:37 
AnswerRe: How to model endless-loop with states in UML-state-diagram Pin
Stefan_Lang23-Feb-14 23:59
Stefan_Lang23-Feb-14 23:59 
QuestionI'm learning dev C++ later to make an application any advice please? Pin
Member 1053353119-Jan-14 7:29
Member 1053353119-Jan-14 7:29 
AnswerRe: I'm learning dev C++ later to make an application any advice please? Pin
Richard MacCutchan19-Jan-14 22:37
mveRichard MacCutchan19-Jan-14 22:37 
AnswerRe: I'm learning dev C++ later to make an application any advice please? Pin
Ger Hayden2-Feb-14 2:03
Ger Hayden2-Feb-14 2:03 
QuestionShellExecute Pin
Jerrick70079-Jan-14 10:38
Jerrick70079-Jan-14 10:38 
AnswerRe: ShellExecute Pin
Richard Andrew x649-Jan-14 11:13
professionalRichard Andrew x649-Jan-14 11:13 
QuestionWhat is difference between A2W and MutiByteToWideChar? Pin
WuRunZhe22-Nov-13 1:32
WuRunZhe22-Nov-13 1:32 
AnswerRe: What is difference between A2W and MutiByteToWideChar? Pin
Richard MacCutchan22-Nov-13 4:00
mveRichard MacCutchan22-Nov-13 4:00 
GeneralRe: What is difference between A2W and MutiByteToWideChar? Pin
WuRunZhe22-Nov-13 15:12
WuRunZhe22-Nov-13 15:12 
QuestionIcon color resolution Pin
nasrin198421-Nov-13 22:50
nasrin198421-Nov-13 22:50 
AnswerRe: Icon color resolution Pin
Richard MacCutchan21-Nov-13 23:00
mveRichard MacCutchan21-Nov-13 23:00 
AnswerRe: Icon color resolution Pin
WuRunZhe22-Nov-13 2:43
WuRunZhe22-Nov-13 2:43 

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.