CAsyncSocket::OnClose() giving errors on -1

For some reason my CAsyncSocket derivative is being passed -1 to the
parameters of its OnClose() member. According to the MSDN, the VC++ 6.0
version of CAsyncSocket::OnClose() should be passed 0, or a series of
WSAE macros which are in the 10000 range. What does it mean if I get
-1?

0
4/19/2005 12:31:29 AM
vc.mfc 33608 articles. 0 followers. Follow

0 Replies
730 Views

Similar Articles

[PageSpeed] 21

Reply:

Similar Artilces:

CAsyncSocket
My main thread creates a CAsyncSocket derived class and tries to connect to the server by calling the Connect method. Unfortunately, since CAsyncSocket is non-blocking, the OnConnect notification arrives as a message to the main window. But, I cannot continue processing until a successful connection has been established and I don't want to create a worker thread to initialize the socket. Is there any way I can process windows messages and wait until the OnConnect function returns with the connection status? "Rohit" <Rohit@discussions.microsoft.com> wrote in...

User error when attempting to create timesheet
Anyone seen this before? Any suggestions? > "The timesheet creation failed, because of problems with the project server or with data validations, such as resources not being valid work resources or users. Check your environment, and then try again". This person is a user with Team Member rights. Thanks, Andy Novak UNT Hi Andy, I knew this issue in the past. I was always able to get it solved by using surrogate timesheets. Sometimes it took serveral runs of deletion and recreation. Now I can only tell to install at least CU February (of course there is the ...

OWA
When user attempts to log off they end up on a page: http://.../exchange/ggdimov/?Cmd=logoff but a message is displayed saying page cannot be displayed - HTTP 500 - Internal server error. How can that be fixed? We have only one exchange 2000 STD server SP3 on Windows 2000 Advanced Server with SP4 Thanks George MCP 318239 XCCC: "HTTP 500" Error Message Occurs When You Log Off or You Use http://support.microsoft.com/?id=318239 Thanks, Richard Roddy Microsoft Exchange Support This posting is provided "AS IS" with no warranties, and confers no rights. -------------------...

Error while opening spreadsheets
Whenever i open any excel spreadsheet, i get this error saying that "A Document with the name "name of the Spreadsheet" is already open. You can not open two documents with the same name, even if the documents are in defferent folders" Pls help me on this as i hv neither any document of the same name nor am i trying to open one. This might be it: http://www.contextures.com/xlfaqApp.html#AlreadyOpen (From Debra Dalgleish's site) "Bij." wrote: > > Whenever i open any excel spreadsheet, i get this error > saying that > "A Document with ...

DAO error
When I load certain programs (i.e. Roxio Creator 2009, a program to track diabetes data), I get a series of error messages: 1. "Please wait while Windows configures DAO" 2. A dialog box requesting a location to search for the file 3. "Error 1706. No valid source could be found for product DAO...." I ahve had MS Access 2005 installed; I also just installed MS Office 2010 (including Access). I got the message during both periods. The Roxio program seems to work OK without the fix, but it's annoying. How can I make it stop? Thanks a heap, -Zz WinXP...

550 Errors HELP!!!!
With one particular client that we send email to, thier end keeps bouncing ALL emails from us. The NDR comes back as- MTP 550 error <EXCHANGESERVER.domain #5.5.0 smtp; 550 Hacked HELO: you are not EXCHANGESERVER.domain>. Sounds like most likely they are doing reverse lookups, and the fqdn presented in the HELO command does not match the PTR record, or you have a missing PTR record. Run a report of your domain at dnsreport.com and it should highlight any problems you have. Post back with what those problems are and we can help identify how to fix them. -- Ben Winzenz Exchange...

Ampersand in value gives me a pain
Some of the customers in the table I'm trying to see in an XML doc have an ampersand in the data. Looking at them and formatting the XML doc with a style sheet this generates an error. I'm creating the XML doc with VB.Net code, simply writing extracted values from my database to the XML doc. What do I have to do so that the ampersands in the data does not create problems while viewing the XML? Any help would b egreatly appreciated. Bob. You have to write an EscapeForXml() function in your VB program that accepts a string from your database and returns a string ready to insert into...

Macros error
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Hi There, I have an apple mac G5 with mac os 10.5 Leopard. <br><br>I have Office 2008 installed, and I keep getting an error in Excel, it has happened recently as the document worked before and I have never gotten this error. <br><br>When I open this specific document I get an error explaining that the document contains Macro's and I can either open and remove macros or open. If i choose open, the document opens and it looks fine, once i click on a &quot;button&quot; i have on the document that work...

HTTP Virtual Server Error
Hi All. I have a problem with my exchange server. We run outlook web access from the server and the HTTP virtual server has been stopped, when I try to restart it I get the following error message Cannot create a file when that file already exists Facility: Win32 ID no: 800700b7 Exchange System Manager Has anyone else already come across this problem, and if so how do I get round it. I have checked security permissions and they are correct. any ideas would be really helpful. ...

csocket error in Create
Hi, this simple code : Csocket temp; temp.Create(); is stores in dll . somehow it work when i call dll but from dialog app but when trying to this again from another application temp.Create() crash. any explanations??? Are you using static linking? You haven't given nearly enough information to tell us what is going on here. For example, when the declaration leaves scope, it is destroyed. So this example isn't too useful without some context. Also, don't use CSocket for anything. It produces unreliable programs and the CSocket code itself is reported to be buggy. Use CAsy...

Calling a bit of code from a sheet errors
I have this bit of code which messes up every now and then, but not al the time at all - I'll try anything to make it work!!! :) Application.Run "WorkInProgress.xls!Sheet7.CommandButton1_Click" (Have also tried Sheet7.commandButton1_Click and call xxx with both of the above) And it works MOST of the time - ie it tends to run about 6 of the 20 of these things that I'm doing then it stops. Then it falls over with: "Method "Run" of object "Application" error (or similar). Basically it crashes and stops.... But I need it to run through hundreds of ...

Debug Error
Using Outlook 2002 - Trying to open get a X Debug Error - Abnormal Program Termination - Retry to Debug - when click on retry it aborts. Any suggestions as to what this could be? Thanks in advance. Jo ...

CAsyncSocket::Receive and CAsyncSocket's threading...
Hi again, 1. Is CAsyncSocket::Receive a blocking function? 2. How is the IO Strategy for MFC's CAsyncSocket? 1 thread to do all stuff? Thanks again. pixelmana wrote: > Hi again, > 1. Is CAsyncSocket::Receive a blocking function? > 2. How is the IO Strategy for MFC's CAsyncSocket? 1 thread to do all stuff? > Thanks again. 1. No. "Async" means non-blocking. 2. CAsyncSocket sends you notifiction messages via the Windows message queue. These messages are just like button and mouse messages. CAsyncSocket turns them into calls to your derived class virtual fu...

CAsyncSocket
I have been unable to figure out a way to detect that the server that my client is talking to has lost its physical connection to the network. I have a simple server and client for debugging this problem. The server just accepts a connection and sends out a line of text every second. The client just connects and reads the socket, displaying each line as it comes in To test this, I fire up the two apps on different machines and let them run for a bit. Then I unplug the server machine's network cable. The client does not receive any notification that something is wrong (no OnClose noti...

RSS Feeds Send Receive Errors
I have seen this issue posted a few times, but I have never found a resolution. When first subscribing to RSS feeds using Outlook 2007, new posts are downloaded and everything appears fine. Later, when Outlook tries to get new posts, a number of Send/Receive errors occur for each feed. For example: Task 'RSS Feeds' reported error (0xD2840155) : 'Synchronization to RSS Feed:"http://feeds.feedburner.com/typepad/yOgm" has failed. Outlook cannot download the RSS content from http://feeds.feedburner.com/typepad/yOgm because of a problem connecting to the server.' Task &#...

Error Receiving Mail
In Outlook 97, when you try to click "Check for new mail", I am receiving the following error message: "A message could not be delivered. Make sure there is sufficient memory and diskspace and that the message store is accessible, then try again." If anyone can help me with this I would greatly appreciate it. Thanks, Glenn ...

Internal compiler error C1001 after SP6 installation
Hello NG, last week I installed the SP6 for my Visual Studio 6, Enterprise Edition (OS is Win XP Pro SP1). Unfortunately, i cannot compile several projects / project configurations any longer. The following compiler error occurs in all cpp files: d:\source\stdafx.h(30) : fatal error C1001: INTERNAL COMPILER ERROR (compiler file "msc1.cpp", line 1794) - or - c:\programme\microsoft visual studio\vc98\include\excpt.h(72) : fatal error C1001: INTERNAL COMPILER ERROR (compiler file "msc1.cpp", line 1794) The stdafx.h contains a class declaration at lin...

Again with CAsyncSocket
I'm again with my attemp of implement a CAsyncSocket class to my project. I started from 0 again and have a class (MySocket:public CAsyncSocket) that has to manage the connections. The constructor creates the server socket: MySocket::MySocket() { //CAsyncSocket* pServer = new CAsyncSocket; this->numclients = 0; int nPort = 15000; int ret = this->Create( 15000 ); if( Listen()==FALSE ) { //ERROR } else { //NO ERROR } } This opens my server and starts listening connections: void MySocket::OnAccept(int nErrorCode) { CAsyncSocket* client = new CAsync...

#Error Message
I have created a calculation to count the number of people and placed it in the Name Footer: =count([EyNumber]) and called the unbound box, CountNames. When there are no results it returns the #Error message. How can I remove this error message and display a message like, "No Data", or display the true results of a count? I have tried using the IsError function but can't seem to get it to work. Thanks Hi Nigel, Try: =IIf(IsError([EyNumber]), "No Data", Count([EyNumber]) Clifford Bass Nigel wrote: >I have created a calculatio...

Text Box results in error
I downloaded the "Issues" database template and modified it pretty heavily. One of the fields is a lookup type of field. In a canned report, this field displays fine when I place it in my detail section or my section header. If I try to use it in an unbound text box, I get an error. If I enter =[Application] or = "Appl: " & [Application] I get #Error Can anyone tell me why it works as a bound field, but not in a text box? -- Thanks! RBear3 .. Did you change the Name property of the text box as well? Access gets confused if the control has the same...

Understanding CAsyncSocket-- need perspective.
I've written several successful applications using CAsyncSocket, both server side and client side. I'm having trouble getting my mind around what exactly is going on in CAsyncSocket with a client side connection- and what the preferred method of connection is. My trouble is this: I've written a very small, q & d app which instantiates a casyncsocket on the stack, does a create() with no parameters and connects to a server (not under my control-- often a public site on say, an html port *80)). The connection always fails with WSAEWOULDBLOCK which I understand... in theory. ...

SSRS Connector Installation Error
Hello, We are getting the following error when attempting to install SSRS connector for CRM. Error| Check ReportServerValidator : Failure: Unable to validate SQL Server Reporting Services Report Server installation. Please check that it is correctly installed on the local machine. The KB 947060 provides some solution for this but it does not resolve it for us. Any thoughts? Thanks, Shikhar I have the same issue. Did you resolve it? ...

CAsyncSocket: how do you send?
As part of the process of learning MFC I've written a simple dialog based app that should allow the user to connect to a server, exchange strings with it and disconnect- telnet, really. I come from a VB background and am familiar with using sockets in that environment. This is why I'm comfortable with the MFC dialog based approach to life.. Anyhow, I can connect OK and the server response is handled correctly and added to a list box, but I can't figure out for the life of me how to send anything. Please have a look at the code: class CTERMSocket : public CAsyncSocket { public: ...

Error Report Wizard
Hi All, I am getting error whenever I try to create a report using the wizard. Everythings goes fine till the final step, and when the final step gets over it throws the error: Record is not available. The requested record was not found or you don't have sufficient permissions to view it. But the log tells a different story. Here is a snap shot of the error. [2010-01-10 01:32:27.8] Process: w3wp |Organization:e8bba7ae-a552-de11- b475-001e0b4882e2 |Thread: 5 |Category: Exception |User: 10c15bb5- a652-de11-b475-001e0b4882e2 |Level: Error | CrmException..ctor at CrmException..ctor(St...

MSCRM Application Error Report
Hi, I cannot connect to my CRM servers after using it for 3 weeks. Below is the error from the event viewer: MSCRM Application Error Report -------------------------------------------------------------------------------------------------------- Error Message: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Source File: Line Number: Stack Trace Info: at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain() a...