What does the program return value mean, for example 0(0x0) or 2 (0x2), when debug a program?

What does the program return value mean, for example 0(0x0) or 2 (0x2), when 
debug a program?

-- 
___________________
Xiongjun Xia 


0
Xia
9/12/2005 7:20:06 PM
vc.mfc 33608 articles. 0 followers. Follow

2 Replies
550 Views

Similar Articles

[PageSpeed] 15

It's what WinMain (or main) returns.

-- 
Regards,
Nish [VC++ MVP]


"Xia Xiongjun" <xj-14@126.com> wrote in message 
news:%23wHd$78tFHA.2392@tk2msftngp13.phx.gbl...
> What does the program return value mean, for example 0(0x0) or 2 (0x2), 
> when debug a program?
>
> -- 
> ___________________
> Xiongjun Xia
> 


0
nish (347)
9/12/2005 8:36:17 PM
Think of these as random numbers. That way you won't be misled into thinking they have any
significance.  They so rarely have any significance that I can't think of the last time
anyone paid attention to them. I certainly have never looked at these return values for
the last 15 years or so.

Historically, these were returned by Unix console apps to indicate success or failure,
e.g., 0 (FALSE) meant success and non-zero ("true") mean failure.  This sort of limited
communication was the sorft of think Unix weenies loved, because they could write scripts
which could be carefully programmed to break instead of breaking accidentally.  Sometimes,
for some cases, which you cannot determine in advance, some console apps you launch might
actually return meaningful values, which maybe have some correlation to actual success or
failure, depending on the mood of the individual programmer who wrote the code, assuming
he or she was actually other than totally indifferent to the value returned.  See the
first paragraph on treating these as random numbers.
				joe
On Tue, 13 Sep 2005 03:20:06 +0800, "Xia Xiongjun" <xj-14@126.com> wrote:

>What does the program return value mean, for example 0(0x0) or 2 (0x2), when 
>debug a program?
Joseph M. Newcomer [MVP]
email: newcomer@flounder.com
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
0
newcomer (15975)
9/14/2005 4:21:47 PM
Reply:

Similar Artilces:

Overall Feedback on CRM 3.0? Anyone Really Disatisfied? Or Satisfi
Hi, I've invested abotu $12K into the CRM software (including the CRM licenses, annual maintenance and Scribe software for GP integration). And we do not have anything working yet. I am wondering if we should proceed with the MS CRM or throw it away and go with some other software. The feedback I've received so far from various people is not good at all - basically lots of money to get something that doesn't work all that well. We are a very small business and we can't afford to throw any more money away. I am super concerned about proceeding further. We are only a 10-...

MAPISP32 #2
MAPISP32 has taken over - uses almost all of the CPU (97 to 99%). Can't send or receive email. Restarting and not launching OUTLOOK gives me back my computer, but no email. Using OUTLOOK 97 on an XP machine. Have checked the postings, but found nothing about this problem (I get no error messages). Also tried renaming MAPISP32.dll and then reloading OUTLOOK, no improvement. Will check back later and thanks! ...

inserting a hard return with replace in a cell
Is there a way to insert a hard return or line break using the replace function in a cell? Thanks brent Use char(10) in your =replace() function. (and remember to turn wraptext on) Brent wrote: > > Is there a way to insert a hard return or line break using the replace > function in a cell? > Thanks > brent -- Dave Peterson Thanks! "Dave Peterson" <petersod@verizonXSPAM.net> wrote in message news:45FF0B46.FD839002@verizonXSPAM.net... > Use char(10) in your =replace() function. > > (and remember to turn wraptext on) > > > > Brent...

Beginning Inventory Balance #2
I am trying to duplicate the Average Inventory, according to KB856731, the formula is; (Beginning Inventory Balance + Summary of each months ending on hand Inventory + Current On Hand Inventory) / (number of months elapsed in the current year +2) Does anyone know what the formula is for the Beginning Inventory Balance? -- Anthony ...

Macro Security #2
Hi, I am trying to set the Macro security level to Low in Access 2003 but cannot find the option in the Tools\Macro menu. It is not even grayed out. The install is a complete install of Office 2003 and I tried a Detect and Repair without luck. Any suggestions? Thank you. Maybe a post in one of the Access newsgroups would get you an answer quicker. Clementius wrote: > > Hi, > I am trying to set the Macro security level to Low in Access 2003 but cannot > find the option in the Tools\Macro menu. It is not even grayed out. The > install is a complete install of Office 2003 ...

How can I asign a number value to a text line in Excel?
tI have a Backgammon Club with Internal Club Rankings that are in Text. I want my members to report their wins - 1st, 2nd, and 3rd place - in tournaments to my web site . I would like them to imput: their nickname, date of tournament, tournament Room #, tournament points played for, and host of the tournament. I would further like the calculation to display any change in Ranking as a text cell. Additionally, I want to show for the member, how many more points are needed to get to the next levle and what that (Text)level is. If there is a "what if" for this please advise. Ri...

Spaces issue not fixed in 12.2
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: Intel The previous threads have all been closed and none of them seem to have an answer. For anyone else struggling with Office not working with Spaces (and therefore having to disable Spaces to use Office 2008), here is the reply I just received from MS Office for Mac Tech Support: "The Spaces issue is still being worked on, please watch for future OS and Office updates" My guess is that as it has not been fixed in two service packs it is unlikely to change until Office 2012 (or whatever the next major release wil...

Preventing Column Cell Values from Printing
I have a summary worksheet with several columns of information. There is one particular column (E25:F39) where I don't always want to print the values. Is there some simple way to toggle this column's values on and off just before hitting the print command? I was thinking of using an adjacent tick box outside the print area, which when ticked would print the column values, and vice-versa. I'm looking for a formula that would examine the tick box, and if the tick (letter 'a' in Marlett font) is not present (i.e. cell value = ""), then the values in column (E25:...

Conditional Formatting #2
Hello, I have a spreadsheet that has about 1200 rows many of which need to have conditional formatting. I had a template set of rows that I was transferring the conditional formatting from and it worked for 20 or so rows. Then in attempting to both copy/paste and drag formatting even further I noticed that the conditional formatting was not being transfered to the target cells. I have even tried doing one row of formatting at a time but it seems like it will not allow any more conditional formatting. The spreadsheet is a good size (about 2MB). I recieve no error messages about this. It simpl...

How to find a value with multi-column, multi-record list
I have a spreadsheet with $costs arranged according to values in both rows and columns. How do I create drop down lists for both the rows and columns and then return the cell value? eg if I have 5 rows (2-6) and 6 columns (B-G) with costs arranged in each cell within this group how do I create drop downs for each selection, 2-6 and B-G, and return the value to a selected cell. In a typical table of this nature there would be descriptive row and column headers. To do a lookup on this table you would then look for the intersection of a specific row header and a specific column ...

How do I change the value in cell based on a future date
I would like certain cells to be cleared after a certain date one way: Put this in the ThisWorkbook code module (Right-click the workbook title bar and choose View Code): Public Sub Workbook_Open() If Date > #12/15/2004# Then _ Sheets("Sheet1").Range("A1,B2,J10,K39").ClearContents End Sub Note that this won't work if the user opens your workbook with macros disabled. Note also that there's no way to prevent a user from accessing your data - i.e., they can set their clock back and open the file. You can make things more difficu...

Printing 2 worksheets to a 2 sided document
Is there any way to print - front to back - 2 seperate worksheets? Turn the paper over and print the second worksheet???? Maybe you can create a worksheet with a picture of both ranges on it: Insert a new worksheet Edit|copy the first range shift-Edit|Paste Picture Link (on that new worksheet) Back for the second range and shift-edit|Paste picture link (right near your first pasted picture link). (insert a nice page break, too) And by pasting a link, you can change the original range and your picture will update right away. (Keep that worksheet as long as you want and print from there???)...

Export #2
Hi, How to export only the perticular group users. Regards Mustafa What sort of information do you need? "Mohammed Mustafa" <mohammed.mustafa@kharafinational.com> wrote in message news:OwKSDO$yGHA.3568@TK2MSFTNGP03.phx.gbl... > Hi, > > How to export only the perticular group users. > > Regards > Mustafa > See "IMI GAL Exporter" - http://www.imibo.com/imidev/Exchange/imige.htm "Mohammed Mustafa" <mohammed.mustafa@kharafinational.com> wrote in message news:OwKSDO$yGHA.3568@TK2MSFTNGP03.phx.gbl... > Hi, > > How ...

EndNoteX2 program
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: Intel I want to use EndNoteX2 program for reference management. I installed EndNote and found that EndNoteX2 was not compatible with Microsoft Office 2008, Japanese version. How can I use EndNote in office 2008, Japanese version? ...

solver and macros #2
Before you use the solver within a macro, you must establish a reference to the Solver add-in. With a Visual Basic module active, click References on the Tools menu, and then select the Solver.xla check box under Available References. If Solver.xla doesn't appear under Available References, click Browse and open Solver.xla in the \Office\Library subfolder. Cheers Nick ...

'error PRJ0019: A tool returned an error code from "Performing registration" Project Name
This is a multi-part message in MIME format. ------=_NextPart_000_0006_01C80055.07F02D20 Content-Type: text/plain; charset="gb2312" Content-Transfer-Encoding: quoted-printable Hi, all I wrote a COM project with VS2003, when I compile this project = ,finally I get the error like 'error PRJ0019: A tool returned an error = code from "Performing registration" Project Name. Any helpful ideas would be highly appreciated! -ja ------=_NextPart_000_0006_01C80055.07F02D20 Content-Type: text/html; charset="gb2312" Content-Transfer-Encoding: quoted-printable...

Trapping empty or null value
I have a subform with a textbox txtAmount bound to field Amount. On the subform's footer is txtTotal with control source =Sum([amount]). When there is no data in the subform I see #Error in the txtTotal. How can I change =Sum([amount]) to something that will test for this condition and display 0 when there is no data in the subform instead?. Robert Unless you are using Access 2007, you can check the RecordCount of the RecordsetClone of the subform. Unfortunately, the new version errors with that, so you have to use a function call. Public Function FormHasNoRecords(frm As F...

Transfering a changing cell value progressively through a workbook
I am creating a payment application form in excel 2007 using windows 7. Each worksheet represents one months invoice. Say I have a formula in "sheet 1/ cell Q7" that sums the total billed to date for a particular budget line item. This value will be transfered to a the next months payment application "sheet 2/ cell K7" this becomes the total amount of previous applications, then "sheet 2/ Q7 is =sum(K7,M7,O7) this value is transfered to "sheet 3/ K7, and so on and so on, until the completion of the job. How do I acomplish this. -- Thanks Mike ...

Closing registers #2
1. Is there any way too remove the closing figure when the registers are closed... I don't want my cashiers to see the closing amounts. 2. Can a group of registers be closed out on a selected machine, e.g Reg 1, reg 2, reg 3, reg 4 are all closed on reg 1. Thanks If you don't want cashiers to see closing amounts, lock them out of doing x/z reports and viewing the journal - apply this setting in SO manager - database - cashiers - properties of each cashier - uncheck these boxes. On question 2, out of the box, RMS does not allow that - each register has its own batch that must ...

SP3 Problem
Ever since I installed SP3 for Office XP, I have been getting the following error - "A program is trying to access email addresses you have stored in Outlook. Do you want to allow this?" I get this error only when I use Word as my email editor. Hence what is happening is that Outlook thinks that Word is a rogue program trying to send unauthorized emails. My question is, is there a way to prevent this - a whitelist of programs for example? Ajit Disable the PDFMaker addin. (See http://www.slipstick.com/outlook/ol2002sp3.htm#problems for details on how to do this.) "Aj...

CRM v1.2 for MSDN?
We are a UNIVERSAL MSDN Subsciber which means we pay about $4000 a year to get the entire Microsoft Library. I have not seen CRM 1.2 in any of the updates which is very strange since I normally see them before any other subscription. Did I miss an update? I also notice on the MSDN downloads section they still only have v1.0 listed. Thanks! CRM 1.2 is only just shipping to partners etc. I would not expect it to appear on MSDN for a couple of months "MEI" <MEI@MEI.COM> wrote in message news:Of0KXo7sDHA.3496@TK2MSFTNGP11.phx.gbl... > We are a UNIVERSAL MSDN Subsciber whic...

hyperlinks #2
When I click on a hyperlink in outlook IE opens and stays blank, but another window opens and asks me to Locate link browser. I have been closing this window, but it reappears on every link. ??????????????? It may help you http://support.microsoft.com/default.aspx?scid=kb;en- us;329912&Product=out >-----Original Message----- >When I click on a hyperlink in outlook IE opens and stays >blank, but another window opens and asks me to Locate link >browser. I have been closing this window, but it reappears >on every link. ??????????????? >. > ...

Freezing Panes #2
How can I freeze two different rows in a single sheet. -- Naidu Pl don't multi-post. Check responses in .misc -- Max Singapore http://savefile.com/projects/236895 Downloads:17,000, Files:358, Subscribers:55 xdemechanik --- "Naidu" <Naidu@discussions.microsoft.com> wrote in message news:967FF8C4-431D-4BAE-9903-ECCDE18157D7@microsoft.com... > How can I freeze two different rows in a single sheet. > > -- > Naidu ...

Deleting Mail #2
This problem seems to be random over our network. We are running Windows Server 2000 with Outlook 2002. Some users are getting a notification that they have mail and when they check, there is nothing in their inbox. The new mail has automatically gone to the deleted items folder. It doesn't do it with all mail for that particular user or do all the users on the network experience this problem. There are no rules set up to do this. Has anyone else have this problem. If you have a suggestion please respond to my e-mail address DKimball@puc.nh.gov Thanks I have Outlook 2002 on...

Pay commissions to 2 salespersons
Is there a way to pay commissions to two different salespersons for one line item? When I try to enter secont salesperson in "Sales Commissions Entry" window I receive a message "The commission amount may not be greater the sale amount distributed to this salesperson" Commissions in GP are calculated a little differently than what we think about. If I have two salespeople and I want to give each a 5% commission on the sale, then I need to give each of them a 10% commission on 50% of the sale. -- Jim "Pay commissions to 2 salespersons" wrote: > Is th...