|
Well what I meant was
<br />
void FOO(int* p){*p+=1;}<br />
<br />
int* i = NULL;<br />
FOO(i)<br />
If you use references then this sort of problem just can not occur.
So it is not that an error will be caught at compile time, there can be no error if you use references.
Anyway replacing pointers with references is not always feasible, if the concept of null object is valid, or if the pointer must be rebound (references cannot.)
I agree and that is what I said.
|
|
|
|
|
Can anybody tell me structure of make file how it is used and link with different environment
thanx
|
|
|
|
|
|
Hi everybody;P
I want to transfer a byte to parallel port, but i can't. Somebody help me do it.
Thanks,
hung
|
|
|
|
|
|
I can't link the URL that you sent
hung
|
|
|
|
|
Neither can I.
Try this
http://www.codeproject.com/csharp/csppleds.asp
|
|
|
|
|
hi,
i want to know any simple image capture API or method so that i can get capture image from a USB camera?
very simply! just capture image, return bitmap array or file handle... that's all!
need to use API in directdraw?
any help?
thanks,
jim
|
|
|
|
|
Tbanks a lot! how to display a text at the mouse?
|
|
|
|
|
GetMousePos, from memory, tells you the position. The in OnPaint, draw whatever text you want.
Christian
I have drunk the cool-aid and found it wan and bitter. - Chris Maunder
|
|
|
|
|
Your memory is going!
Its GetCursorPos()
Roger Allen
Sonork 100.10016
Death come early, death come late,
It takes us all, there is no reason.
For every purpose under heaven,
To each a turn, to each a season.
A time to weep and a time to sigh,
A time to laugh and a time to cry,
A time to be born and a time to die.
Dust to dust and ashes to ashes,
And so I end my song.
|
|
|
|
|
Can someone PLEASE tell me how to modify C++ code for prims Algorithm to tell if it's connected or not ? I know this is probably really simple, but I am having major codewriters block trying to figure it out!! HELP ME!!!
|
|
|
|
|
It being the graph.
|
|
|
|
|
Prim's algorithm computes a minimum spanning tree, starting from whatever vertex and adding one edge at a time. When the algorithm is done, you can verify whether the number of vertices in the spanning tree is equal to the number of vertices in the graph: if it is not, the graph is not connected.
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
I can't find any information on this subject.
I want to call a standalone exe from a dialog application.
For example I want to be able to call a media program from mine
like winamp or some standalone video player.
As a side note if I call an exe from a full screen dialog application how do
I give the exe the ability to go full screen or how do I temporally tell my
full screen dialog application to go away for awhile?
Thanks,
Steve
|
|
|
|
|
Go to MSDN and look up ShellExecute or CreateProcess. CreateProcess is much more complicated, but also more powerful - and you can wait for processes to finish with it. But ShellExecute is simpler, and may be all you need here.
If your nose runs and your feet smell, then you're built upside down.
|
|
|
|
|
That should do, thanks,
Steve
|
|
|
|
|
|
Hi,
I have a 3D object in OpenGL which I display in multiple view (top, bottom, left and right). Because my object is much longer than thick, I would like to expand the X-axis coordinates for the left and right view.
I only use one display list for all view and views have their own display context. So how can I change the appearance of the X-axis for specific view without rebuilding the display list ??
Thank you guys!
Jean Bédard
Optifor, Inc
Québec, Canada
|
|
|
|
|
I have problem with formview printing. 've downed the file and
try to print out the formview in my mdi application. However,
only i can print out is the control( gray colored ). Actually,
there is image on this control and this program can't print out
image but only control itself. does anyone have the same problem
and solve this problem before?
thanks in advance.
shin
// TODO: Add your command handler code here
CRect rect;
this->GetClientRect( rect );
CDC memDC;
CClientDC dc( this );
memDC.CreateCompatibleDC( &dc );
CBitmap bitmap;
bitmap.CreateCompatibleBitmap( &dc, rect.Width(), rect.Height() );
{
LocalGDI local( &memDC, &bitmap );
this->Print( &memDC, PRF_ERASEBKGND|PRF_CLIENT|PRF_CHILDREN );
}
m_dib.Attach( GDIUtil::DDBToDIB( bitmap ) );
CFormView::OnFilePrintPreview( );
|
|
|
|
|
Hey, question for you network buffs out there. Is there a way to do the equivilant of RunAs programmatically?
I have looked into CreateProcessAsUser and have consistently run into brick walls. I noticed there is a (rather lengthy and convoluted) example of its use on MSDN, but I get compile problems if I try to use it (can't find a certain API it's looking for.)
Any ideas? Or should I use "RunAs" and just pipe the password to it so no user interaction is necessary?
Thanks.
If your nose runs and your feet smell, then you're built upside down.
|
|
|
|
|
I've seen it done many times, and was wondering whether there's an API that makes it happen.
For a Console application, highlight the menu items as you navigate them with the arrow keys in order to make a selection.
Thanks for any insight.
William
Fortes in fide et opere!
|
|
|
|
|
Hi,
How do I set a default value for a radio button(mark one radio button by default) and how do I set a default value in a combo box when the dialog loads.
Karteek
|
|
|
|
|
just check in MSDN for CButton class , Read it in much details. Also check for CComboBox class...The information is there ...
VikramS
|
|
|
|
|
Need some help.
I have created a .dll library for an AI technology and have tested it on 98/2000 & ME OS. Project built using VC++ 6.0. I have someone having difficulty running on XP - what would the problem tend to be - memory handling? Never used XP and do not have it available. What would be so different? Do I need to go to .Net?
Any help greatly appreciated!
Thanks
Mike
http://www.ccoreinnovations.com
|
|
|
|