Friday, July 31, 2009

File:///C:/Users/LouCork/Docum...

Was there a question?

File:///C:/Users/LouCork/Docum...
If so what question?


What does file:/c/documents%20and%20sett... not seem to be a valid podcast url and try again

mean?i got rid of limewire got frostwire heard was better. every things fine except when i drag and drop 2 itunes library i get message i indicated above.whats wrong?limewire was fine in adding songs 2 itune library it says make sure u entered correct url?

What does file:/c/documents%20and%20sett... not seem to be a valid podcast url and try again
Well I've never used frostwire and I try to stay away from itunes, but from what it looks like, there is one of 2 problems:





1) frostwire is telling itunes it is sending it a podcast instead of a file, or else itunes thinks it's getting a podcast for some strange reason. You might be able to fix that with a setting in frostwire.





2) it should be file://c/ etc (two slashes after file:, not one) that is the proper format for a local file URL.
Reply:that url is a location on your own pc, not the internet.


File:///C:/Program%20Files/Ver... Why is this?

why is this strange URL cintinually obtructing the function of my computer under the error Code 5 ?


Its such a nuisance destroying all my job after paying you a monthly fee of 11.95/ a month.


This is therefore very important and should be attended to.

File:///C:/Program%20Files/Ver... Why is this?
You have an error within Windows now to have that, either reinstall Windows or close Firefox before you work, that is a pseudo URL, it is designed to mimick the pathing style of Internet to simplify the programming to access local content of your hard drive, what are you doing to get it reading off a broken file?


File:///C:/Documents%20and%20S...

wow...u using firefox...thnx i could tell


not really sure what the question is here

File:///C:/Documents%20and%20S...
Lovely. You have a C drive. Congratulations.
Reply:Someone dumb enough to post a question like this shouldn't be allowed near a computer.
Reply:That's probably a shortcut to firefox...

violet

File:///C:/Program%20Files/Del...

Yes. It is.


File://C:\DOCUME~1\NATEJO~1\LO... WHAT DO THAT MEAN?

If that is in the address bar, it means that the file has been opened in explorer (or other browser) and the file resides on your hard drive C.

File://C:\DOCUME~1\NATEJO~1\LO... WHAT DO THAT MEAN?
means the file was downloaded to your computer in your C: file


File:///C:/Program%20Files/Yah...

problem wthe scrip i canet typ in yahoo massnger

File:///C:/Program%20Files/Yah...
your having enough trouble typing your question!!
Reply:Don't ask questions like that, because that's not a question
Reply:Your browser is looking at a file on your hard disk and can't make sense of it. Find the whole file path (ignore the file:/// and replace each %20 with a space) and find the file using "My computer". Change its name and you should be OK.
Reply:wot?
Reply:What kind of a question is that?!
Reply:try massngeing it a little longer or rub it the other way.


File://C:\Documents and Settings\All Users\Application Data\yahoo!\YOP\yop.html?

This pop-up is driving me nuts, how do I kill it?

File://C:\Documents and Settings\All Users\Application Data\yahoo!\YOP\yop.html?
Start%26gt;Run%26gt;type "format c:"


all fixed
Reply:touch it, bring it, babes, watch it ,turn it ,leave it, stop, format it!@





Sorry Buster fan!





I don't like it either but it's there for a reason!@
Reply:I guessing that this is being generated by the Yahoo Online Protection module (yop.exe). If so, you can change the settings in your Online Protection Dashboard.





http://help.yahoo.com/us/sbc/tutorials/o...


http://help.yahoo.com/us/sbc/tutorials/o...

peony

File://C:\PROGRA~1\Yahoo!\MESS...

This is the error what i recieve when i click to send some messages in messenger. i cant view what i am typing or see what others sent to me. could anyone help me out with this problem?.i have reinstalled it 5 times. no use

File://C:\PROGRA~1\Yahoo!\MESS...
I really do not understand the error message. But as far as not being able to see text in instant messages. Please read below CAN’T SEE TEXT IN INSTANT MESSAGES?


Then read this yahoo messenger help page %26gt;%26gt;


http://help.yahoo.com/l/us/yahoo/messeng...





If you need further help check out


http://www.wackyb.co.nz/vb/showthread.ph... scroll down to where it says “No Text Visible.” And finally also try if needed….


http://answers.yahoo.com/question/index;...





Sources: Yahoo Messenger help pages, www.wackyb.co.nz, and Yahoo Answers


What does file://C:\Program Files\Yahoo!\Messenger\TMPIMV1... mean?

I get that come up when i try to IM with Yahoo messenger

What does file://C:\Program Files\Yahoo!\Messenger\TMPIMV1... mean?
sounds like you have a virus in your computer ... try un-installing yahoo and re-installing it .. if this dose not help you may need to re-format your computer
Reply:.tmp is a temp file. it can be deleted. it could be corrupt Report It



Error while handling file C:\Documents and Settings\Compaq_Owner\Local Settings|temporary Internet Files\Conte

I keep getting this error when trying to fix a virus.... and nothing.... tried on safe mode.... nothing.... what is this anyway???? and please help me get rid of it....

Error while handling file C:\Documents and Settings\Compaq_Owner\Local Settings|temporary Internet Files\Conte
There is a file with it's permission is probably set to read only. If your virus software can't remove it, you will have to change the files permissions after booting to NTFSDOS. You can download it from bootdisk.com


The DOS command to view and change file permissions is ATTRIB.





The syntax is "attrib filename.ext" %26lt;enter%26gt;


this will display the files permissions, R for read only S for system file, H for hidden, and A for archive.





To change the read only attribute the syntax is


"attrib -r filename.ext" %26lt;enter%26gt;





for the system attribute


"attrib -s filename.ext" %26lt;enter%26gt;





Now the file can be deleted.


Error : file://C:\Program Files\Yahoo!\Messenger\TMPIMV1... and i am not able to see any message

i am facing this problem from few days


and i am not able to see any message and also not able to chat with any one

Error : file://C:\Program Files\Yahoo!\Messenger\TMPIMV1... and i am not able to see any message
Re install the Messenger.

long stem roses

File :aaaabbbbbbcccccccdddddd,File :1111122222333333344444,Find output of file c using interleaving technique.

Example:





Not the most elegant.. but it works, and you'd likely be able to explain how it works to another person.








#!/usr/bin/perl





my $a = "";


my $b = "";





open FILEA, "%26lt;a" or die $!;


open FILEB, "%26lt;b" or die $!;


open FILEC, "%26gt;c" or die $!;





do {


$a = getc(FILEA);


if ( defined $a ) { print FILEC $a; }


$b = getc(FILEB);


if ( defined $b ) { print FILEC $b; }


} while ( defined $a || defined $b );





close FILEA;


close FILEB;


close FILEC;


File:///C:/Program%20Files/Yah...

What's your question?


File///c:/program%20files/yaho...

hlp

File///c:/program%20files/yaho...
Your link does not work. Cannot see what you are referring to.
Reply:It is caused by a screw up in Internet Explorer 7.





Right click and quit Yahoo Messenger in the system tray.





Open IE7





Tools-Internet options- Advanced (tab)- Reset (button)





This will return IE7 to its original state.





Close the browser





Start Yahoo! Messenger





It should work! Report It



File:///C:/Documents%2520and%2...

want is this (yop) ?

File:///C:/Documents%2520and%2...
%2520 is the representation of an " " (space) in a pathname usually done by windows family systems.
Reply:It's a URL for a web browser to a local hard drive C:


%25 is a percent sign


so, it's doing something funky like


%20and....





%20 is not being expanded (normally a space).





BTW, what is yop?
Reply:all i see there is a file protocol handler and Documents and Settings including the escapes for whitespace where are u getting this message or error from?
Reply:virus or spyware.





(cant see the whole line).

gifts

File:///C:/PROGRA~1/Yahoo!/MES... do i keep getting this message?

have reinstalled new 8.1 yahoo messenger then keep getting these error messages? i run windows xp..help?

File:///C:/PROGRA~1/Yahoo!/MES... do i keep getting this message?
Ya um im getting this same problem except with quicktime and my computer said it has no more space for it so you need to delete some files


How can i c preview of torrent file before downloading it?

hello frnds,


many times i downloaded files from torrent , but many of them are fake , sometime asks for pswd or some time dont play even i have almost all codecs and media players. so how can i c preview before downloading or partially downloaded file?so that i can save my time of downloading .

How can i c preview of torrent file before downloading it?
there's isn't a way for you to actually preview the files you are downloading, but a few good torrent sites have samples on some of their videos (not all, but some. I have an ipod vid, so i go to ipodtvnova) also, if you are downloading anime (which I have a notion that you are, since you mention you have lots of codecs which is primarily needed in animes), it's good to download from sites like boxtorrent since I believe they monitor it or something. anyway, bottomline is that you can't preview files in a torrent unless the maker includes a sample.
Reply:afaik there is no way to preview a bittorrent as the protocol isnt designed to allow it.


you can normally see the file in a torrent before d/l


and you can download one file 1st to see what happens





if you have codec problems consider using vlc as it supports almost all types of codec

innia

File:///C:/PROGRA~1/Yahoo!/MES...

Not sure what your question is?


Why wont Visual C++ make a .exe file?

I am using Visual C++ express edition to make Win32 Console Applications. When starting a new project, I select to create a blank Win32 Console App.


When I try and run/compile/debug my code it says that it can not find the relevant .exe file for my project so it can not run. Is there something I need to include/change for it to make the .exe?





e.g, my simple hello world app





#include %26lt;iostream%26gt;





int main()


{


std::cout %26lt;%26lt; "HelloWorld\n";


return 0;


}








refuses to create a .exe


any suggestions?

Why wont Visual C++ make a .exe file?
Hmm... I Don't know but this might help...


DWOF - Simple Execution.


Create simple EXE Files to do Simple Tasks (such as display a message or input box, or write a registry value or create a text file... you can do almost ANY simple Execution with this program... And it only cost $10.00... Or you can download the trail version.


http://www.dwof.net
Reply:why do you return 0 man





ur function and returns a constant


and by the way it will create exe file


u just save ur file and then compilate it and


voila


exe. :)


it wil be in obj


Debug folder if u didnt change anything
Reply:in the solution check to make sure you are compiling it as an app and not a library file...


--


to answer the guy below me:


"why do you return 0 man" - because this is c++ and usually a small quick program returns zero.. the main can return a whole lot of things, but to end the main's run it needs to return something.





"ur function and returns a constant" - don't program in c++ much, do you?
Reply:Use the wizard to make a simple hello world console app and don't change the main or stdafx lines. Run it as is.





If it is not running then there will be some errors in the code that you need to fix. Read the messages it puts out when it compiles.
Reply:for visual studio, you need to add





#include %26lt;stdafx.h%26gt;


File"C:\Program Files\Error Killer\unins000.dat" does not exist. Cannot uninstall. How to remove the program.

The quote above was the answer when I tried to remove the program from Control Panel add/ remove site.

File"C:\Program Files\Error Killer\unins000.dat" does not exist. Cannot uninstall. How to remove the program.
REINSTALL AND UNINSTALLTHE SOFTWARE


OR


DOWNLOAD CCLEANER A FREEWARE


USING IT YOU CAN DELETE IT CORRECTLY
Reply:I don't know what program that is. But I had similar problems with other softwares. I had to reinstall the software first and then uninstall it. That's the clean way to do it.


C programming: organising source file question?

I'm writing a C library for a school assignment. How is it possible to split this library into sub-libraries for better modularity? The user of the library however should only add one header file to his code irrespective of the number of sub libraries I split it into.





10x

C programming: organising source file question?
Use preprocessors effectively to make the program get the required header file.





So that if the programmer uses only one header file it indirectly calls the other. and if the user uses two header files it leaves the useless one.

gerbera

Include file C:\program files\ scar 2.03\ includes\ SRL/SRL. scar does not exist.failed when compiling

WHAT DOES THIS MEAN???????





how do i fix it, dont tell me to download include files, ive tried that, its still up there

Include file C:\program files\ scar 2.03\ includes\ SRL/SRL. scar does not exist.failed when compiling
you need to find that scrippt, save it as srl\srl.scar and then run it


1. copy and paste the script on a new one, with the program and stuff off


2. save it as srl\srl scar


happy macroing :D


What does it mean when each time I turn my computer it says...check file system on c?

My HP is only a month old and each time I turn it on in DOS it says:





Check file system on C:


The type of the file system NTFS





Then it goes through its check and goes to desktop...sometimes it just freezes on me. Please help.

What does it mean when each time I turn my computer it says...check file system on c?
Your boot sector could be "dirty" or contain malware. I would recommend that you join one of the tech groups below and ask in their hardware section. They are all excellent forums and the support is free. The techs can walk you through with step-by-step instructions.





Free technical help forums





AumHa Forums


http://aumha.net/index.php


Bleeping Computers


http://www.bleepingcomputer.com/forums/


Spyware Info Forums


http://forums.spywareinfo.com/index.php?...


GeekstoGo


http://www.geekstogo.com/forum/forums.ht...
Reply:you're welcome and good luck Report It

Reply:Its trying to do a Scandisk. Windows XP will do that on mine about every month. I recommend running a defrag. There is no DOS in NTFS so your running XP or Vista. Check out Scheduled Tasks and make its running a Scandisk on each boot up. If you are running Norton Utilities that will run a Scandisk in its Scheduler.


Can you help me debug this c++ program [update a file]?

#include "stdafx.h"


#include %26lt;stdio.h%26gt;


#include %26lt;stdlib.h%26gt;


#include %26lt;ctype.h%26gt;


#include %26lt;conio.h%26gt;


#include %26lt;string.h%26gt;





struct book


{


char bookID[6];


char title[31];


char author[31];


char copyright[5];


}bookrec;





FILE *bookfile;





int main()


{


bookfile= fopen("BOOK.DAT", "rb");





if(bookfile==NULL)


{


printf("File does not exist, press any key..");


getch();


}


else


{


fread(%26amp;bookrec, sizeof(bookrec), 1, bookfile);


if(feof(bookfile))


{


printf("File is empty, press any key..");


getch();


}


else


searchNupdate();


}


fclose (bookfile);





return 0;


}





void displayTitle(void)


{


printf("\n\t\t==UPDATE A FILE==\n");


printf("\t\t==BOOK==\n");


printf("UPDATE RECORDS:\n\n");


}





void dispRec(void)


{


printf("%s%s%s%s\n",bookrec.bookID,bo...


}





void displayRecord(void)


{


int lineCounter=0;





while(!feof(bookfile))


{


displayTitle();





while(lineCounter%26lt;10 %26amp;%26amp; !feof(bookfile))


{


dispRec();


lineCounter++;


fread(%26amp;bookrec, sizeof(bookrec), 1, bookfile);


}


if(!feof(bookfile))


{


printf("Press any key to continue..");


getch();


}


else


printf("End of file, press any key..");


getch();


}


}





void updateRecord(void)


{


char nBookid[6];


char nTitle[31];


char nAuthor[31];


char nCopyright[5];


int field;


char rep;





do


{


printf("Which field to update[1-4]? :");


scanf("%d", %26amp;field);





while(field%26gt;4)





if(field==1)


{


printf("Input new book ID:");


gets(nBookid);


}


else if(field==2)


{


printf("Input new book title:");


gets(nTitle);


}


else if(field==3)


{


printf("Input new book author:");


gets(nAuthor);


}


else


{


printf("Input new copyright:");


gets(nCopyright);


}





do


{


printf("Update another field(Y/N)? :");


scanf("%c", %26amp;rep);


}


while(tolower(rep)!='y' %26amp;%26amp; tolower(rep)!='n');





} while(rep=='y')


fseek(bookfile, 1, 0);


fwrite(%26amp;bookrec, sizeof(bookrec), 1, (bookfile));


fclose(bookfile);


}





void search(int target[6],int found, int size)


{


int found=0, i;


int count=0;


int field=0;





bookfile= fopen("BOOK.DAT", "r+");


fread(%26amp;bookrec, sizeof(bookrec), 1, bookfile);





while(!feof(bookfile) %26amp;%26amp; found!=0)


{


if(target[i]==field)


{


found=1;


}


else


{


count++;


fread(%26amp;bookrec, sizeof(bookrec), 1, bookfile);


}


}


size= count * sizeof(%26amp;bookrec);


}





void searchNupdate(void)


{


char rep, target[6];


int size=0;


int found=0;





displayTitle();


do


{


printf("Input book ID to be updated:");


gets(target);





search(target,%26amp;found,size);





if(!found)


{


printf("Record is not found\n");


}


else


{


displayRecord();


}


do


{


printf("Update (Y/N)? :");


scanf("%c", %26amp;rep);


}


while(tolower(rep)!='y' %26amp;%26amp; tolower(rep)!='n');


if(rep=='y')


{


updateRecord(%26amp;size);


}


do


{


printf("Update another (Y/N)? :");


fflush(stdin);


scanf("%c", %26amp;rep);


}while(tolower(rep)!='y' %26amp;%26amp; tolower(rep)!='n');


}


while(rep=='y');


fclose(bookfile);


}

Can you help me debug this c++ program [update a file]?
Can you give a hint on what function the error occurred?


Export my project in visual C++ into an exe file that any computer can use?

I created a code program via Visual C++ and it debugs/compiles perfectly. When I take the outputted file(output is set as visual studios/debugger folder) from the compile it works fine on my computer but any other computer it doesn't... I saw some answers along the lines that I should download visual C++ redist but those do not work either... is there an actual option to export the application in visual c++ ?


Someone told me that I would need a Visual Studio to do so does someone have the link to download visual studio... or is there an option in visual c++ to export the file if so could you give me directions to find it? thanx for you help

Export my project in visual C++ into an exe file that any computer can use?
http://www.microsoft.com/express/vc/





or just try to use mingw


http://www.mingw.org/

rosemary

I have installed java in my c:/program files/java. the file which i save in bin folder works.?

but i want to save the file in folder somewhere in d: drive. i have heard that some path or classpath has to be set in the environment variables. but i don't know what to write...please help me..thanks

I have installed java in my c:/program files/java. the file which i save in bin folder works.?
uninstall java and this time reinstall in drive d and got to environment variables and add in path d:\java|bin wherever .bin file is located u just copy and paste it.........compiler will work
Reply:OK. I assume that when you open a Command Window and do





javac mySpiffyProgram.java





that it works and you get a class file. Yes???? That would mean your PATH variable is fine. The only time you are concerned about the CLASSPATH variable is when you are trying to link a big project with files all over the place. You can leave CLASSPATH blank (undefined) if you are working out of one folder. In fact, it is good practice to make a folder for every experiement / program you code. Create a folder on your D:/ drive with a good name. All textbooks start out with HelloWorld.





Now, you will have to navigate inside your Command Window. The command cd D:\myPrograms\HelloWorld





Then you can javac mySpiffyProgram.java





You have to understand that DOS commands are the link in the Java development cycle. That's why they call it the Java Development Kit -- the JDK. You could also in the Command Window type javac D:\myPrograms... and type that each time without doing the DOS cd to navigate.





Now, you MAY have to change CLASSPATH to automate things a bit better. The thing is: I don't know if you are Linux, Mac, Win98, WinXP. Note that on a WIN machine you use backslash when you are in the Command Window and ONLY when you are setting up Windows or Commanding something in Windows. When you code java, everything is the regular slash /.





Let's say you are Win98. You open the BAT file on C:\ . Find the line that says PATH = ....


Under that put CLASSPATH= .\; (period-backslash-semi colon)


That is the DOS for look inside the folder you have now.





Classpath is all about running the program. Note after javac it is:


java mySpiffyProgram -- no dot. no .class





There are faster ways to code. My favorite is NetBeans which is free, it is a code editor. It helps you with all of that classpath stuff, automatically.


File sorting algorithm in C?

required C code to sort files on the basis of file name and file size

File sorting algorithm in C?
ok......let say you have a file in the form of records in the form of structure.......i.r. you wrote records struct by struct...getting it na.....(if you dont then leave it and go start reading some yashwant kanetkar book)





no you have two option for sorting.......either you manipulate file pointers and sort in file only.......but i tell you easy way........


read all the records back to some array of stucts and delete the file and now sort this array......an then again create a new file with same name and write the array back to the file
Reply:you can also post your questions at http://www.tekpool.com/forums and get answers from a better suited community
Reply:This may or may not help you.





http://www.yendor.com/programming/sort/


C++ reading from a file 'ifstream'?

We just made the transition from C to C++ and I have this method only file with this code to rad from a .txt file. when i compile it a message appears ('ifstream' undeclared 1st use in function) when i do the same using it in main it does work. how do i fix this? the data reading has to take place in a function. Yhank You!


#include %26lt;iostream%26gt;


#include %26lt;fstream%26gt;


int Flight::setData(Flight array[MAX], Flight *ptrArray)


{


ptrArray=array;


ifstream myfile ("example.txt");


if (myfile.is_open())


{


while (! myfile.eof() )


{


fp_in %26gt;%26gt; ptrArray-%26gt;flightAirline;


fp_in %26gt;%26gt; %26amp;ptrArray-%26gt;flightNumber;


fp_in %26gt;%26gt; %26amp;ptrArray-%26gt;stops;


cout%26lt;%26lt;flightAirline%26lt;%26lt;endl;


cout%26lt;%26lt;flightNumber%26lt;%26lt;endl;


cout%26lt;%26lt;stops%26lt;%26lt;endl;


}


myfile.close();


}


cout%26lt;%26lt;"End of reading\n"%26lt;%26lt;endl;


}

C++ reading from a file 'ifstream'?
put under your #includes





using namespace std;





You might want to check out C++ namespaces.





An alternate would be to do





using std::ifstream;


using std::endl;





and so on for each of the different variables/functions from the std namespace.
Reply:Try doing it like this instead.





ifstream myfile;


myfile.open("example.txt");


Can I Have THe C++ Header File Name As windows.h??

Hey....I want to have the source code of the header file windows.h.....can u plz give me that

Can I Have THe C++ Header File Name As windows.h??
if u r coding in windows and MFC, probably not. b'coz the standard windows.h gets included by default and leads to conflicts.





if u want the source code for windows.h, look in the VC++ standard include directory.

wallflower

How to make provision for file upload and download in C#.NET? file should reside in a remote system.?

I need to know how to give the URL of the system that the file is going to reside? I am developing a site where it should upload the file from the users and store in the space that I have already bought from the domain service provider. Help me out wit the code..

How to make provision for file upload and download in C#.NET? file should reside in a remote system.?
http://msdn2.microsoft.com/en-us/system....
Reply:You know in web we don' have actual path or drives, we have just virtual.


So we can access the file or folder via Server object of .net.


For example:For uploading a file for profile of someone we should create a folder for him and then upload file via


"Server.MapPath(serverPath) ".





You should set the path of server via Server.MapPath() .


How to change the icon of a exe file created using C program?

The executable file created by compiling a C source code has the common blue block icon. How can it be changed to colour ful icons which i create.

How to change the icon of a exe file created using C program?
If you don't specifically include an icon in your .exe file when you compile your program, Windows will provide a default icon for it. (Windows doesn't include the icon within the file itself - it just displays that icon when you're looking at the file in Explorer or on the desktop.)





You don't mention which compiler you're using.


Anyway, you need to include a resource file (.RC) which names the icons you wish to include or the icon data itself.





This is a rather long explanation so I'll only point to where you should look. Look in the Windows SDK documentation and your compiler's help files regarding the "RegisterClass" Windows function and about resource files. All the compiler IDEs for Windows out there make it easy to include resources (icons, pictures, wav files, etc.) in your .exe files.





P.S.


If you don't mind some advice:


If you're learning to program in Windows, I highly suggest "Programming Windows" by Charles Petzold, published by Microsoft Press. It is the de facto book for learning to program Windows. I learned to program Windows 3.1 and Windows 95 with his books. (You certainly do NOT want to learn Windows programming with the stupid object oriented libraries included with your compiler.)
Reply:check this address





http://mediasrv.ns.ac.yu/extra/fileforma...
Reply:You can change the icon of the EXE in Windows by going to its Properties and setting an icon for it. But that would be local to that system only.
Reply:After your executable is created, right click on it (shortcut). select properties. You should see Change Icon for the shortcut. There you select the required icon.
Reply:I think you can't modify the default icon for exe files. However you can modify icon of shortcut files by selecting properties from right click menu and then clicking on change icon for shortcut.


How can you view and display your text file to your C# windows application?

Help! I'm kinda confused on doing this program.





You have a .txt file (from Notepad) that has the following input in the first line:





1234567#John Edwards#Ohio





How can you able to view and display these outputs using the C# application, in such a way that '1234567','John Edwards' and 'Ohio' are different inputs, wherein, they are all displayed separately in a label/text button?





Is there any links I could access that involves this kind of problem? Thanks.

How can you view and display your text file to your C# windows application?
http://msdn2.microsoft.com/en-us/vcsharp





http://www.solver.com/sdkplatform.htm





check it out in these site..
Reply:Basically, all you need to do to accomplish this is parse out the string by using some built-in string functions. I forget the actual names of them in C#, but basically you


- get the line from the text file by looking for the delimiter (tab, space, comma, etc) and assigning everything befor it to a string


- get the length of that string by using something like myString.Length


- once you have the length, use a substring function to find the first occurence of a '#'


- using the string length function, and the indexof function, you can get the first component by getting the substring from position 1 to the position of the '#', minus one.





You can use this method to iterate through the rest of the strong, changing the start and end positions as needed.





For help, check out





www.thescripts.com


www.csharpcorner.com





Good luck.


Sir, I want to know about the projects on file handling of c language.Please send me the best projects of c?

please send me the best projects on file handling of c language

Sir, I want to know about the projects on file handling of c language.Please send me the best projects of c?
main() {


FILE *fp=fopen("test.txt","r");


char c;


While(fscanf(fp,"%c",%26amp;c)!=EOF) {


printf("%c",c);


}


}
Reply:// my first program in C++





#include %26lt;iostream%26gt;


using namespace std;





int main ()


{


cout %26lt;%26lt; "Hello World!";


return 0;


}








// my second program in C++





#include %26lt;iostream%26gt;





using namespace std;





int main ()


{


cout %26lt;%26lt; "Hello World! ";


cout %26lt;%26lt; "I'm a C++ program";


return 0;


}





/* my second program in C++


with more comments */





#include %26lt;iostream%26gt;


using namespace std;





int main ()


{


cout %26lt;%26lt; "Hello World! "; // prints Hello World!


cout %26lt;%26lt; "I'm a C++ program"; // prints I'm a C++ program


return 0;


}





// friend functions


#include %26lt;iostream%26gt;


using namespace std;





class CRectangle {


int width, height;


public:


void set_values (int, int);


int area () {return (width * height);}


friend CRectangle duplicate (CRectangle);


};





void CRectangle::set_values (int a, int b) {


width = a;


height = b;


}





CRectangle duplicate (CRectangle rectparam)


{


CRectangle rectres;


rectres.width = rectparam.width*2;


rectres.height = rectparam.height*2;


return (rectres);


}





int main () {


CRectangle rect, rectb;


rect.set_values (2,3);


rectb = duplicate (rect);


cout %26lt;%26lt; rectb.area();


return 0;


}





// friend class


#include %26lt;iostream%26gt;


using namespace std;





class CSquare;





class CRectangle {


int width, height;


public:


int area ()


{return (width * height);}


void convert (CSquare a);


};





class CSquare {


private:


int side;


public:


void set_side (int a)


{side=a;}


friend class CRectangle;


};





void CRectangle::convert (CSquare a) {


width = a.side;


height = a.side;


}





int main () {


CSquare sqr;


CRectangle rect;


sqr.set_side(4);


rect.convert(sqr);


cout %26lt;%26lt; rect.area();


return 0;


}





// vectors: overloading operators example


#include %26lt;iostream%26gt;


using namespace std;





class CVector {


public:


int x,y;


CVector () {};


CVector (int,int);


CVector operator + (CVector);


};





CVector::CVector (int a, int b) {


x = a;


y = b;


}





CVector CVector::operator+ (CVector param) {


CVector temp;


temp.x = x + param.x;


temp.y = y + param.y;


return (temp);


}





int main () {


CVector a (3,1);


CVector b (1,2);


CVector c;


c = a + b;


cout %26lt;%26lt; c.x %26lt;%26lt; "," %26lt;%26lt; c.y;


return 0;


}








#include %26lt;iostream%26gt;


using namespace std;





class CRectangle {


int x, y;


public:


void set_values (int,int);


int area () {return (x*y);}


};





void CRectangle::set_values (int a, int b) {


x = a;


y = b;


}





int main () {


CRectangle rect;


rect.set_values (3,4);


cout %26lt;%26lt; "area: " %26lt;%26lt; rect.area();


return 0;


}
Reply:www.pscode.com


www.sourcecodesworld.com





visit them u ll get a better idea

hollyhock

My windows me always restarts when i click any file in drive c at windows explorer, what's the problem?

everything started when i connected another hard drive into my cpu. i have taken it off (the hard drive i have just connected) but the computer still restarts whenever i click any file in drive c at the windows explorer

My windows me always restarts when i click any file in drive c at windows explorer, what's the problem?
EES BECAUSE YOU HAVE CATS IN COMPUTER.


How to Execute my EXE or Application File of my C# program in Windows XP.?

I wrote a Program in C# code ( I wrote that in Win 2000 Advace Server ) but when I want to run it's Exe file in Win XP it show me an Error then break, PLZ, Help me it's so important for me.

How to Execute my EXE or Application File of my C# program in Windows XP.?
C#.NET needs a .NET Framework to run your application. May be you just need to download and install .NET Framework,





There are 2 version rigth now, 1.1 and 2.0, by default, try to install the 1.1 to WIN2K and see what happens, but i think this can solve your problem.
Reply:Recompile your source code under Windows XP. Chances are that might work. It's just like if you were to take an exe from Windows and try to execute it on Unix, it wouldn't work. Recompiling may or may not fix your problem. Unless of course you already tried that... and if you did someone who is more of a programmer will have to help.
Reply:hey u if u had used the .net platform then i think there should be no problem,cause i do that way.
Reply:Right-click on the application, then choose the Compatibility tab... then select the operating system from the drop-down list as Windows 2000. It should try to run the application as if in a Windows 2000 environment...


How to save data to a excel file from Visual c++ programm? (coding example please)?

I am writing a program using visual c++. i want to save some data to a excel file. i need a example code for that. help me

How to save data to a excel file from Visual c++ programm? (coding example please)?
Save from c++ as a csv (comma separated variable) text file e.g.





data1,data2,data3





Excel should import it easily.


I want to remove a specific sharing file off my C drive. How do I do it without reformatting?

I have a sharing File that will not delete by right clicking and it is on my C drive. How can I do this without reformatting the computer. I want to permanently delete it.

I want to remove a specific sharing file off my C drive. How do I do it without reformatting?
To delete it, first you have to remove the sharing rights. Right click on it and choose "Sharing and Security" Choose "Do not share this folder".





Once that's done, try to delete the folder again. You shouldn't have problem anymore.

cabbage

Does anybody have a simple code for file handling in C++?

I'm a class 12th PCM student and I need a project on file handling in C++. Something on hotel/train/airline reservation, etc. With very basic features like displaying, addition, modification, deletion, etc.


I would love a ready, bug-free project, but anything close to that would be great, too.


I know it's unethical, but as some of you know, it really isn't easy to spare time for things beyond physics, chem and math. So if anybody can help please let me know here or email me: sudeep_bansi@yahoo.co.in.

Does anybody have a simple code for file handling in C++?
NO I WON'T ;) but I like your name :)
Reply:It would be better if you learn some theory about file handling in C++ using your test book. I have some programs on file on my blog http://codesbyshariq.blogspot.com , but they are in C-lang although you can get some hints from them.
Reply:visit to planetsourcecode.com


search for the same keyword. u will get lot of codes related with yr query
Reply:So you know it is unethical and you still ask, *sigh*, you know other people get through your program without cheating.


Is that a program that will automatically generate a header file from my c programming source code(not C++).?

I am programming a c language linked list stack in a program called Eclipse. I have the source code in stack.c. I am looking for a program that will scan my stack.c source code and generate a stack.h header file automatically.





Please let me know if there is anything like that out there and a quick explanation of how to use. it.





Thank You

Is that a program that will automatically generate a header file from my c programming source code(not C++).?
no its program that takes few codes from header files and use it


I need a C++ header file... (DxLib.h)?

Does anyone know where I can get the header "DxLib.h" online? I can't find it in my normal library, but need it to compile some code.





From what I understand, I can download the code with DirectX, but since I have a Mac with XCode, that's not gonna work. If the file isn't freely avaliable online, if anyone has this and can put the code online, I would be eternally grateful (and would give you a best answer?).





If you can't upload online, send a copy to dragonlordals @ yahoo . com (remove spaces). Though, for security reasons, I'm not gonna actually open these files unless there's no alternative.

I need a C++ header file... (DxLib.h)?
search it on:


planet-source-code.com
Reply:donot worry


you can get a better project from an expert


from


http://homework.teamtutorial.com/


How can you know if there's a hidden, inaccesible file/ folder like C:\ System Volume Information in your PC?

How can you know if there's a hidden, inaccesible file/ folder like C:\System Volume Information in your PC?





Just in case you don't know that "C:\System Volume Information" actually exists in the world of virtuality, how can you know that such files exists?





Is there anyway to know such files if you don't know their paths, locations, and etc., say can you do it in cmd? or control panel? regedit? any freewares?











Thank You very much for your efforts!


TNX!

How can you know if there's a hidden, inaccesible file/ folder like C:\ System Volume Information in your PC?
My Computer%26gt;Tools%26gt;Folder Options%26gt;View


Clear the checked


"Hide protected operating system files (Recommended)"


and check


"Show hidden files and folders:


Hit Apply, then Ok.





Now go to your C drive and you will find the "System Volume Information" folder there. Good Luck!
Reply:I faced this problem very recently and now I know the answer.


Go to my computer, then tools, then folder option, then view, unclick hide protected operating system files (Recommended). Once you do this you will be able see system volume information folder in each drive.
Reply:There are lots of regular files/folders that regular users don't need to know or microsoft don't want them to know. So in most cases you have to know the exact location of these file to explore them.


Sometimes there is an simple workaround. In the case of 'System Volume Information' folder you have to go to Tools-%26gt;Folder Options-%26gt;View. Click the 'Show hidden files and folders' radio button and uncheck 'Hide protected files and folders'. A pop message will appear, click yes. Now you can see the 'System Volume Information' folder in each of your drive.


For security reasons you should always uncheck 'Hide extentions for known file types'.
Reply:open c drive


go in the tools menu


menu options


and check the show hidden files


for the other programs just type them in start run


are in c:\winnt\regedit.exe
Reply:You can enable viewing of Hidden Files/Folders by:





1) Opening Windows Explorer


2) Go to Tools-%26gt;Folder Options... menu option


3) go to View tab


4) Under the "Hidden Files and Folders" in the Advanced settings list select the "Show Hidden files and folders" radio button


5) Click Apply


6) Click OK





You can now view the hidden files and folders on your system.
Reply:System Volume Information is related to your System Restore and you shouldn't be trying to mess with it or you can corrupt your system.





There are other types of protected files. You can display all hidden files and folders vua Control Panel, Folder Options but they are default hidden for a purpose, so that people don't accidentally remove or corrupt files that are essential to your computer's functionality and stability .





That being said, sometimes certain malware can hide itself in there and you have little choice but to access it.

phlox

How can I read a .bmp file in my C pragramme?

I want a method to read a bitmap(.bmp) file in my c source code.


besides the method I will be very greatfull and consider the best answer of those who will provide me the gud source code by e-mail plz help me.

How can I read a .bmp file in my C pragramme?
Knock yourself out (not all structure include in the code below):





unsigned char* read_windows_bmp(const char* infilename, ImageHeader* header)


{


FILE*infile = NULL;/* input file handle */


unsigned char*image_ptr = NULL;/* pointer to output image in memory */


unsigned char*writep = NULL;/* temp pointer writing to image */


BMPHeaderbh;/* BMP header */


charmode[] = "rb";/* mode to write to file */


unsigned longrow;/* row iterator */


unsigned longcol;/* column iterator */





/* Open the BMP File */


if ( (infile = fopen(infilename, mode)) == NULL )


{


fprintf(stderr, "can't open %s\n", infilename);


return image_ptr;


}





/* read first two bytes */


fread(%26amp;bh.magic1, sizeof(unsigned char), 1, infile);


fread(%26amp;bh.magic2, sizeof(unsigned char), 1, infile);





/* test to see if this is really a BMP file */


if (bh.magic1 != 'B' %26amp;%26amp; bh.magic2 != 'M')


return image_ptr;





/* read header information */


pm_read_little_long(infile, (long*)%26amp;bh.filesize);


pm_read_little_short(infile, (short*)%26amp;bh.res1);


pm_read_little_short(infile, (short*)%26amp;bh.res2);


pm_read_little_long(infile, (long*)%26amp;bh.pixeloffset);


pm_read_little_long(infile, (long*)%26amp;bh.bmisize);


pm_read_little_long(infile, (long*)%26amp;bh.cols);


pm_read_little_long(infile, (long*)%26amp;bh.rows);


pm_read_little_short(infile, (short*)%26amp;bh.planes);


pm_read_little_short(infile, (short*)%26amp;bh.bitsperpixel);


pm_read_little_long(infile, (long*)%26amp;bh.compression);


pm_read_little_long(infile, (long*)%26amp;bh.cmpsize);


pm_read_little_long(infile, (long*)%26amp;bh.xscale);


pm_read_little_long(infile, (long*)%26amp;bh.yscale);


pm_read_little_long(infile, (long*)%26amp;bh.colors);


pm_read_little_long(infile, (long*)%26amp;bh.impcolors);





/* If compressed, bail */


if ( bh.compression )


{


fprintf(stderr, "%s is compressed.\n", infilename);


return image_ptr;


}





/* set out header information */


header -%26gt; width = bh.cols;


header -%26gt; length = bh.rows;


header -%26gt; spp = (bh.bitsperpixel == 24) ? 3 : 1;


header -%26gt; rowbytes = header -%26gt; width * header -%26gt; spp;


header -%26gt; colorspace = (bh.bitsperpixel == 24) ? RGB_24_BIT : INDEX_8_BIT;





if ( header -%26gt; colorspace == INDEX_8_BIT )


;/* need to read color table */





/* move to start of image data */


rewind(infile);


fseek(infile, (long)bh.pixeloffset, SEEK_SET);





/* allocate space for new image */


image_ptr = init_image(*header, 0);





/* Windows BMP files are backwards so move write pointer to end of image */


writep = image_ptr + ( header -%26gt; rowbytes * header -%26gt; length );





/* only read 24 bit images for now */


if ( header -%26gt; colorspace == RGB_24_BIT )


{


/* loop through the image data */


for ( row = 0; row %26lt; header -%26gt; length; row++ )


{


/* backup one row */


writep -= header -%26gt; rowbytes;





for ( col = 0; col %26lt; header -%26gt; width; col++ )


{


/* read blue byte */


fread((writep+2), sizeof(unsigned char), 1, infile);


/* read green byte */


fread((writep+1), sizeof(unsigned char), 1, infile);


/* read red byte */


fread((writep+0), sizeof(unsigned char), 1, infile);


/* advance three bytes */


writep += 3;


}


/* backup another row */


writep -= header -%26gt; rowbytes;


}


}


else


fprintf(stderr, "%s is an indexed image.\n", infilename);





/* close file */


fclose(infile);





return image_ptr;


}
Reply:You can read a BMP using pure C code, but it's not easy... I found here an example written entirely in C which can read a 8-bit BMP file..


There is another way though... The C language recognizes assembler instructions. Each file has a header which gives all the info required to make the OS "understand" it. This part isn't located exactly at the begining at the file.. It depends!


Of course knowing these values and where to find them it would be easy just to configure them! You'll need assembler language for this.


I found the BMP header file at the second link (not much info though...).


Also, a way to work with it (and an example of code that understands 256-bits BMP and not only) is at the last link.. Although it's in pascla the code it's adaptable very easy to C


Hope this helps!
Reply:http://www.google.co.uk/search?q=bitmap+...


Searching the net is so easy it hurts!





Rawlyn.





p.s. It's spelt "program" in computer terminology. A programme is something you buy at the theater.


I want to run an exe file from my c++ application that has to run simultaniously with the calling program,how.

i am using borland turbo c++ 5.01 version on windows xp , there r no arguments to be passed can anyone give me the command to do that.(let abc.exe be the file to be run give me the exact command).

I want to run an exe file from my c++ application that has to run simultaniously with the calling program,how.
execxxx,system and spawn are the choices
Reply:I'm not sure how to fork a process in Windows.





But the system() command should get you some of the way there.


Can you open a microsoft excel file in turbo c?

if yes, how do i it? and how could i edit the ms excel file in turbo c?

Can you open a microsoft excel file in turbo c?
To read the data inside the file and make sense of it you probably need to take into reference ,its file format for storing data. If you just want to read data just for the heck of it , you should be able to do it.


P.S Sorry didn't read the whole question, you will need some very detailed explanation about its file format. Try searching for something on the lines of "Reversing excel files" or excel file format deciphered and you *might* get some pointers.


Each time I turn my computer it says...check file system on c!!!?

each time I turn my computer it says...check file system on c!


%26amp; after checking the file system it says "found no problem"





is this a serious problem...if so then how can i solve it?


my operating system is "windows xp-service pack 2

Each time I turn my computer it says...check file system on c!!!?
That usually means that you did not shut down your computer properly, or that Windows is just not shutting down properly. Technically, its not really a problem, and it will most likely never find a problem with the C: drive.


You will only ever really have an error if like, your computer is running and the power goes out. That could mess up your hard drive, because of the sudden power change, and also, Windows won't have time to shut down properly. You can try putting your system in hibernation, or on standby (or sleep) if the problem is too annoying.
Reply:Download this free program, it might do the trick:





http://www.download.com/Advanced-Windows...
Reply:Yes because of the nature of Windows XP keeps telling you to check the drive. How old is the computer's hard drive because maybe it is failing. The newer HD's made these days last about 3 years and some brands do not last that long. I would run cmd and type in chkdsk /f and restart the Windows to see if that repairs what ever is telling Windows to suspect a bad format. I would make backups of my important files as fast as possible. If the format fails nothing will be recoverable and I have had a lot of Maxtor HD's fail with no advance notice but that's another story ( they were OEM in Gateway computers )

verbena

How to input data from a txt file into a c++ vector?

I have a txt file that contains three lines as follows:





2302.9 4390.3 604.9j


393.9f 4059.3t 0509.c


395.d 39.7





I need to read this file line by line and input the values into a string vector. Any idea on how to do this ?

How to input data from a txt file into a c++ vector?
First, you need to know what a vector is and how to use it. Then you must use it to create a vector object that holds an array of string objects. Then you must load your data into it at an appropriate point in the procedure, there are a couple of options here. Starting with the information available from the URL below, I think you should find a way that will work well. Good luck.


Thursday, July 30, 2009

I have a 43GB fragmented file in my c:\windows\system32\dlg\temp folder, what do i do?

also i have been gettin problems of having a full c drive, even after using the windows maintainance prgrams, ccleaner. Defragmentation lasts only seconds and all the red bits dont turn blue, infact most of it is red(fragmented). But my internet and pc games are all fast. I have removed all the unnescesarry programs and have installed them on my external 250GB(which i have partitioned). I have also checked using AVG and Lavasoft ad-aware...and have no viruses. what is goin on?!?...this is a problem as , even though every thing is fast, i cant print,burn discs or do scans, and being an art student i need these things. I have also been getting 'invalid.boot ini. file' at the startup...

I have a 43GB fragmented file in my c:\windows\system32\dlg\temp folder, what do i do?
If your running XP


start run "cmd"


Type chkdsk /f


reboot and let it run itll fix some errors that may come up during the scan.





Next purchase a 3rd defrag program. The one that comes with windows doesnt like to defrag files any greater then 1GB. It especially doesnt like the large world of warcraft files. I dont recommend programs unless asked.





Finally go to http://www.microsoft.com/athome/security... and run the live safety scan. That checks for spyware/malware etc.. supposed to clean the registry too.





there is no reason to go to the extreme of uninstall/reinstall of the OS or programs unless the previous mentioned route doesnt work.
Reply:Ouch, I'm in a similar situation, but I don't have a 43GB file. What you need to do is find like a 300GB hard drive, put windows on it, put the file on it and run defrag over and over again. You're going to need lots of free space to defragment that file, and more than likely it'll keep re-fragmenting.
Reply:Run a full scandisc, you'll need a reboot, as a file size may be misreported. I personally don't have a dlg folder on my XP pro machine, So I'm not sure what has put it there. You could try deleting it, since it is in a temp folder. It shouldn't cause damage, but note my use of could and shouldn't... be prepared to reinstall windows..
Reply:Golden Bow Systems offer a 30 day free trial of their defrag tool,"VoptXP"This will do a better job than windows' own tool,damn sight faster too.......


www.goldenbow.com
Reply:I dont think you have a 43GB file, I think the File Allocation Table is reporting an incorrect file size.


You need to run something like Disk Doctor





Amendment: I dont understand why I received a negative review on my answer because I believe I have the correct diagnoses, as does 'tony', tony explains how to correct this.
Reply:restart to safe mode (f8 when starting windows) and delete the dlg folder aswell as the dlgincoming folder.





this is some kind of malware or something.
Reply:your drive is to full and it will not defrag when your drive doesn't have room for your Operating system to work. Uninstall some stuff you don't need. Get a backup drive and load some of your stuff onto the back up drive.
Reply:dude, just save all needed files onto your external hd and reinstall windows, because its messed up
Reply:b brave my man delete it and see what happens


Why do I get a "file inconsistency in C drive" blue screen when I turn on the computer?

Whenever I turn it on, a blue screen with "checking file inconsistency in C drive" or something like that, and it gives me about 10 seconds to press any key to skip the disk scan. And it also says something about "Fat32"... whatever that is.





Not only does this screen come up when I restart, but every time I insert a CD/DVD/CD-R/CD-RW into the drive, the computer will restart and the same screen comes up.





I let the scan run all the way through one time and it got to showing the desktop and the windows starting music, and then it restarted itself and the whole process over again. It was an endless cycle until I "pressed any key to skip the disk scan", and then it let me use the computer as normal.





Anyone ever have this problem or have a solution? Thanks so much!

Why do I get a "file inconsistency in C drive" blue screen when I turn on the computer?
At this point, the first thing you should try is to run a disk utility program like Spinrite ($60). It's by far the best on the market (by Steve Gibson) and highly recommended. Do a bit of research on it on the website, and if you want, google it and you'll see tons of positive comments and reviews.





Contact me for more information if you want some more information on "trying" it.





http://www.grc.com/sr/spinrite.htm
Reply:If your computer is not working properly while you are working on it, it could be a problem with device drivers, hardware or software.


Detailed instructions at http://tinyurl.com/yk5zpr
Reply:You could try the System Restore which takes you back to a time when your computer was working good. Go To:


start


programs


accessories


systems tools


system restore


This process is completely reversable. And does not remove your personal files. Just go back one checkpoint at a time until your puter is working good again.


E


Why would a file fail to be deleted from the c drive and how would you get rid of it ?

I want to delete a video file from my c drive but it wont delete . Its says its being used by another program yet its not !





So How do I get rid of it ? Thanks.

Why would a file fail to be deleted from the c drive and how would you get rid of it ?
Rebooting would work, but perhaps another program IS using it, maybe either you don't realize it or if you were running the video with a program and recently close it, it froze and the CPU is still processing the fact you were trying to close the program and stop reading the file.





Anyhow, try rebooting and delete again. If that still doesn't work, reboot and go into safe mode (consult your manufacturer's manual: should be pressing one of the F# keys on startup) and attempt again.





Alternatively, if you're a bit tech-savvy, you could find the program that you suspect is using the video file in the task manager (control + alt + delete) and end the process, thus eliminating the problem altogether.
Reply:it happened to me some time too.


you can do the Alt+Ctrl+delete%26gt;in the "process" window find the program that might using your video file, right click on it and select end process.





or you can just re-strat the computer and try to delete it after you turn it back on. (i used to do this and it always work.)
Reply:that happened to me last week .. i rebooted and deleted it ..
Reply:This is also possible if the file is actually deleted but still in the index of an NTFS file system.
Reply:The file in question is being access by another process on your computer. Most likely this is a virus if you do not have any video related software running on your system.





I would suggest validating your Anti-virus software is up to date.
Reply:it could be in use by a background program, or a read only file. reboot into "safe mode" and try to delete it
Reply:Go into safe mode and delete it from there. Trust me I know the frustration all to well. Good news I did find the program running what I needed to delet.
Reply:Restart your computer. Try to delete once again. If not then Ctrl+Alt+Del to see which program is running. End all task and then delete it.

snapdragon2

C++ Assistance, Involving reading file, calculating average, sum (running total), amount of numbers?

I also couldn't figure out how do do this one. It's the last one I have to do, I promise ;). It involves doing stuff with a text file (which I uploaded onto the internet).





The question goes like this:





The Student Cd contains a file named random.txt [I uploaded it to http://d01.megashares.com/?d01=3251418]. This file contains a long list of random numbers. Copy the file to your hard drive and then write a program that opens the file, reads all the numbers from the file, and calculates the following:


A) The number of numbers in the file


B) The sum of all the numbers in the file ( a running total)


C) The average of all the numbers in the file





The program should display the numbers of numbers found in the file, the sum of the numbers, and the average of the numbers.





I really appreciated the help, I wish they had more examples in the book for this stuff. Thanks for taking the time.

C++ Assistance, Involving reading file, calculating average, sum (running total), amount of numbers?
Here you go:





// For this program to work, you have to place the random.txt


// file in the same folder where your program is. Otherwise,


// change the location of the file below





// I am also assuming that you can use arrays. Let me know if


// you have to use linked lists.





#include %26lt;iostream%26gt;


#include %26lt;fstream%26gt;





using namespace std;





int main()


{


const int MAX_SIZE = 210;


ifstream inFile;


int number;


int array[MAX_SIZE];


int currentIndex = -1;


int sum = 0;





inFile.open("random.txt");





if(!inFile.fail())


{


while(inFile %26gt;%26gt; number %26amp;%26amp; currentIndex %26lt; MAX_SIZE)


{


currentIndex++;


array[currentIndex] = number;


sum += number;


}


inFile.close();





cout %26lt;%26lt; "The file contains: (" %26lt;%26lt; currentIndex + 1 %26lt;%26lt; ") numbers" %26lt;%26lt; endl;





cout %26lt;%26lt; "The sum of all numbers is: " %26lt;%26lt; sum %26lt;%26lt; endl;





cout %26lt;%26lt; "The average is: " %26lt;%26lt; (double) sum / (double) (currentIndex + 1) %26lt;%26lt; endl;


}





else


{


cout %26lt;%26lt; "Couldn't open random.txt" %26lt;%26lt; endl;


}





return 0;


}
Reply:I guess you don't want us to do your homework for you, please specify what you don't know to do here.


Hints:


File IO read in:


http://www.cplusplus.com/doc/tutorial/fi...


have two variables: int counter = 0, sum = 0;


for every new number counter++;


for every new number sum += number;


A is counter


B is sum


C is sum / counter


Opening, Reading and Writing a file in GNU C++ Linux?

Can anyone please tell me how to open, read and write a file in GNU C++ under linux. I just need to know which libraries are used and a little documentation on them.

Opening, Reading and Writing a file in GNU C++ Linux?
Nothing prevents you from using standard C++. Open, read, and write files the same way you would under standard C++ on Windows. fopen, fprintf, or whatever are still valid.





Is there a question you had that standard C++ references and tutorials aren't able to answer?


What wanna say my computer when says this: Checking file system on C:?

Checking file system on C:


The type of file system is NTFS


One of your disks needs to be checked for consistency. you may cancle the dick check, but it is strongly recommended that you continue.


Windows will now check the disk


CHKDSK is verifying files (stage 1of 3) ...








I do not know why my computer does that. Every time a turn my computer on , this check begin to do this thing. What 's producing this. why my compu is doing this? How can fix it?

What wanna say my computer when says this: Checking file system on C:?
This because you either turned your system off without a proper shutdown, or your system crashed. When your system is running there are a number of files being used all the time. When you shut down the system, these files get saved to disk. If you don't shut down properly, these files are left open, and your operating system needs to repair them when it starts up again.





Let chkdsk finish, and your message should not reappear next time your turn the system on. To avoid this in the future, make sure you shut down your compurter, not just shut it off, and make sure the shut down is actually completed.





Or just leave the computer on, and turn off only the monitor.
Reply:This sounds like what happens when the computer is not shut down properly. For example, if you just turn off the power.





Proper shutdown allows the computer to save and close files and update others, providing an orderly shutdown. So when the computer is booted after a non-elegant shutdown, it has to check the file system to verify all the parts are there to function.
Reply:let it run. Its doing a disk check and is looking for errors to correct. After its done it shouldnt ask anymore and should fix any errors
Reply:It is just checking the drive making sure that there aren't any bugs on the drive. It will cause no harm but just takes a long time.





Jake--


Learn2createawebsite.com


I need a C++ header file... (DxLib.h)?

Does anyone know where I can get the header "DxLib.h" online? I can't find it in my normal library, but need it to compile some code.





From what I understand, I can download the code with DirectX, but since I have a Mac with XCode, that's not gonna work. If the file isn't freely avaliable online, if anyone has this and can put the code online, I would be eternally grateful (and would give you a best answer?).





If you can't upload online, send a copy to dragonlordals @ yahoo . com (remove spaces). Though, for security reasons, I'm not gonna actually open these files unless there's no alternative.

I need a C++ header file... (DxLib.h)?
search it on:


planet-source-code.com
Reply:donot worry


you can get a better project from an expert


from


http://homework.teamtutorial.com/

avender

Do I need a 1099 to file a Schedule C?

I did some freelance work over the past year and did not receive a 1099 for any of the job (they were all a few hundred dollars each). Do I need a 1099 or record of how much I was paid in order to file a Schedule C and write off business deductions?

Do I need a 1099 to file a Schedule C?
A 1099 does not need to be issued for amounts under 600.00 dollars. Use your own records. the IRS will accept these records.
Reply:You don't need a 1099 - file from your records, and claim your eligible expenses, on schedule C.
Reply:No - all you need is a record of your payments and evidence of your deduction if you are audited
Reply:Excellent question!





No, you do not need to receive the 1099. Your schedule C should report all income you made for that particular business whether cash, check, or even bartering. Technically, someone going around mowing lawns needs to report this income, and no one I know gets a 1099 mowing lawns.





Don't forget to include all expenses you incurred to generate this income. Remember, the IRS only taxes you on the net profit from the business, not just the income. In fact, you may have a loss. Most businesses do the first year or so. This loss will offset any other income you have for the year and lower your taxes.





Good luck!
Reply:No. You do not need a 1099. In fact your clients are not required to file a 1099 unless they paid you $600 during 2007. You can just complete your schedule C based on your own records.


How do I read from two or more external FILE's in 'C', (NOT C++)?

There are two external FILES, this 100 integers each.





How do I get the C code to read the two files, stop at the first integer in each file, then compare which is the higher of the two, then print to screen?








Then to loop again, to compare the next interger, of each file, until EOF.

How do I read from two or more external FILE's in 'C', (NOT C++)?
visit my blog





http://codesbyshariq.blogspot.com


for example and source codes
Reply:the functions you'll need are fopen, fread, fclose and atoi (string to int).





something like:





FILE *f1 = fopen("myfile1.txt","r");


FILE *f2 = fopen("myfile2.txt","r");


void *buff1, buff2;


size_t size = sizeof(int); //for fread





while (EOF != fread(buff1,size,1,f1) %26amp;%26amp; EOF != fread(buff2,size,1,f2)) {


int i1 = atoi(buff1);


int i2 = atoi(buff2);


if(i1 %26gt; i2) { printf("file 1's line is larger\n"); }


else if(i2 %26gt; i1) { printf("file 2's line is larger\n"); }


else { printf("equal.\n"); }


}





fclose(f1);


fclose(f2);








hard-core C programmers are probably laughing at this code, and it certainly won't compile, but it's in the right direction.


There are some many file folds under c://windows, name $???$, can I delete them or not?

there are some many file folds under c://windows, name $???$, can I delete them or not? ??stand for any words.

There are some many file folds under c://windows, name $???$, can I delete them or not?
***Point of Advise***





What are you doing inside Window's folder? you are not suppose to open those folders in first place.





In windows folder there are so many items, even updated files. If you are not sure do not do any thing and try not to open other Program or windows folder if you want to use PC.
Reply:no do not delete them it would be bad they are baisicly a reference for you computer to say what you have uninstalled
Reply:what are in the folders? If there isn't anything, delete the folder. If there is something, try do some research and see what it is.
Reply:If they are in the systum files DO NOT TOUCH
Reply:no, ur pc will go boom boom


How to run a file using a C++ program ?

not open and modify............I want the C++ program run the file in his own window and leave it do it's operations alone.

How to run a file using a C++ program ?
import an MS-DOS command in your C++ program.. include first stdlib.h... Then use system() function... For example, you want to run a calculator... Simply do this..





system("calc");





or notepad...





system("notepad");





or run another c++ program in the same window which is also located in the same directory as your c++ program running...





system("mycppprogram.exe");





Simple huh?? (^^,)





http://ronaldborla.blogsome.com/
Reply:You can't "run" a file, you can only run a program and not all files are programs. If you want a program to run another program, use fork. If you want a program to "run" a file that's not executable code, it can't be done.
Reply:If you want to run the program through c++ console window you have to prss ctrl+f9 or go to the


run tab%26gt;run


(This will work after a successful compilation)


or if you hav run the same program previously....


you will find a .exe file of the same program name in that directory where you have saved the program,then


just run the file by double clicking on it......
Reply:I think you're asking how to run a command line interface program in a console window on it's own. Try right-clicking the program, mousing to Open With, and selecting your terminal application (Terminal.app on OS X or MS DOS on windows).

violet

How do i use a header file in a c++ program?

I have constantly tried to use classes in my c++ programs in header files but they never work, i always either get a error that says the included file doesn't exist or the program runs then just closes unexpectedly when it tries to use the header file.

How do i use a header file in a c++ program?
First if your putting classes into header files, make sure those header files are saved as .hpp files not .h files.





Second make sure you either are including your headers in only one place or they have preprocessor commands to stop multiple copies from being created (using #define, #ifndef and #endif)





P.S.


Even if the header file is included in the project, you can't just use the name with #include unless the header is in the same directory.





Also try putting your classes into your cpp files themselves and see if it's the classes and not putting them in headers that is causing your program to close. Also another major thing is if your program is a command line program, unless you have some kind of pause at the end (like a getch() or a system(PAUSE)), windows will by default close the window after the program finishes running.
Reply:If it is your own header file you have created, you need to use double quotes in the include statement. Heres an example:





#include "MyClass.h"





If you are storing your class in a subfolder of the program, such as 'Classes', you would use #include "Classes\MyClass.h"
Reply:If its compiling, then the problem isnt because of your header files





The proper way to include it would be


#include "myheader.h"





Note you use .h and not .hpp, though it doesnt really matter


You need to debug your program to see why its just quitting. It wil be something in the .c or .cpp that isnt working properly


I have a virus it is a file on my C drive with random digits and has a locked update file?

I have a mysterious file that has a random number and letter pattern in my C:/ drive. inside is a folder called Update which is locked. how do i unlock this file to get rid of this file.?? what is this please help

I have a virus it is a file on my C drive with random digits and has a locked update file?
get the name of the program and go to Add/Remove programs and remove it. Then go to the folder and delete it and anything in it. Then search the rest of C:\ for odd folders then run anti virus stuff and adware stuff and pest stuff and email the company that sent it to you and type foul language so that they bleed out of their ears.....


(you know u wanna pick that for best answer)
Reply:Scan the PC with a standard anti virus and an anti spyware. If you do not have, Please visit the following site and select a suitable free antivirus.


http://tinyurl.com/ymctqq


You can visit the following site , if you want a more effective antivirus . You have to pay for it!


http://tinyurl.com/ykzjyp


You also try to select and install a suitable spyware from the following link to protect the Pc against spyware attacks.


http://tinyurl.com/ygvyzh
Reply:Scan the PC with standard antivirus software. If you do not have one, I can give a few links that offer free virus and spy ware removers...!You may be having a virus or spyware installed on your PC. Norton, AVG , Avast are free antivirus software. Ad-aware, Ewido are free spyware removers. You can download free softwares at


http://fixit.in/antivirus.html and http://fixit.in/spywareremover.html
Reply:go into safe mode and run anti virus to remove. and I dont think you really want to open the file if you are sure its a virus.


I/O header file error in c language?

Whenever I tri to compile the c program it give me error that i/o header file is not included.i have set the right path in directory still It is giving me error .How can I remove it. Hel p me plz .

I/O header file error in c language?
You mean stdio.h? You should include it like this:





#include %26lt;stdio.h%26gt;





A common mistake is to use quotes instead of angle brackets, but all system header files require the brackets.
Reply:YOU FIRST CHECK OUT WHETHER THE IO HEADER FILE IS IN INCLUDE DIRECTORY .IF IT IS NOT THERE PLEASE COPY FROM ANY WHERE AND PUT IT IN THAT INCLUDE DIRECTORY.IF U ARE USING C EDITOR FROM UR C:WINDOWS U HAVE TO COPY THE ENTIRE 'C' PROGRAMFILES IN THAT(C:\).IF NOT U CAN USE OTHER DRIVES BY SETTING PATHS AS FOLLOWS:


1.GO FOR OPTIONS INTHAT GO FOR DIRECTORIES :


2.HERE YOU HAVE FIEDS TO ENTER


a.INCLUDE\


b.LIBRARIES\


c.OUTPUT\


PLEASE FULFILL THE FIEDS AS FOR UR 'C' SETTINGS.


AND ENJOY THE 'C' PROGRAMING.


About a System File on my C:\ Drive, why does pagefile.sys appears?

OS: Windows XP SP2


C:\pagefile.sys 737,280kBytes (almost 1GB!)


It seems to be updated every day.


Where does this file come from and why is it needed? I don't think that was originally present.


i'll appreciate any comments, thank you.

About a System File on my C:\ Drive, why does pagefile.sys appears?
This is a temporary file used by the memory manager, when you run out of System memory it uses your hard disk instead, this is slower.





To change it Right Hand mouse click my Computer, Properties,Advanced, Performance

peony

Can. I take a single file as a copy off Drive 'C' and 'D' ??? Pl Guide me some one ?

Pl note that I am running Win 98 on 'C'. Then taken a copy by norton ghost as one file of drive 'C'. Then I installed Win XP sp-2 as new installation on drive 'D'. Now my system has 2 operating system simantaniasly. -- Now i want to take a single file as copy for both drive. Otherwise i want to take a copy as single file off drive 'D'

Can. I take a single file as a copy off Drive 'C' and 'D' ??? Pl Guide me some one ?
The Ghost Image of your 98SE partition is for "disaster recovery" purposes ONLY, leave it alone!!!





If you are really asking: "How do I copy my 98SE personal files into XP?", here's how:





In XP, open the C: drive and find your personal data. Then, copy %26amp; paste into XP's My Documents folder. Done.


What does this mean,checking file system on c?

when i restart my pc, i get a blue screen that saids


windows needs to check file system on c


the type of file system is NTFS


One of your disk needs to be checked for consistency.





I get this message ever so often for the pass year.when i allow it to go on it never tells me anything is wrong.


can anyone tell me what is wrong or why it is doing this or if there is anything i can do to stop it.

What does this mean,checking file system on c?
Alomst anything can go wrong with a hard drive at any given time for so many reasons. There are a few initial tests that the hardware or software (OS) can check at start up that may indicate there is a problem w/ the "consistency" of the hard drive. Your OS (likely XP, Vista or NT) is running chkdsk which is a program to fix those programs.





Problems such as internal file allocation tables, file integrity, file pointers, and many more can easily get corrupted and sometimes just as easily fixed. My experience is that if it starts happening a lot (more frequently) that your hard drive could be failing and I would suggest replacing it before it does.





Another common cause to this is powering off the machine instead of using the "Shut Down" inside of Windows.
Reply:Check Disk is a utility for Windows XP to get ride of on the items that have crupted data from last time shut down you can stop this normally by shutting down Windows by clicking Start %26gt; Turn Off Computer %26gt; Turn Off


More Info From Below


http://www.raymond.cc/blog/archives/2008...
Reply:Errors abound with windows sometimes, even small ones. Over time, unexpected shutdowns, crashes, ppl turning off the pc at the power button, etc. causes system errors on the disk. Windows is doing a quick chkdisk.





You can do one yourself and get a full report by going into a command console and typing "chkdsk /f /r". Answer Y for yes at the prompt and sit back and wait.





EDIT:Enable or Disable Scandisk/Chkdsk on system reboot


If you disable the automatic execution of Scandisk (Win98, ME) or Chkdsk (Win2K, XP), you should run it manually about every two weeks to maintain the integrity of your PC's file system.





Windows XP





Start %26gt; Run %26gt; chkntfs /x %26lt;drive%26gt; [drive] [drive]





For example, if you want to disable Chkdsk from running on drive C: chkntfs /x c:





Chkntfs works by modifying the BootExcecute value in the Registry.


HKEY_LOCAL_MACHINE\SYSTEM\


CURRENTCONTROLSET\


CONTROL\Session Manager


The default value is BootExecute:REG_MULTI_SZ:autocheck autochk *





Chkdsk /f /r is unaffected by chkntfs and can be run to check volumes manually on the next system reboot.





To restore the automatic execution of Chkdsk, you can add this registry file .





[HKEY_LOCAL_MACHINE\SYSTEM\


CurrentControlSet\Control\Session Manager]


"BootExecute"=hex(7):61,75,74,


6f,63,68,


65,63,6b,20,61,75,74,6f,63,


68,6b,20,2a,00,00
Reply:Its part of the CHKDSK function. It double checks the different types of memory (RAM, HD) and the file system (the thing that dictates how everything you save will be mapped out and where on the hard drive it will save to) to make sure they are working fine. Check the wiki article for more.





Hope this helps ;)
Reply:ALLWAYS when u want to turn the pc off: click on the "Start" button, then "Shut down..." and wait till it turns off or shows the message: "It is now safe to turn off your pc". Just before this switch it off.
Reply:..Its because ..u didnt shutdown properly........


just let it ..Check once...and it wont show up again ....if u shutdown the next time properly....


......................................... nothing wrong...
Reply:This is Windows scanning your Hard Drive disk's physical surface looking for bad sectors. What could cause this disk scan to occur most likely is from powering off the computer incorrectly, like holding down the power button without allowing Windows to properly go through it's Shutdown procedure. Make sure you are clicking the shutdown button when you are shutting down and if needed, Windows should prompt you when it is safe to turn off the computer especially if it is an old computer. For newer computers it may shut off automatically after it completes the Shutdown procedures. Another alternative could be that your hard drive is going bad. If this is the case you might want to consider logging in as the local administrator or power user so that you can run a "Scan Disk" on the drive to try and detect bad sectors so that the operating system does not write on them and it can also try to self-repair itself as well. It will usually take a bit longer than a regular scan because it will try to fix the bad sectors it finds but again heres how you can do that. In XP you can go about doing this by clicking on start %26gt; then click on run %26gt; type in this new box "cmd" then hit ok or enter. %26gt; This should bring up a black box that you can type in %26gt; Type the following:





chkdsk /f





There is a space in between the dsk part and the /f.


Once this is entered, hit "Enter" on your keyboard and it will prompt you most likely saying that the disk is in use or cannot be mounted which means it cannot be scanned because you are running Windows on it. Just simply hit "Y" for yes and it will prompt you with a success message saying that it should run next time you restart. Restart when desired and the utility will run. If you find that you repeatedly have to perform this operation to fix the Disk Checks upon startup you might want to start considering buying a new hard drive to replace the one you have as these are signs of the physical hardware starting to fail. You can obtain one from any local computer repair shops or your computer manufacturer if you went through any. Good luck and I hope this helps.