Posts

Showing posts from 2007

Network analyzer for mobile device

Image
Most of this explanation for network analyzer for the mobile device. When we are closing the "X" button on a windows mobile 6 C# application. Its not closing that is the reason we couldn't remove the dll from the memory. (specific to mobile network analyzer) Actually its minimizing. therefore its necessary to set one property MinimizeBox to false. http://msdn2.microsoft.com/en-us/library/system. windows.forms.form.mi... says; "Gets or sets a value indicating whether the Minimize button is displayed in the caption bar of the form." My understanding is it's not closing , but minimizing. If we set the property, we can trigger one event when the form closes, MainForm_Closing(object sender, CancelEventArgs e) then we can check the user preference and if the user does not need to save we can set the e.Cancel = false; //good bye.
#include "cc352.h" #include <netinet/tcp.h> int main(int argc, char **argv) { int fd; //socket descriptor int sndbuff = 32*1024; //send buffer int rcvbuff = 32*1024; int error;//to hold the errocode socklen_t len; // option len for getsock //create the socket. fd = socket(AF_INET,SOCK_STREAM,0); //call the socket option error = setsockopt(fd,SOL_SOCKET, SO_SNDBUF,&sndbuff, sizeof(sndbuff)); //setsockopt return 0 when it is ok -1 for error if(error) { printf("Set sockopt fails!n"); return -1; } //set the rcv buffer. error = setsockopt(fd,SOL_SOCKET, SO_RCVBUF,&rcvbuff, sizeof(rcvbuff)); if(error) { printf("Set socket option fail!n"); return -1; } //checking the values error = getsockopt(fd,SOL_SOCKET, SO_SNDBUF,&sndbuff,&len); if(error) { printf("Get Socket option fails!n"); return -1; } error = getsockopt(fd,SOL_SOCKET, SO_RCVBUF,&rcvbuff,&len); if(...