5,676 Posted Topics

Member Avatar for royaloba

Read each line If it contains "[I]Event:Access, Door:entry, Card No.[/I]", write it to the file If not, don't If not at end-of-file, go back to read the next line

Member Avatar for WaltP
1
472
Member Avatar for Gigs_

[quote=Gigs_;251639]What are something.X files and how to edit them? Thanks![/quote] Don't know. And if you don't know, why would you want to edit them?

Member Avatar for ~s.o.s~
1
96
Member Avatar for bobeagle

[quote=bobeagle;250946]But it still doesn't work for me. I'm just a freshmen. I set up a blank workplace, then win32 application project, then a c++ cource file. Then type as below: #include <iostream> void main() { std::cout <<"welcome" <<std::endl; } No matter I use "main" or "WinMain" in the second line, …

Member Avatar for GloriousEremite
1
161
Member Avatar for charter

That depends. Since we don't know what websites you're talking about, we can't tell. It could be a couple things. One way to find out is view the source of the page you're interested in. Sometimes there's information there on what they did.

Member Avatar for FC Jamison
0
95
Member Avatar for vinay raja
Member Avatar for WaltP
0
574
Member Avatar for promiscuoustx

Wow! A first time poster that used code tags!!!! Thank you ! [inlinecode]while (iResponse = 0) {[/inlinecode] sets [I]iReponse[/I] to 0, which by definition is FALSE and the loop does not execute. == maybe? [inlinecode]getch()[/inlinecode] is not standard and should be avoided. Use [inlinecode]getchar()[/inlinecode] instead. And the bottom of your …

Member Avatar for WaltP
1
957
Member Avatar for smagee12
Re: glut

[quote=~s.o.s~;250798]Why not try to make the variable persistent throughout the program by declaring it as global static variable ? [/quote] [quote=Anonymusius;250740]You can best (I think) make an global variable or an automatic variable in main called counter and then add it if the button is pressed. [/quote] No, you shouldn't …

Member Avatar for ~s.o.s~
1
122
Member Avatar for the.future.zone

Most games are written using the C family. You just need the graphics packages.

Member Avatar for mostafadotnet
0
76
Member Avatar for becki

[quote=Lutzee;250112]Hey this problem is too simple to implemented in an objecft oriented way. Programs this small do not need to have good programming practices. Especially if teyt are just for fun. For somthing this small it only matters if it works IMO. [/quote] Well said, if all you want to …

Member Avatar for WaltP
1
190
Member Avatar for comp_sci11

[quote=Ancient Dragon;249706]probably because [URL="http://www.cs.colorado.edu/%7Emain/cs1300/doc/bgi/bgi.html"]BGI[/URL] requires a 32-bit compiler, which TurboC is not. Upgrade to one of the free compilers mentioned in that link.[/quote] Just the opposite. I was using BGI back with Turbo C++ 1. Download from Borland: [URL="http://bdn.borland.com/article/21751"]Turbo C++ version 1.01[/URL] [URL="http://bdn.borland.com/article/20841"]Turbo C++ version 2.01[/URL] Other old Borland stuff …

Member Avatar for ~s.o.s~
2
168
Member Avatar for lover99509

Look under your menus for "[I]Package and Deployment Wizard[/I]". This will create an installation package that will install you rprogram on the destination computer.

Member Avatar for purplegerbil
0
125
Member Avatar for bh_hensem

[quote=bh_hensem;249429]the problem is how could i store the current record in the variable ? Can you give some example ? I have tried it before but the previous input have been overwrited...[/quote] Did you read in the current record? Is it still in the variable space? If so, move it …

Member Avatar for Bench
1
155
Member Avatar for VinC

You've mostly got it. Each C 'string' ends in a character value of 0. That's what your "out of bounds" is really checking, really it's "end of string. Commented (and formatted properly) [code]int find_ substr( char *s1, char *s2) { register int t; char *p, *p2; for( t= 0; s1[t]; …

Member Avatar for VinC
1
127
Member Avatar for Wreef

Instead, figure out how to compile it without the need for the Framework. Then it can run on any Windows computer, with or without .NET

Member Avatar for tgreer
0
263
Member Avatar for the.future.zone

VB is only for PC apps, therefore C. But stick with Standard C/C++ and avoid compiler-specific functions that cannot be used with other compilers. If you want a VB-like language that is cross-platform, look into Real Basic ([url]http://realbasic.com/[/url])

Member Avatar for Rashakil Fol
0
126
Member Avatar for VinC

[quote=mostafadotnet;247868]Hi VinC,[I][quote]system("pause");[/quote][/I]Use instead.[/quote] No, don't. Learn your tools. Using [inlinecode]scanf()[/inlinecode] to read characters is even worse than using [inlinecode]gets()[/inlinecode] because not only does it allow you to blow your buffer boundaries but as you can see it also leaves your input stream dirty. The \n is left in the stream …

Member Avatar for Bench
0
426
Member Avatar for grunge man

[quote=grunge man;246061]Ok im learning how to do exponents in c++ and I get most of this, but I dont get what double means. I do however know what float is. [/quote] It simply means that the storage space (number of bytes) in a [I]double[/I] is twice the storage space of …

Member Avatar for dwks
0
249
Member Avatar for insamd

I think some major clarificarion is needed. [quote=insamd;245897]I was wondering if anyone can help me in terms of using atoi to get my my results to add the 1's of my binary output and then join them together... eg. 110101 and 100101 is 4 and 3 = 43. [/quote] Do …

Member Avatar for insamd
0
393
Member Avatar for akadri

[quote=aeinstein;245209]In this [URL="http://www.daniweb.com/techtalkforums/thread46884.html"]thread[/URL] WolfPack provide me a link to the [URL="http://www.digitalmars.com/ctg/sc.html"]online reference manual[/URL] for the [URL="http://www.digitalmars.com/ctg/sc.html"]free Digital Mars Compiler[/URL] that I'm using - which I've found easy to use.[/quote] I have never actually used the Digital Mars compiler, but I have never heard anything good about it. I think you'd …

Member Avatar for WaltP
1
261
Member Avatar for scoobie

[quote=scoobie;246760]i am using a program that gets run through a windows command prompt and outputs the result to the command line screen by default. i was trying to get it to output the results to a .csv file injstead but i have no idea how to do this. [/quote] You …

Member Avatar for Salem
0
124
Member Avatar for degamer106

[quote=degamer106;245418][code]#include <stdio.h> struct FUN { char x; char *y; int z[20]; }; int main(void) { struct FUN fn1; struct FUN fn2; struct FUN fn3[10]; struct FUN fn4[50]; return 0; }[/code] is an assignment like fn4[23] = fn3[5] invalid?[/quote] What happened when you tried it? ;) Set up a function to …

Member Avatar for himanjim
0
141
Member Avatar for SHWOO

It might be easier to accumulate the pay with [code] set totalpay to hours * straighttime // this will include ALL hours worked subtract 8 from hours to get all overtime // time+half and double add to totalpay hours * time-and-a-half // IOW 1/2 of straighttime subtract 2 from hours …

Member Avatar for WaltP
0
242
Member Avatar for hay_man

[quote=WolfPack;246214]Use [URL="http://www.cppreference.com/cppstring/substr.html"]std::string::substr()[/URL]...[/quote] to break the string into 4 strings of 4 characters. Store them in a string array (or 4 variables if you don't know arrays). Then work with each of the 4 strings.

Member Avatar for Grunt
0
157
Member Avatar for hay_man

[quote=hay_man;245985]Hope you can help. The following is essentially a small problem of an overall project, i have been trying to work out how to divide an inputted string, into say blocks of 4 characters and then output these separate blocks on the screen. e.g. 1234567891234567 ----> 1234 5678 9123 4567and …

Member Avatar for Ancient Dragon
0
235
Member Avatar for grunge man
Re: ????

I haven't read any of your posts to see what the problem is but it seems to me that if you are 1) Posting your code properly formatted 2) Using code tags 3) Explaining what is going wrong in understandable detail 4) Explaining what the code should do in understandable …

Member Avatar for Bench
0
290
Member Avatar for s s paul

Since [i]word[/i] is defined as 5 characters, and you enter "hello", the \0 at the end overwrites memory outside your string. Try increasing the size of [i]word[/i] for starters.

Member Avatar for Dave Sinkula
0
155
Member Avatar for jubleebow

[quote=jubleebow;245338]Hey guys, in matlab when u do a loop(something like this): [COLOR=red]for i=1:3[/COLOR] [COLOR=red]a= 2*i[/COLOR] [COLOR=red]end[/COLOR] You get a=2 a=6 a=9 any idea how do i assign the 3 answers(a) names so that i can calculate the product of all 3 answers?[/quote] Maybe: [code] [COLOR=Black]a = 0 [/COLOR][COLOR=Black]for i=1:3 [/COLOR] …

Member Avatar for WaltP
0
129
Member Avatar for the.future.zone

When a function is finished, the final statement in the funct can be something like [inlinecode]return x;[/inlinecode] [B]x[/B] is the value returned into the variable. Example: [code] val = add(a, b); // add A and B ... int add (int x, int y) // define the add function { int …

Member Avatar for WaltP
0
46
Member Avatar for sdybc

[quote=Micko;245275]Please add system("pause"); at the end. So it should loook like this: [code] ... exit (0); } system("Pause"); } [/code][/quote] No, don't. There is no need to call the operating system when the languave itself can pause the program by simply doing a [inlinecode]cin[/inlinecode] statement. The assumption here is the …

Member Avatar for WaltP
0
128
Member Avatar for the.future.zone

[quote=the.future.zone;244993]Hello everyone. What languages are being used for instant messaging? [/quote] I use English, personally :D

Member Avatar for WaltP
0
57
Member Avatar for Smoke

[url]http://www.borland.com/downloads/download_cbuilder.html[/url] for Borland 5.5 [url]http://www.bloodshed.net[/url] for Bloodshed DevC

Member Avatar for WaltP
0
79
Member Avatar for dannyfang

[quote=Deacon J]I didn't resurrect it...I just answered t. Don't shoot the messenger.[/quote] What makes you think [B]DMR[/B] was talking specifically to you? "Hello People" was the post salutation. The others [I]could[/I] be people, too. :)

Member Avatar for Dave Sinkula
0
334
Member Avatar for ammu117

[quote=ammu117][COLOR=magenta]For professional development which is the best compiler? DevC++ or Turbo c++? [/COLOR][/quote] Neither, really, if you are developing professional on the job code. But if you are learning to code, [URL="http://www.bloodshed.net"]Bloodshed DevC[/URL] or [URL="http://www.borland.com/downloads/download_cbuilder.html"]Borland 5.5[/URL] command line is good for the beginner. Both can create professionall programs, they just …

Member Avatar for Grunt
0
139
Member Avatar for med7at7egazi

How many freakin' forums are you spamming with the same lame post?!?! Once is enough, you don't need po make 10 posts all over the place!

Member Avatar for WaltP
0
314
Member Avatar for muhammad_owais

Have a variable that holds the item number. Every time the ADD ITEM button is pressed, increment the item number and load the number into the text box. Make the text box 'Enable=FALSE' and it can't be edited.

Member Avatar for WaltP
0
125
Member Avatar for sdybc

And... Are we supposed to read your entire program, figure out what's missing, and add it for you? Shouldn't you maybe [I]tell us[/I] what you're completely lost about? What doesn't work, and where the specific area is in the code you posted?

Member Avatar for WaltP
0
113
Member Avatar for tln26

Where is the loop that allows [inlinecode]cin>>final[count++];[/inlinecode] to accept more than one value? Because of the [B];[/B] on the line [code]while(count<10 && (reply)=='y');[/code]you have here an endless loop. [I]count [/I]and [I]reply [/I]are never allowed to change. It would also help if you start indenting you code properly so you can …

Member Avatar for tln26
0
121
Member Avatar for VBWayne

[quote=VBWayne]I've created the following series of If statements that are totally disfunctional. I'm thinking it has to do with my lack of understanding between a function and a statement. (I'm an old mainframe programmer and sometimes have difficulties crossing over) Even though when I do a watch on the fields, …

Member Avatar for VBWayne
0
289
Member Avatar for taha54
Member Avatar for WaltP
0
1K
Member Avatar for ze_viru$

My preferred solution: [code] #include<iostream> using namespace std; int ReadInputFlava (); int ReadInputCart (); int main() { int flava,cart,delivery; flava = 0; cart = 0; cout<<" Mulaudzi Ice-Cream Limited\n" <<" --------------------------\n"; flava = ReadInputFlava(); cart = ReadInputCart(); cout<<"Ur flava is : "<<flava<<endl; cout<<"Ur # of cartoons is : "<<cart<<endl; return …

Member Avatar for Grunt
0
402
Member Avatar for degamer106

[quote=degamer106]Hi. I can't a small part of this program to work correctly; the square root function either returns a bunch of funny symbols OR it returns 0.00[/quote] Split the statement into two. Print the value that goes into the sqrt() function to see it's value, then call the function. If …

Member Avatar for degamer106
0
166
Member Avatar for SamY
Member Avatar for INI

[code] If NOT [B]isNumberic[/B](Textbox1.value) then Msgbox("Sorry you must only put numbers") else end if [/code]

Member Avatar for Comatose
0
148
Member Avatar for p_eqlz_np

If these are actual formulas: [quote=p_eqlz_np] Groups of Groups GG1 - (G1 && G2) || G3 GG2 - (G2 || G3) && (G1 && G4) GG3 - (G1 && (G2 || G3)) || G5 [/quote] then GG1 = G3 GG2 = 0 GG3 = G5 [quote=p_eqlz_np]Now I want to be …

Member Avatar for Rashakil Fol
0
146
Member Avatar for cyan033

The first problem I see is you defined a pointer [I]bin[/I] but you never created space for it. A point simply points to space, yours points nowhere so your binary characters are going somewhere you really don't want them to. Second problem is [inlinecode]strrev()[/inlinecode] is not a standard function. You …

Member Avatar for dwks
0
146
Member Avatar for Rosicky

[quote=Ancient Dragon]if you don't know where to start, here's a hint[/quote] You forgot the return: [code] int main() { // put your code here return 0; } [/code]

Member Avatar for ~s.o.s~
0
148
Member Avatar for jubleebow

Create the filename as a string value and use the string instead to open the file.

Member Avatar for WaltP
0
87
Member Avatar for cgerber

And, [inlinecode]cout[/inlinecode] is the C++ output command, not [inlinecode]printf()[/inlinecode], so you don't need [I]stdio.h[/I] any longer.

Member Avatar for WaltP
0
106
Member Avatar for dilip.mathews

I would put this under "undefined behavior" and assume defining [B]a[/B] to be [B]b[/B] then [B]b[/B] to be [B]a[/B] to be a bad practice. Therefore I would abandon the concept of understanding what the compiler would do and move on to a different problem -- one that makes sense... Just …

Member Avatar for WaltP
0
228
Member Avatar for comp_sci11

[quote=WolfPack]But use DevCPP at home. Maybe code that works in DevCPP will work in TurboC, although not the otherway around (not sure about that but stick with code that works in DevCPP as much as possible). [/quote] As long as standard C is used, Turbo and Dev are compatable. There …

Member Avatar for Ancient Dragon
0
155

The End.