devxlogo

Tip Bank

Returning an Argument by Reference

Question: What exactly returns a C++ function if it returns an object by a reference like: Person& GetNextPerson(); Please explain at assembly level, if possible. Answer: Assembly speaking, such a

Understanding Session_OnStart and Application_OnStart

Question: I am confused regarding the Application_OnStart and Session_OnStart events in the global.asa file. What I feel is that the application_onstart event is triggered the very first time the application

Pointer Arithmetic

Question: I am a programmer beginning to learn C++. I wrote this chunk of code: /////////////////////////////////////////////////////////////// Get to do some pointer arithmetic!/////////////////////////////////////////////////////////////#include #include const char NL = ‘ ‘;const char

Updating a VB6 DLL on the Web Server

Question: We have Internet Information Server (IIS) 4.0 running Active Server Pages (ASP) with a Visual Basic 6.0 DLL serving data content to the ASP pages. The problem lies when

Accessing Arrays

Question: Normally, you access an array by the number of the element you want. Is it possible, in C++, to access an element by the value and return the number?

Equivalent functions for Unchecked Conversion

Question: Are there any functions/libraries that can perform the Unchecked_Conversion function in Ada? We are writing a program that will read a bitstream. Upon determining the type, we want to

C++ Comments

Question: Why isn’t C commenting style preferred in C++? C commenting style definitely looks neater and more readable than the C++ commenting style. Answer: /* comments in C++ are just