Hello, this should be simple, but I'm unsure of the correct syntax for initializing an array from a constructor. Consider :
class Firable {
public:
Firable (int wid_first, int wid_second, int wid_third)
: wids ( {wid_first, wid_second, wid_third} )
{
/* ... */
}
private:
int...
I have an object that I have created with "foo = new Object()". I would like to create a duplicate of this object, but it seems every way I try, the duplicate is actually just a reference to the same original object.
For example:
[code]foo = new Object();
foo.member = 3;
bar = foo;
bar.member...
It seems like all the PHP chat scripts are limited in that they have to keep refreshing the page all the time, or else they rely on additional server processes and (which many hosting providers do not allow).
I thought of a method that doesn't require a server process running continuously in...
A simple question I think, but I have no idea where to start:
How would I go about using the Flash ActiveX control to play an SWF file in my own applications?
Thanks for all help!
I have an Object, and I need to copy all its properties to another Object. I have tried simply assigning one object to the other like this: myNewObject = myObject;
However, that causes a weird problem. When I change a property of myNewObject, the same property changes in myObject!
Please help...
It appears as though you can't use Tab to cycle through buttons or PushButton components. But you can use Shift+Tab.
How can I enable Tab to work as it should?
Using Flash MX.
(For a demonstration, create a new document, drag 3 PushButtons from the Components panel. Then when you test the...
I have two SWFs... a parent swf which loads a child SWF.
In my parent SWF I have a button symbol which is exported for runtime sharing.
The child SWF imports the button, and specifies an on(release) handler for its instance.
When I test the movie (either the parent or the child) the button...
I have just installed Linux 2.4.22 kernel and I am trying to enable the computer to poweroff itself. I have tried APM builtin to the kernel, and also as a module. But when I do poweroff, I get this:
Flushing ide devices: hda hdb hdc hdd
Power down.
At that point, I can hear my hard drives...
I am writing a server that uses the telnet protocol to communicate with clients.
One of the commands I would like to implement will allow the client to edit their user-info with vi. Two concerns:
1. How do I invoke vi, such that the input from the socket goes into vi, and vi's output goes back...
I admit I'm a newbie to the C backend for MySQL. Anyway, here's my problem: I wrote a simple program to test the client library, but every mysql_* symbol is reported as unresolved.
Also, I might add, I am POSITIVE that libmysqlclient.a exists in /usr/local/mysql/lib.
#include <mysql.h>...
Hi, I am attempting to install Slackware Linux 8.1 on my PC and I am wondering what the most popular boot-management utility is out there. I have an old version of System Commander 2000, but it seems to have odd bugs with my 80GB hard drive.
Also, if possible I'm hoping there's a free one out...
Hi, I am using the MFC WinInet classes to retrieve files via HTTP.
I am doing this action in a separate thread, so that the User Interface can remain responsive.
However, I am wondering how I might implement a "Cancel" button for this behavior. A dialog would be displayed during the...
I have obtained a Process Identifier that I intend to use in a wait function. I understand that I must use OpenProcess to get a handle to the process. The first parameter of OpenProcess specifies the desired access to the handle... I think I need to specify SYNCHRONIZE access, but the SDK...
I have a problem trying to use SendInput in a program. When I use it, I get compiler messages saying that SendInput, the INPUT structure, etc, are undeclared. But I am staring straight at the declarations in winuser.h!!!
As a work around, I just copy and paste the prototypes directly into my...
This question seems really stupid--to me at least. Please help.
How does one obtain a non-const pointer to a std::string's internal buffer, for example to pass to the sprintf rountine.
What I'm thinking of is along the lines of MFC's CString::GetBuffer function.
Any help is appreciated.
Will
I wanted to use the _beginthreadex and _endthreadex C runtime functions, so to have them included in <process.h> I #defined _MT.
Now I get these errors:
connthread.obj : error LNK2001: unresolved external symbol __endthreadex
rbid.obj : error LNK2001: unresolved external symbol __beginthreadex...
How can I initialize Flash variables from the HTML page that contains it? For example, I have two variables _root.preloadalbum and _root.preloadsong, to which I would like to assign values, by means of JavaScript.
In the first frame of the flash file, I stop playback and send an FSCommand.
My...
The following code worked in an MFC dll, but when I moved it to a non-MFC DLL, the realloc function returns NULL.
void MD::nullstr()
{
if (((char*)data)[len-1] != 0) {
// at this location, data points to a valid address
// and len == 9
data = realloc(data,len+1);
//...
I would like to use the CAsyncSocket class for socket support in a console app that links to MFC. However, after creating the socket and binding it to a port, the console program terminates. I understand why, because the main function is allowed to exit.
I guess I need some kind of while loop...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.