GetInBufferCount GetOneDimSize

Category: VC/MFC -> ATL/ActiveX/COM Author: phil4000 Date: 2001-07-09 16:51:48
 
phil4000
2001-07-09 16:51:48
The first is a data buffer , and the second is to get valid data , and this data is effectively what it meant, and now I accept the data , with GetInBufferCount returns over 7000 , with GetOneDimSize returns only 24 , why so much worse ... ...
haodayizhiyingqqqq
2001-07-09 17:01:52
GetInBufferCount ()   MSCOMM this is the function that returns the number of data buffer waits

GetOneDimSize read ()
COleSafeArray :: GetOneDimSize
This method retrieves the number of elements in a one-dimensional COleSafeArray object. 
under investigation MSDN

ggtest123
2001-07-09 17:13:35
simple point can be understood
inside a fixed size buffer is definitely a

data is a valid and invalid
both the sending and receiving both
may only use a portion of the buffer used part of the natural part of the data is valid
book_duckweedwz
2001-07-09 17:16:24
such buffers are 1024
and read the data received only 10
it is only these 10 data valid
probably mean
fxllxf
2001-07-09 17:30:10

COlesafeArray         is an array dimension can store any type of data , according to my understanding Oh ,
long   float   type of data could have been accounted for 4 bytes , because the array into safe inside, only count elements , and according to this algorithm, 1024 reduced to 24   difficulty should not be Get great
but GetInBufferCount is not binary but also hope the Supreme verify
ak4700313
2001-07-09 17:45:36
you these two functions is where they come . .
glassessnakes111
2001-07-09 17:50:18

how do these two things on the relationship between the
hkdg2001
2001-07-09 18:03:54
RecCnt   =   m_Comm.GetInBufferCount ();
test returns over 6000 data.

Cnt   =   safearray.GetOneDimSize ();
return 24 data

for   (i = 0; Cnt; i ++)
{
safearry.GetElement (& i, RecvData + i);
}

safearray is not just take this time to the 24 data.
jiayoujianmao
2001-07-09 18:16:10
what is effectively what is invalid ah
tzr0723
2001-07-09 18:22:39
little understood  
tankediyu1
2001-07-09 18:37:43
Can it be understood
buffer District accept binary number ( underlying hardware transmission )
converted to mscomm function is carried out in decompile , restore the character became

bold hypothesis , but also look carefully verify
Comments
zhouchenggang
2001-07-09 18:56:33

that this is too serious waste of resources to put ? ? ? ?
handshake protocol need to take so many problems?
yuyuyao
2001-07-09 19:03:11
SetInbufferSize ()   =   10000; input buffer is 10000;

m_Comm.GetInbufflen ()   has over 7000 number , indicating that the buffer has more than 7000 data
safearray.GetOneDimsize ()   return 24 , indicating that only 24 valid data. What is the relationship

valid data and the data in this buffer ? Or what valid data.

sxm776347289
2001-07-09 19:05:45
I also used when programming GetOneDimsize (), when the transmission is more than 14 the number of characters to return 14 ; return the actual number of characters is less than 14 .
would like to ask you to solve the problem yet?