15,300 Posted Topics

Member Avatar for GliderPilot

I agree, I don't really like the preview either as it seems confusing at times. A checkbox or control panel option to disable it would be nice.

Member Avatar for JorgeM
4
577
Member Avatar for poisonousgu

When you want to add a line to the end of a file you don't have to rewrite the file, just open with "a+", which will open the file for update and move the pointer to the end of the file. See more detailed description at [this link](http://www.cplusplus.com/reference/cstdio/fopen/).

Member Avatar for Ancient Dragon
0
286
Member Avatar for DarkVision

[edit]^^^ exactly as Mike posted above. The best way to do that is to create a virtual function in ExtraTerrestre class named putAlien() then override it in each of the derived classes. With that, line 28 in the code you posted will call the correct function in the derived class. …

Member Avatar for Ancient Dragon
0
154
Member Avatar for motrcolt

what compiler are you using? I presume it's Turbo C on MS-DOS. What you have to do is scroll the whole screen up one line then print something on the blank line at the bottom. Wait awhile then repeat the process. It's not going to look as smooth as you …

Member Avatar for Ancient Dragon
0
941
Member Avatar for amnakhan786
Member Avatar for Ancient Dragon
0
100
Member Avatar for Lucaci Andrew
Member Avatar for tech-ultrasonic
0
220
Member Avatar for smart.saravana.1

>the source codes should not be copied from the internet.. > pls send me the code and how it works.,.and what language So you're asking us to help you cheat??

Member Avatar for smart.saravana.1
-1
154
Member Avatar for umesh314

You need to pass the head of the linked list by reference rather than by value. That means functions need two stars, not one. For this function, since you are adding the new node to the head of the list an if statement isn't necessary. But you see that it …

Member Avatar for umesh314
0
110
Member Avatar for Sunshinex3

Maybe it would be easier to debug if you wrote a small program with main() that tests that class. That way you can test it without trying to debug your entire game at the same time.

Member Avatar for Ancient Dragon
0
127
Member Avatar for rodrigo.l.salazar.14

You need to check that the file was opened successfully. Put this after line 16 if( !infile.is_open()) { cout << "Error opening file\n"; return 1; } line 19: move the declaration of x up outside the loop so that it can be used to index into the array. line 20: …

Member Avatar for Ancient Dragon
0
163
Member Avatar for AznWun

line 10: You are treating modify as if it were of type std::string, it isn't. modify is of type char\* and character arrays don't have methods like begin() and end(). lines 3-5: What is the purpose of those lines? You can't convert a single character as you declared on line …

Member Avatar for ravenous
0
323
Member Avatar for PM312

You need to check the ocx versions before replacing it, you could render your computer unusable if you replace an existing ocx with an older version. Have you tried to re-register it? [Here are some tutorials ](https://www.google.com/webhp?source=search_app#hl=en&tbo=d&sclient=psy-ab&q=how+to+register+an+ocx+in+windows+7&oq=how+to+register+an+ocs&gs_l=hp.1.1.0i13l4.0.0.1.1290.0.0.0.0.0.0.0.0..0.0.les%3B..0.0...1c.2gW31Hh_7J0&pbx=1&bav=on.2,or.r_gc.r_pw.r_qf.&fp=9eb487146e9930b&bpcl=39314241&biw=1039&bih=529)on how to do that.

Member Avatar for hkdani
0
394
Member Avatar for GeneClaude

The way I read the problem is that the program should print either 0 or 3 depending on the time. There is no equation for that, just a simple if/else statement.

Member Avatar for Ancient Dragon
0
465
Member Avatar for hg_fs2002

The reason yours won't compile is because two stars means a 2d array, but the array you declared is a 1d array. int array[] ={1,2,3}; int *p_array = array; p_array[1] = 99; // or the last line could also be `*(p_array+1) = 99;`

Member Avatar for Ancient Dragon
0
102
Member Avatar for sushan bastola

when you compiled it did you check to see if there are any errors or warning messages? Also, use Windows File Explorer to see if the executable exists in the project folder.

Member Avatar for Ancient Dragon
0
77
Member Avatar for GokuLSSJ4

>if ("symbol = +") When doing comparisons you have to use == operator, what you have above is an assignment operator. Don't get the two operators confused even though they look alot alike. Second problem with the above line is remove the quotes and put ' around the + symbol. …

Member Avatar for GokuLSSJ4
0
341
Member Avatar for PrimePackster

The problem is open() fails because you're trying to open the file for reading when the file doesn't exist. The file must exist in order to use ios::read flag.

Member Avatar for Ancient Dragon
2
193
Member Avatar for James19142

Are you trying to do something like this? class base { public: base() {x = 0;} protected: int x; }; class derived : public base { public: derived() {x = 1;} protected: int y; }; void foo(base* b) { derived* d = static_cast<derived*>(b); // <<<< this line } int main() …

Member Avatar for James19142
0
191
Member Avatar for matt.sunder.7

One way to solve it is to keep track of the original row numbers and the sum for each row, then when the rows are sorted the program will remember the original row numbers. Expand the array by two columns to do that int tekmovalci[rows][cols+2]={{7, 6, 9,0,22}, {8, 7, 8,1,23}, …

Member Avatar for Ancient Dragon
0
704
Member Avatar for JaxConer

Why allocate new memory for those links? You can just move the link from the original linked list to the new linked list and adjust pointers accordingly. No need to allocate new memory or delete old nodes. Your function is causing a lot of memory leaks because none of the …

Member Avatar for JaxConer
0
134
Member Avatar for kaywt

That is a poorly written program becuse it passes the vector to PlayWithStrings() by value instead of by reference, causing the program to duplicate the entire vector on each entry to that function. What compiler and operating system are you using?

Member Avatar for kaywt
0
227
Member Avatar for guy21

line 11: i+4 should be i+=4, the value of i is not getting incremented in your program.

Member Avatar for guy21
0
116
Member Avatar for HLA91

>>"linker error undefined reference to mciSendStringA@16" That is a completly different problem. It means it can not find the code to that function which is probably in a library somewhere. You need to find out what library that function is in and then add it to your project.

Member Avatar for graceville
0
3K
Member Avatar for Dani

It seems the only place where that would be useful is in the Community Center forums. I don't see any threads on the first page of any of the other forums where anyone with more than 0 checksmarks have started threads.

Member Avatar for diafol
0
311
Member Avatar for thammalatha

You are probably trying to create the list box before the dialog box is created. Move the code to just before the return statement in OnInitDialog() as shown [here](http://msdn.microsoft.com/en-us/library/fwz35s59(v=vs.80).aspx).

Member Avatar for thammalatha
0
314
Member Avatar for thammalatha

If you handle the event in your derived class then your derived class will get the event, not the parent(s). Parent class will only get the event if your derived class calls it. >If you have supplied a handler for a specific message, or for a range of messages, in …

Member Avatar for thammalatha
0
237
Member Avatar for vishalonne

>gd=DETECT,gm,errorcode; Line 23: What is that trying to do? >if I enter 500,600,180,250 i am getting BLANK SCREEN. Print out the value of the calculations, x and y are probably off the screen.

Member Avatar for Ancient Dragon
0
130
Member Avatar for tomz6

what compiler do you want to use? If you use C# and Visual Studio 2012 the IDE will generate a lot of the code for you. If you use Visual Studio 2010 you can create a CLR/C++ Windows Forms project which will also generate most of that program. For some …

Member Avatar for mike_2000_17
0
966
Member Avatar for LastMitch

I see that the list changes each time you click on your profile and whenever you refresh the browser when it's already in your profile. Wouldn't it be easier to just give us a complete list and let us check the members we want to entorse? Or is the complete …

Member Avatar for LastMitch
2
598
Member Avatar for pritha.aash.7

The requirements for any given degree varies from one college/university to another. You have to ask the school you want to attend about its requirements. Most schools I know about have catelogs that describe the requirements for a degree.

Member Avatar for Ancient Dragon
0
59
Member Avatar for Hopp3r

>it's my understanding that IMissile* Create() (line 5) just points to the location in memory where a missile is created i.e IMissile* IMissile::Create() is that correct? No. The static keyword says that there is only one copy of the function that is used for all instances of the object. All …

Member Avatar for ravenous
0
199
Member Avatar for christinetom

To extend a little what phorce wrote, the pointers don't have to be pointers to arrays, but can be pointers to a single object such as a single integer. What exactly to pass to Func depends on how Func() is written. It could be either of the following, depending on …

Member Avatar for Gonbe
0
145
Member Avatar for TonyG_cyprus

live 5 more years lose some weight see my great-grandchildren (none yet) go bungee jumping go skydiving win the tax-free lottery

Member Avatar for jalpesh_007
0
160
Member Avatar for Shatrughan2010

There is no such thing as Windows 2008, you probably mean Visual Studio 2008? If you want to write plugins for Visual Studio then read some of [these links](https://www.google.com/webhp?source=search_app#hl=en&tbo=d&sclient=psy-ab&q=visual+studio+plugin+development&oq=visual+studio+pl&gs_l=hp.1.1.0l4.0.0.1.320.0.0.0.0.0.0.0.0..0.0.les%3B..0.0...1c.UnqTzfbhwCI&pbx=1&bav=on.2,or.r_gc.r_pw.r_qf.&fp=87ce17bb4aae0186&bpcl=38897761&biw=1097&bih=545). Note that this is not for c++ language or compilers, but to extend the Visual Studio IDEs. If you want to …

Member Avatar for mike_2000_17
0
121
Member Avatar for daino

You are using a function that has been depreciated, not intended to be used in new programs. http://www.sqlite.org/c3ref/free_table.html >This is a legacy interface that is preserved for backwards compatibility. Use of this interface is not recommended.

Member Avatar for Ancient Dragon
0
1K
Member Avatar for Dani

I thought it was just my isp, but apparently not. It's working normally now.

Member Avatar for JorgeM
0
106
Member Avatar for mattster

You have to compile that with a resource compiler, not a c++ compiler. What filename did you give that code? It needs to have .rc extension.

Member Avatar for mattster
0
330
Member Avatar for GolDRoger00

if you want to read all the lines in the file then make line 26 a while statement, not an if statement. >strEmployeeCategory == "J") You can't do that with character arrays. You have to call strcmp() to compare two character arrays like this `if( strcmp(strEmployeeCategory, "j") == 0)` strcmp() …

Member Avatar for Ancient Dragon
0
127
Member Avatar for mohamed.rani
Member Avatar for blindislands

put lines 1 thru 8 in a header file put the remainder in a .c file at the top of the .c file include the header file that you created in the first step create the make file Once you do the above you need to finish writing the functions …

Member Avatar for nullptr
0
136
Member Avatar for Ancient Dragon

I'm trying to figure out how to set up RSS feeds for specific DaniWeb forums. How can I find out what valid forum ID numbers are? [This page](http://www.daniweb.com/rss/pull) says to set it to 0 for all forums, so what if I only want C and C++ forums?

Member Avatar for Dani
0
115
Member Avatar for sunfizu

>i need turbo c soft for 64 bit.. There is no such thing. Turbo C was written only for MS-DOS 6.X and earlier (mid 1980s). It will not run natively on any modern version of MS-Windows. But not all is lost, you can get [DoxBox](http://www.dosbox.com/) and run Turbo C in …

Member Avatar for Ancient Dragon
0
135
Member Avatar for Ancient Dragon

For all our non-American friends here at DaniWeb this is a video that shows you what Black Friday means in America. http://techcrunch.com/2012/11/23/a-glimpse-of-the-apocalypse-walmart-customers-fight-over-phones-on-black-friday/

Member Avatar for <M/>
1
181
Member Avatar for new_developer
Member Avatar for serdar.ilarslan

If the user has to enter integers why are you using a std::string array? Why not an int array? The loop on line 8 is incorrect. Arrays are always numbered from 0 to the number of elements, for example if the array has 5 elelements then they are numbered 0, …

Member Avatar for serdar.ilarslan
0
324
Member Avatar for dot_binary

I don't know what compiler you are using, but this works (your second attempt) with vc++ 2012 Express. Maybe the problem is caused by something else in your program. #include <iostream> #include <fstream> int main() { long length; std::ifstream is("l.2"); is.seekg (0, std::ios::end); length = is.tellg(); std::cout << length << …

Member Avatar for dot_binary
0
260
Member Avatar for eminenz cw
Member Avatar for eminenz cw
Member Avatar for LastMitch

testing bump >I am concerned that this will lead to people posting "bump" and other such empty content just to get their names in the bar. Nope. It apparently doesn't work like that. once the thead is marked solved the bar doesn't change when new posters add to the thread. …

Member Avatar for Dani
4
220
Member Avatar for pritaeas

>And did it make you think windows is better mac os x operating systems? Anything is better than mac os x :) I have a friend that has it on a notebook, always crashing and corrupting files.

Member Avatar for BigPaw
2
199

The End.