15,300 Posted Topics

Member Avatar for devkc

You're going to have to provide a whole lot more information about your robot if you really expect anyone to help you. You made it sound like you have a robot walking down our city streets!

Member Avatar for akshaydusane
0
148
Member Avatar for emreozpalamutcu
Member Avatar for emreozpalamutcu
0
788
Member Avatar for Ancient Dragon

I'm trying to set up NetBeans IDE on my Vista Home, and have a choice between those two compilers. Which one would you choose? I also want to have Code::Blocks.

Member Avatar for marantis
0
212
Member Avatar for electrox73

In that case you need to learn to crawl before attempting to run in the Olympics. Learn the c++ language from the beginning. Its not something you can learn in an hour or two -- probably takes several months to learn just the basics well depending on how fast you …

Member Avatar for jackmaverick1
0
2K
Member Avatar for vedro-compota

Reading the input stream is the only standard way to do it. That means you have to dynamically expand the input buffer with realloc() while reading the input stream.

Member Avatar for vedro-compota
0
86
Member Avatar for AmerJamil

srand() is ued to seed the random number generator. If you call srand() with the same number every time your program is run rand() will generate the same sequence of random numbers, which is the default if the program never calls srand(). To get rand() to generate a different set …

Member Avatar for Ancient Dragon
0
181
Member Avatar for deanus

"setup and deployment"??? AFAIK the Express version does not have such an option.

Member Avatar for Ancient Dragon
0
97
Member Avatar for l1fel0ng

To attach a doc --- Look just below the Quick Message editor and you will see two buttons -- "Post Reply to this Thread" and "Use Advanced Editor". Click the "Use Advanced Editor". Next, scroll down until you see a button "Manage Attachments" then click that button. That will let …

Member Avatar for caperjack
0
96
Member Avatar for dip7

replace fread() with fgetc(). Of course you will have to deleted and rewrite eveything inside that while loop.

Member Avatar for Ancient Dragon
0
3K
Member Avatar for l1fel0ng

You can post, answer questions, or just browse around. It's up to you and no one will critisize you for whatever you want to do.

Member Avatar for l1fel0ng
0
91
Member Avatar for BDev338

The ThreadProc parameter to CreateThread() must be either a simple global c-style function or a static method of a c++ class. You can not pass non-static class methods to any win32 api function. line 12: handl = &thr_handl; Just what do you expect to accomplish with that statement??? As soon …

Member Avatar for Ancient Dragon
0
298
Member Avatar for amir malik

Post your code or do you think we are mind readers? malloc() and calloc() work perfectly -- its your code that doesn't work for some unknown reason.

Member Avatar for amir malik
0
285
Member Avatar for SpecialForce

make that check at line 40 of the code snippet you posted. If you don't want to process any subdirectories at all then delete lines 37-43, just leaving an empty if statement.

Member Avatar for SpecialForce
0
196
Member Avatar for mbhaluni2
Member Avatar for JonaRab

What part of the instructions do you not understand? Post what you have attempted to do so far.

Member Avatar for wolfson109
0
309
Member Avatar for ~s.o.s~

Happy New Year -- we still have 2 hours to go :) Years ago when I was a young lad it was fun to stay up at night and watch all the parties on TV. They don't do that any more, it's so boring now.

Member Avatar for Shinedevil
3
222
Member Avatar for kk33

create an array of HANDLE objects so that you can put the code in a loop. [code] const int MaxThreads = 20; HANDLE hThreads[MaxThreads]; for(int i = 0; i < MaxThreads; i++) hThreads[i] = (HANDLE)_beginthread(TheThread, 0, NULL); ... for(int i = 0; i < MaxThreads; i++) TerminateThread(hThreads[i],0); [/code]

Member Avatar for Ancient Dragon
0
250
Member Avatar for MasterGberry

If you want to convert C# to anything then convert it to CLR/C++ which is managed c++ and a very close cousin of C#. c++ itself knows nothing about System.

Member Avatar for MasterGberry
0
251
Member Avatar for alonewolf23

You should leave random_char as int because rand() will return values that overflow (dont fit) char. [URL="http://www.cplusplus.com/reference/clibrary/cstdlib/rand/"]Here[/URL] is a hint how to generate a random number between 'a' and 'z'. Note that any standrd ascii chart will tell you the decimal values of characters.

Member Avatar for alonewolf23
0
152
Member Avatar for libathos

reading date/time is simple -- just use the functions in time.h time() returns the current date/time in seconds since 1 Jan 1970. Then if you want to know the month, day and year you need to call localtim(), which returns a structure with that info.

Member Avatar for Ancient Dragon
0
291
Member Avatar for tomtetlaw

What compiler are you using? If you don't have the *.lib then you have to call LoadLibrary() and GetProcAddress() for each of the functions. But before you make any drastic changes to your code check the DLL project to see why the compiler didn't create the *.lib. It might because …

Member Avatar for tomtetlaw
0
172
Member Avatar for BChicago

function LoadUsers() must allocate space for each of the character arrays in the users array. All it is currently doing is using the same std::string over and over again, each time destroying the value of the previous time. Two fixes: 1. re-declare char* users[100] as vector<string> users. or 2. replace …

Member Avatar for Ancient Dragon
0
537
Member Avatar for jitender939
Member Avatar for Red Goose
0
122
Member Avatar for by_stander

since vectors are arrays why would you want to do that? You could create a vector of vectors [code] vector< vector<double> > RAzE1; RaZe1.push_back(range); RaZe1.push_back(az); RaZe1.push_back(el); [/code] Of course that won't work if you want to pass the array to a function that expects double[] Here is an exmaple [code] …

Member Avatar for by_stander
0
2K
Member Avatar for linova

There are at least a couple ways to do it. One is using <map> class and the other is to use an array. To use an array: create an int array of 255 elements, one for each possible char in the ascii character set. I know that's too many for …

Member Avatar for WaltP
0
159
Member Avatar for MasterGberry
Member Avatar for johnray31

If you want a class method to be inline then just code it directly in the class declaration. The inline keyword is unnecessary here. [code] class SomeApp { private: SomeApp() { } public: returnType_t SomeState() { // code here return 0; } }; [/code]

Member Avatar for Fbody
0
309
Member Avatar for AmerJamil

[URL="http://lmgtfy.com/?q=armstrong+number"]This [/URL]is an armstrong nuumber You will even find example programs how to compute them.

Member Avatar for Ancient Dragon
0
166
Member Avatar for Borzoi
Member Avatar for Borzoi
0
157
Member Avatar for lerkei

There are hundreds of program source code on the net. All you have to do is learn how to use google. There are several ways to do what you want, the oldest and most supported method is via ODBC.

Member Avatar for fdtoo
0
74
Member Avatar for Eddiebauer

post an example of what you are talking about. It might mean the function returns a 2d array of some sort. It could also mean that its a pointer to a function. Never know until you tell us more.

Member Avatar for Eddiebauer
0
194
Member Avatar for BBSharp

Welcome to DaniWeb. For those readers who are not from USA, he is from the state of Alabama, sothern part of USA. As for reputation points -- see those up and down arrows to the right of each post (except your own)? Just click one of them (up is positive …

Member Avatar for Ancient Dragon
0
96
Member Avatar for jay200032

If you hurry up you still have time to add code tags to your post so that people can read the code better. Just hit the Edit button and add this [noparse] [code] // put your code here [/code] [/noparse]

Member Avatar for Ancient Dragon
0
307
Member Avatar for Silkywings

Whether to use internal or external hard drive will depend on how much disk space all those games will consume. Since you have such a huge internal hard drive I would put them there if they take less than a couple hundred gb.

Member Avatar for cwarn23
0
189
Member Avatar for TSims11

managed c++ does not use new -- it uses gcnew. And you have to make W2 a pointer. The braces are unnecessary. [code] Window2^ W2; W2 = gcnew Window2; W2->Show; [/code]

Member Avatar for TSims11
0
165
Member Avatar for zachman1094

how to use: 1. call time() to get current date/time as number of seconds since 1 Jan 1970. 2. call localtime() to get struct tm pointer. If you want GMT them call gmtime() instead of localtime() 3. Use sprintf() or strftime() to convert the struct tm to a string in …

Member Avatar for Ancient Dragon
0
4K
Member Avatar for ft3ssgeek

You can't just add text to the beginning of a file. You have to completely rewrite the file to do that. First, open a new file, write the new text to it, then copy the old file to the end of the new file. Next, delete the original file then …

Member Avatar for Ancient Dragon
0
136
Member Avatar for AmerJamil

try declaring the arrazys globally, outside any function. And its [b]int[/b] main(), never void main() [code] #include <iostream> const int size=85020; int b[size]; char c[size]; float f[size]; int main() { std::cin.get(); } [/code]

Member Avatar for Ancient Dragon
0
174
Member Avatar for arshi9464

The maximum value of register ax (and other similar 16-bit registers) is 255. Any register can be treated as either signed or unsigned. So 255 is the maximum of unsigned while 126 is the maximum signed. Registers do not contain instructions -- only data. mov, jmp, cmp, etc are instructions.

Member Avatar for nezachem
0
101
Member Avatar for jelita31

[code] struct record { char name[80]; // blabla }; int main() { struct record[255]; // creates an array of 255 record structures // copy name to the first structure in the array strcpy(record[0].name,"John Smith"); } [/code]

Member Avatar for Ancient Dragon
0
39
Member Avatar for ggs234

>>I just discovered that it says right on my assignment that I am not able to be assisted by anyone You poor boy -- you should have read that before posting here. Next time learn to follow instructions.

Member Avatar for peter_budo
0
171
Member Avatar for wert21
Member Avatar for Sukhbir

And don't feel bad if someone posts a correction to whatever you said -- none of us are perfect. And you might be supprised at how much I've learned since joining DaniWeb too. Development is a life-long learning process and nobody stops learning.

Member Avatar for abhityagi85
0
2K
Member Avatar for cjoyce

Those numbers are the data types. They should be defined in one of the header files you have to include in your program. [URL="http://msdn.microsoft.com/en-us/library/ms714540(v=vs.85).aspx"]Here [/URL]is a complete list.

Member Avatar for kvprajapati
0
102
Member Avatar for Allasso

Would have to see the C code but most likely the -16 is allocating 16 bytes on the stack for local variables, such as four 4-byte integers.

Member Avatar for Tight_Coder_Ex
0
93
Member Avatar for Borzoi

A couple years ago I walked into a doctors office and the receiptionist told me that she had to do evething manually because her computer was broke and a repairman had not yet arrived to fix it. I asked her what happened to her computer and she told me she …

Member Avatar for The Mad Hatter
0
157
Member Avatar for mrectek
Member Avatar for mrectek
0
210
Member Avatar for daino

In Dev create a c++ project then just add all the *.c and *.cpp files to it that you want. Dev-C++ will do all the rest for you, you don't have to do a thing. But I would suggest you replace Dev-C++ with Code::Blocks because Dev-C++ is old and has …

Member Avatar for daino
0
188
Member Avatar for Naveen Haran
Member Avatar for chikkupa
-1
92
Member Avatar for Dark_Omen

[QUOTE=wamuti;513110]Also try MFC(Microsoft Foundation Classes). It is an encapsulation of Windows API. To make them work just compile, build and execute the ordinary way!. As easy as that(You can even skip compile:) ).[/QUOTE] I agree MFC is pretty easy to use, but it isn't free. Neither VC++ 5.0 Express nor …

Member Avatar for kvprajapati
-1
4K

The End.