Click here to Skip to main content
15,889,116 members
Home / Discussions / C#
   

C#

 
GeneralRe: Serial Communication Problems... Pin
Mike Dimmick10-Jul-04 8:39
Mike Dimmick10-Jul-04 8:39 
GeneralRe: Serial Communication Problems... Pin
Randy2412-Jul-04 7:53
Randy2412-Jul-04 7:53 
Generalpinvoke and winmm.dll Pin
Oldmate10-Jul-04 4:35
Oldmate10-Jul-04 4:35 
Generallogin code Pin
Member 12278839-Jul-04 23:57
Member 12278839-Jul-04 23:57 
GeneralRe: login code Pin
Michael P Butler10-Jul-04 0:24
Michael P Butler10-Jul-04 0:24 
GeneralRe: login code Pin
Member 122788310-Jul-04 0:26
Member 122788310-Jul-04 0:26 
GeneralRe: login code Pin
Michael P Butler10-Jul-04 0:33
Michael P Butler10-Jul-04 0:33 
GeneralWMI Access - Help Pin
wakkerjack9-Jul-04 23:28
wakkerjack9-Jul-04 23:28 
Ive been battling with this prob for a LONG time now..
Using Threads and remote retrieval: i get a rpc error or COm exception sometimes? Like it's retrieving the values, and then it says rpc server unavailable and then if u carry on it will retrieve the next value.. happens with different values..

maybe deadlock occurs?

Basically- i use: private ManagementObjectSearcher m_MOSearcher;
private ManagementScope m_ManScope;
private ConnectionOptions m_ConnectOptions;

m_ConnectOptions = new ConnectionOptions ();
m_ConnectOptions.Username = "user";
m_ConnectOptions.Password = "pass";
m_ConnectOptions.Authentication = AuthenticationLevel.Call;
m_ConnectOptions.Impersonation = ImpersonationLevel.Impersonate;
m_ConnectOptions.EnablePrivileges = true;
m_ConnectOptions.Locale = "MS_409";
m_ConnectOptions.Timeout = new TimeSpan (0,0,0,0,5);

string strConnection = "\\\\"+ "192.168.0.88" + "\\root\\cimv2";

m_ManScope = new ManagementScope(strConnection, m_ConnectOptions);


ObjectQuery Temp = new ObjectQuery("SELECT " + "Size" + " FROM Win32_" + "DiskDrive");
m_MOSearcher = new ManagementObjectSearcher (m_ManScope, Temp);

foreach(ManagementObject mo in m_MOSearcher.Get())
{
Console.WriteLine("Size: " +mo["Size"].ToString ());
}

Temp = new ObjectQuery("SELECT " + "Model" + " FROM Win32_" + "DiskDrive");
m_MOSearcher = new ManagementObjectSearcher (m_ManScope, Temp);

foreach(ManagementObject mo in m_MOSearcher.Get())
{
Console.WriteLine("Model: " +mo["Model"].ToString ());
}


And thread it with:
for (int i=0; i< 250; i++)
{
Thread a = new Thread(new ThreadStart(Function));
a.Start();
}
QuestionIn StringBuilder copied from richTextBox fast way to findout end of line ? Pin
evdoxos9-Jul-04 23:23
evdoxos9-Jul-04 23:23 
AnswerRe: In StringBuilder copied from richTextBox fast way to findout end of line ? Pin
mav.northwind9-Jul-04 23:42
mav.northwind9-Jul-04 23:42 
GeneralRe: In StringBuilder copied from richTextBox fast way to findout end of line ? Pin
evdoxos10-Jul-04 0:34
evdoxos10-Jul-04 0:34 
GeneralRe: In StringBuilder copied from richTextBox fast way to findout end of line ? Pin
mav.northwind10-Jul-04 5:22
mav.northwind10-Jul-04 5:22 
AnswerRe: In StringBuilder copied from richTextBox fast way to findout end of line ? Pin
leppie10-Jul-04 1:05
leppie10-Jul-04 1:05 
AnswerRe: In StringBuilder copied from richTextBox fast way to findout end of line ? Pin
partyganger10-Jul-04 4:09
partyganger10-Jul-04 4:09 
GeneralRe: In StringBuilder copied from richTextBox fast way to findout end of line ? Pin
evdoxos10-Jul-04 7:23
evdoxos10-Jul-04 7:23 
Questionhow to make Date function Pin
Anonymous9-Jul-04 20:26
Anonymous9-Jul-04 20:26 
AnswerRe: how to make Date function Pin
mav.northwind9-Jul-04 23:36
mav.northwind9-Jul-04 23:36 
GeneralRe: how to make Date function Pin
Werdna10-Jul-04 11:13
Werdna10-Jul-04 11:13 
GeneralIs it possible to serialize an assembly Pin
joelwwk9-Jul-04 18:26
joelwwk9-Jul-04 18:26 
GeneralRe: Is it possible to serialize an assembly Pin
Robert Rohde10-Jul-04 1:51
Robert Rohde10-Jul-04 1:51 
GeneralRe: Is it possible to serialize an assembly Pin
Nick Parker10-Jul-04 18:14
protectorNick Parker10-Jul-04 18:14 
GeneralChild Control Painting problems Pin
Jon_Slaughter9-Jul-04 17:15
Jon_Slaughter9-Jul-04 17:15 
Questionhow to catch key combinations? Pin
BrownJacket9-Jul-04 15:34
BrownJacket9-Jul-04 15:34 
AnswerRe: how to catch key combinations? Pin
mav.northwind9-Jul-04 23:33
mav.northwind9-Jul-04 23:33 
GeneralRe: how to catch key combinations? Pin
BrownJacket10-Jul-04 1:18
BrownJacket10-Jul-04 1:18 

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.