Click here to Skip to main content
15,905,504 members
Home / Discussions / C#
   

C#

 
GeneralRe: static Method And Thread Safety Pin
Guffa23-Aug-05 0:40
Guffa23-Aug-05 0:40 
GeneralRe: static Method And Thread Safety Pin
HumanOsc22-Aug-05 23:58
HumanOsc22-Aug-05 23:58 
GeneralRe: static Method And Thread Safety Pin
M.Waseem Chishti23-Aug-05 0:15
M.Waseem Chishti23-Aug-05 0:15 
GeneralRe: static Method And Thread Safety Pin
Guffa23-Aug-05 0:06
Guffa23-Aug-05 0:06 
GeneralRe: static Method And Thread Safety Pin
M.Waseem Chishti23-Aug-05 0:29
M.Waseem Chishti23-Aug-05 0:29 
GeneralRe: static Method And Thread Safety Pin
Guffa23-Aug-05 0:44
Guffa23-Aug-05 0:44 
Generalcontrolling lcd Pin
Member 208806922-Aug-05 19:44
Member 208806922-Aug-05 19:44 
Generalread more bytes Pin
levi's22-Aug-05 19:44
levi's22-Aug-05 19:44 
Hi all!i have a read function here.I face a problem,it just can read limited byte only..Can somebody help me?Where to edit to make it read more bytes?Thank so much!
public byte[] Read(int NumBytes)
{
byte[] BufBytes; //------Declaring of dynamic Array
byte[] OutBytes; //------Declaring of dynamic Array

BufBytes = new byte[NumBytes]; //------Setting the Array Size to NumBytes( From parameter )

/*-- Check Port is Open --*/
if( hComm != INVALID_HANDLE_VALUE )
{
OVERLAPPED ovlCommPort = new OVERLAPPED(); //------Declaring of ovlCommport
int BytesRead = 0; //------Declaring of BytesRead and set to 0

ReadFile(hComm, BufBytes, NumBytes, ref BytesRead, ref ovlCommPort); //------Get data from RS232
OutBytes = new byte[BytesRead];//------Setting the size of Array to BytesRead
Array.Copy(BufBytes, OutBytes, BytesRead); //------Copy previous array data to new array data for preventing data loss

return OutBytes; //------Return the GET data
}/*-- End of Check Port is Open --*/

return null; //------Return null( nothing )
}/*-- End of Function Read --*/
GeneralRe: read more bytes Pin
HumanOsc23-Aug-05 0:15
HumanOsc23-Aug-05 0:15 
GeneralRe: read more bytes Pin
levi's23-Aug-05 17:39
levi's23-Aug-05 17:39 
GeneralContext menu in windows explorer Pin
Anonymous22-Aug-05 18:55
Anonymous22-Aug-05 18:55 
GeneralDetect SMTP MailServer Pin
machocr22-Aug-05 17:18
machocr22-Aug-05 17:18 
GeneralOwnerDraw PropertyGrid Pin
Shane Stevens22-Aug-05 15:51
Shane Stevens22-Aug-05 15:51 
GeneralTotal newb needs help. Pin
tomlog22-Aug-05 14:16
tomlog22-Aug-05 14:16 
GeneralRe: Total newb needs help. Pin
Christian Graus22-Aug-05 14:31
protectorChristian Graus22-Aug-05 14:31 
GeneralRe: Total newb needs help. Pin
tomlog23-Aug-05 6:30
tomlog23-Aug-05 6:30 
GeneralRe: Total newb needs help. Pin
Christian Graus23-Aug-05 13:27
protectorChristian Graus23-Aug-05 13:27 
GeneralProblem getting drag and drop to work between listbox with mode set to MultiExtended Pin
22-Aug-05 13:04
suss22-Aug-05 13:04 
GeneralRe: Problem getting drag and drop to work between listbox with mode set to MultiExtended Pin
Luis Alonso Ramos22-Aug-05 18:58
Luis Alonso Ramos22-Aug-05 18:58 
GeneralRe: Problem getting drag and drop to work between listbox with mode set to MultiExtended Pin
Member 221063323-Aug-05 12:34
Member 221063323-Aug-05 12:34 
Generalcomparing computation Pin
Sasuko22-Aug-05 12:57
Sasuko22-Aug-05 12:57 
GeneralRe: comparing computation Pin
Christian Graus22-Aug-05 13:04
protectorChristian Graus22-Aug-05 13:04 
Generaladding 2 buttons to a data grid Pin
Member 221087122-Aug-05 11:56
Member 221087122-Aug-05 11:56 
GeneralRe: adding 2 buttons to a data grid Pin
Christian Graus22-Aug-05 12:07
protectorChristian Graus22-Aug-05 12:07 
GeneralRe: adding 2 buttons to a data grid Pin
Member 221087122-Aug-05 13:37
Member 221087122-Aug-05 13:37 

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.