15,300 Posted Topics

Member Avatar for kissiwat

>>scanf ( "%s", &rainfall ); %s wants a character array of at least 2 bytes. rainfall is not a character array, so the above will always fail to work correctly. [code] char rainfall[2]; // 1 byte for either Y or N and secnd byte for null terminator scanf ( "%s", …

Member Avatar for Infarction
0
111
Member Avatar for GreenDay2001

There are lots of tutorials -- [URL="http://home.netcom.com/~tjensen/ptr/pointers.htm"]here [/URL]is just one of them

Member Avatar for vitrag
0
92
Member Avatar for Ancient Dragon

Here's one that was written by Altert Einstein. Can you solve it? (Hint: create a matrix on paper to keep track of who does what) There are 5 houses in 5 different colours. In each house lives a person of a different nationality. The 5 owners drink a certain type …

Member Avatar for iamthwee
0
70
Member Avatar for matrimforever

when declaring a function you must specify the parameter types as well as name. For example [code] double computeUnitCost(int length,int width,int price) { // the code goes here } [/code] It is also necessary to declare the functions before they are used, so you need to put the function prototypes …

Member Avatar for ~s.o.s~
0
2K
Member Avatar for The Tao Of Bill

>> Date.obj : error LNK2028: unresolved token (0A00028C) "public: __thiscall Date::Date(class Date &)" (??0Date@@$$FQAE@AAV0@@Z) The above error (and similar other ones) is telling you that you forgot to code one of the Date constructors. If you look in Date.h you will find that it has two constructurs -- but in …

Member Avatar for iamthwee
0
236
Member Avatar for rowly
Re: enum

[code] printf("%s",records[i].M_F == 0 ? "Male" : "Female") [/code]

Member Avatar for Ancient Dragon
0
109
Member Avatar for Iron_Cross

quite frankly I don't think there are a whole lot of programs out there in the commercial world that use win32 api console functions very extensively -- most programs have GUI front ends. But [URL="http://www.codexxi.com/"]here[/URL] is a link to some example programs.

Member Avatar for Ancient Dragon
0
198
Member Avatar for naureen

I don't know how much equipment (hardware) you have at your disposal, but one real-world example is: Lets say we are in a factory that manufactures several different kinds of candy. After the candy is put in shipping containers (corrugated boxes) they roll down an assembly line past a barcode …

Member Avatar for Ancient Dragon
0
100
Member Avatar for Line

[QUOTE=Line;263974] What is causing this, and how do I avoid it? [/QUOTE] This line is causing it [code] strcat((char *)&midl, &text[i]); [/code] how to avoid it? I can't say because I don't know what you intend for it to do.

Member Avatar for Line
0
100
Member Avatar for kimw

sort the vector first, then you can use a [URL="http://en.wikipedia.org/wiki/Binary_search"]binary search algorithm[/URL]

Member Avatar for Ancient Dragon
0
99
Member Avatar for tarakant_sethy

not possible unless you already have a pointer to it because your program does not know the address of the node and because you also have to remove it from the linked list before deleting it.

Member Avatar for Ancient Dragon
0
79
Member Avatar for sugantha

sounds like you got some very very old and ancient MS-DOS code, such as [URL="http://www.teco.edu/~cdecker/webchip/api/serapi/doc/html/serapi_8c-source.html"]this[/URL] program. To make effective use of the REGS union you need to learn some assembly language, and especially about software interrupts 16 and 21. Those are not useful with any of the moders 32-bit compilers. …

Member Avatar for Ancient Dragon
0
103
Member Avatar for gampalu

took me all of about 2 seconds to find [URL="http://www.google.com/search?hl=en&q=matrix+c%2B%2B+class"]them[/URL]

Member Avatar for Ancient Dragon
0
61
Member Avatar for ~s.o.s~

at the end of every other day he will have Rs 5 left. So the answer must be (60/5) * 2 = 24th day. BTY: what is Rs ?

Member Avatar for Ancient Dragon
0
179
Member Avatar for server_crash

One thing is certain, end-of-the-world will certainly cause a crash in the real estate market, so will nuclear war. And prices in New Orleans (USA) plummeted after last year's hurricanes. [quote]That's the situation as it was at the end of the .com boom when many people in IT lost their …

Member Avatar for Ancient Dragon
0
172
Member Avatar for balekic

use tolower() instead of toupper() in that loop, then just use touper() on the first letter of the first word.

Member Avatar for balekic
0
84
Member Avatar for kissiwat

>>but can anyone write some code in C using if statements for the following: No! write it yourself, post code and ask questions. we do not do your work for you.

Member Avatar for Ancient Dragon
0
105
Member Avatar for dev.cplusplus

read [URL="http://msdn2.microsoft.com/zh-CN/library/a1z81fxe.aspx"]this[/URL] article, and [URL="http://msdn2.microsoft.com/zh-CN/library/82ab7w69.aspx"]this[/URL] one about DATE data type

Member Avatar for Ancient Dragon
0
647
Member Avatar for super_rookie

Here are just a few helpful hints: They are not all inclusive and you will no doubt encount other problems during the porting process. 1. rename the *.cpp files to *.c files 2. convert the classes in the .h files to normal structures and make the class methods just standard …

Member Avatar for Ancient Dragon
0
99
Member Avatar for edek

>> GlobalMirror2(&GlobalMirror,2); You can't do that after the object has been constructed. You can only do it when actually instantiating the object. You need to write an initializer method or other method that can be called to initialize those classes, something like this [code] GlobalMirror2.initialize(&GlobalMirror,2); [/code]

Member Avatar for edek
0
98
Member Avatar for Glorioso

I was wondering what "ally C" is? anything like an "ally cat" ?:) BTW: I have no idea about how to write a disassembler -- although I know an executable can not be disassembled back to C or C++ code. About the best you can accomplish is to generate the …

Member Avatar for Ancient Dragon
0
338
Member Avatar for UrbanKhoja

anyone driving that fast diserves whatever he gets. That's called "the theory of evolution at work", or "survival of the fitest". Hopefully he did not pass along his bad genes to any children.

Member Avatar for UrbanKhoja
0
287
Member Avatar for joey z

Please read [URL="http://web.daniweb.com/techtalkforums/announcement8-3.html"]this thread [/URL]about how to post code inside code tags so that spaces and tabs are preserved. There are also other helpful threads for newbes at the top of this board that contain links to other useful information. Thank you, and welcome to DaniWeb:)

Member Avatar for ~s.o.s~
0
173
Member Avatar for petzoldt01

>>How do I make sure that my program gets very little priority, but just enough to watch another program This is operating system dependent. In MS-Windows you can call SetThreadPriority() -- see MSDN for details. I don't know how its done in *nix. Can't answer your other questions. sorry.

Member Avatar for Ancient Dragon
0
136
Member Avatar for djskip

Please read[URL="http://http://web.daniweb.com/techtalkforums/announcement8-2.html"] this[/URL] and post your code when you are ready.

Member Avatar for DavidRyan
0
166
Member Avatar for alan_b
Member Avatar for jbennet

According to [URL="http://www.microsoft.com/windows/windowsmedia/player/windowsmobile/default.aspx"]Microsoft site[/URL] that version is still in beta so it may not work at all on Mobile wireless devices.

Member Avatar for jbennet
0
105
Member Avatar for ~s.o.s~

I got the same one -- manybe everybody does??? The most difficult questions for me were to select the picture that was least like the others. my favorits were the brain teasers. Too bad they didn't say which questions were incorrect.

Member Avatar for ~s.o.s~
0
165
Member Avatar for slacke

Depends on which version of that compiler is used -- 16-bit MS-DOS or 32-bit MS-Windows? 16-bit can create arrays up to only 64,000 bytes (large memory model), or 16,000 long integers. There is no work-around other than to redesign your program or use a modern 32-bit compiler, which is one …

Member Avatar for ~s.o.s~
0
235
Member Avatar for kararu
Re: Gdb

its been a long time, but I think you can use it on core files too. If your program produces a core dump you can use gdb on that core file.

Member Avatar for jim mcnamara
0
83
Member Avatar for DmD

You know the ID of each text box, right? And you have the HWND of the dialog box that contains the edit controls, right? Then use GetWindowText() for each box [code] char text[255]; // or however long the strings are // hWnd is the HWND of the dialog box HWND …

Member Avatar for Nick Evan
0
1K
Member Avatar for dmegee

>> cin >> filename; If there are spaces in the filename and/or path the above will not work because it stops at the first space. In that case use getline(). [code] while(!file_in.eof()) //as long as we're not at the end of the file....do { file_in >> temp; //reads file into …

Member Avatar for Ancient Dragon
0
97
Member Avatar for GreenDay2001

16-bit api functions are obsolete and were only useful on now dead MS-DOS 6.X and earlier operating systems. Don't bother with them. If you use a 32-bit compiler you can't use them anyway. [URL="http://www.winprog.org/tutorial/"] Here[/URL] is a good 32-bit tutorial that you should learn.

Member Avatar for Ancient Dragon
0
114
Member Avatar for depsch

In C++ functions can have parameters with default values [code] int Test ( int a = 1, int b = 2) { return a * b ; } [/code] now when the program calls Test with no parameters, the compiler will force them to the values shown above. [code] int …

Member Avatar for Ancient Dragon
0
59
Member Avatar for B.H

it always helps to post the code that does not work. and please use code tags as explained in the threads at the top of this board.

Member Avatar for Ancient Dragon
0
75
Member Avatar for redstar

1. Please edit your post to use[URL="http://http://www.daniweb.com/techtalkforums/announcement8-3.html"] code tags [/URL]to preserve spacing and tabs. 2. main() must be declared like this: [code] int main() { // blabla return 0; } [/code] I realize neither of the above answer your questions, but fix those and we will look at your post …

Member Avatar for Nick Evan
0
278
Member Avatar for The Dude

[QUOTE=proliant_fan;260738] how old r u when ur in the 8th grade (im in the uk)[/QUOTE] about 13 or so -- and its been 50 years since I was in 8th grade :mrgreen:

Member Avatar for xyfay
0
160
Member Avatar for lol_hacker101

[QUOTE=lol_hacker101;254131]a minute? pitiful..you call yourself a moderator? whatever the heck that is? lol_hacker101[/QUOTE] A Moderator is someone who likes to answer other people questions or silly comments, such as yours.:)

Member Avatar for lol_hacker101
0
153
Member Avatar for dick28

welcome to DaniWeb -- and happy to find someone my own age group.:mrgreen: Hope to see you around these forums a lot. And enjoy that grandson as much as you can, as you know they grow up so fast. I live only a couple hours drive from you so maybe …

Member Avatar for jbennet
0
79
Member Avatar for GreenDay2001

1. step #1 -- go to Add/Remove Programs and remove that old ancient compiler from your computer. 2. Setp #2, to do Microsoft Web site and download VC++ 2005 Express and the Windows Platform SDK.

Member Avatar for WaltP
0
104
Member Avatar for nikki100

we certainly cannot accuse him of talking too much :mrgreen:

Member Avatar for ~s.o.s~
0
18
Member Avatar for Mouche

Welcome to DaniWeb -- I don't know a thing about Pyhthon so I can't help you at all with that. Hope you have enjoyable experience here.

Member Avatar for ~s.o.s~
0
74
Member Avatar for Gessa

Please use [URL="http://www.daniweb.com/techtalkforums/announcement9-3.html"]CODE TAGS[/URL] All that unformatted code hurts my eyes and greatly reduces the probability that anyone will help you. Also [URL="http://www.daniweb.com/techtalkforums/announcement8-2.html"]we do not do student's homework[/URL].

Member Avatar for Gessa
0
82
Member Avatar for friendz_

read the stickies at the top of this form -- that contains lots of information and links, for example t[URL="http://www.daniweb.com/techtalkforums/thread50370.html"]his one[/URL]

Member Avatar for Ancient Dragon
0
54
Member Avatar for hariza

use the escape sequence character. and to get the '' you need two of them [code] sep = strpbrk(line, "\\<=->/'\""); [/code]

Member Avatar for hariza
0
549
Member Avatar for lalalu

that is the right syntax, but it does not allocate enough memory because [b]array[/b] inside the allStatus structure is an array of pointers and each of them must be malloc'ed as well. [edit]Sorry Glorious -- your post was not there when I started writing the above[/edit]

Member Avatar for lalalu
0
989
Member Avatar for kathy78

my quess is Expr1Column is the name of a function, if that is correct then you need to add the parentheses [code] if (LogInfo.Expr1Column[color=red]()[/color] > 0) [/code]

Member Avatar for peterbyrne
0
85
Member Avatar for jordan2005

read the stickies at the top of this board -- they will give you lots of information and links. and Welcome to DaniWeb. Please visit Coffee House and introduce yourself.:)

Member Avatar for Ancient Dragon
0
101
Member Avatar for highlanda

I think you will want to investigate [URL="http://www.calculator.org/RPN.html"]Reverse Polish Notation[/URL] as it is applied to calculators. google has lots of information about it.

Member Avatar for andor
0
103
Member Avatar for Utkarsh Kukreti

maybe [URL="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_wrcore/html/wrwlkwalkthroughusingcomboboxtochangeformattinginworddocument.asp"]this[/URL] microsoft tutorial will help???

Member Avatar for Inanna
0
105

The End.