352 Posted Topics
Author: [I] ================================================================================ Crt Unit Read-Me By: Will DeWitt Jr. (edge@boink.net) Mar 21st, 2003 ================================================================================ BRIEF NOTES AND INFORMATION: This unit was created primarily to support my development of console mode applications under Delphi. I've tested this unit and had it successfully works under Delphi 2, 3, 4, 5, 6 … | |
Re: I can programming in turbo pascal like i did it on xp! | |
Re: unplug the internet cable from your computer,and remove the lan card if there are any.Or if it is integrated on your motherboard then you can disable it under the B.I.O.S. | |
Re: [CODE=pascal] program solution31; uses crt,dos; var name_and_path,s,temp:string; f,f2:text; c:char; counter:word; begin (*main*) clrscr; counter:=0; writeln('give me the file''s name and its path: '); readln(name_and_path); assign(f2,'c:\bp\file\other.txt'); rewrite(f2); assign(f,name_and_path); {$I-} reset(f); {$I+} if ioresult <> 0 then begin writeln('file reset error'); readln; halt; end; writeln('the file''s contents: '); while not eof(f) do … | |
Re: [URL="http://www.daniweb.com/forums/misc-explaincode.html"]http://www.daniweb.com/forums/misc-explaincode.html[/URL] | |
Re: [CODE=pascal] program solution28; uses crt,dos; type newtype = string[20]; var f:file of newtype; procedure game_over(s:string); begin writeln(s); writeln('press enter to quit.'); readln; halt; end; procedure write_in; var x:newtype; begin assign(f,'new.dat'); {$I-} rewrite(f); {$I+} if ioresult <> 0 then game_over('file rewrite error'); write('give me your string: '); readln(x); write(f,x); close(f); end; … | |
Re: the main algorithm of the shearching..... :D [code=pascal] (* found:=false; i:=0; while (i <= N) and (found = false) do begin i:=i+1; reach the i. element; found:=i. element's property; end; *) (*or if we don't know the number of the elements*) (* found:=false; i:=0; reach the i. element +1; while … | |
Re: control panel ->windows update set to auto maybe this helps | |
Re: is your windows dvd original?If yes then you can go to the microsoft home page and ask them,maybe they can help to you.(i hope that your win7 is not a rc version cause these beta versions will die)..if not then,try to format your hard drive with the windows xp cd,use … | |
Re: I think this is a linked list....try the google ,and read about linked lists... Alert if you need help yet | |
Re: hi append() works only with text files :D [CODE=pascal] program typed_files; uses crt; type newrec = record name:string[50]; job:string[20]; end; var one:newrec; f:file of newrec; is_created:boolean; choice:char; procedure press; begin write('Press enter to continue'); readln; end; procedure create_file; begin assign(f,'myfile.dat'); {$I-} rewrite(f); {$I+} if ioresult <> 0 then begin writeln('error … | |
Re: I think that you do understand the for loop first,and then the shoriting algorithm. I made a program that shorts an array [code=pascal] program forloop; uses crt; var a:array[1..10]of byte; temp:byte; i,k:byte; begin clrscr; (*fill the array with random numbers*) randomize; for i:=1 to 10 do begin a[i]:=random(100)+1; end; (*write … | |
Re: [CODE=pascal] (* Problem is next. I need to change row right to left and i need to save entered numbers to "input.txt" and save reversed rows to "output.txt". I have tried something and then crashes pascal or i get blank txt file. *) program sol01; uses crt; var t:array[1..3,1..3] of … | |
Re: on the form's onshow events : [CODE=delphi] unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls; type TForm1 = class(TForm) Edit1: TEdit; procedure FormShow(Sender: TObject); private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.dfm} procedure TForm1.FormShow(Sender: TObject); … | |
Re: [CODE=pascal] program something; uses crt; type directory = record line:string[1]; end; a = array[1..2500]of directory; procedure saving(input:a); var i:integer; f:file of directory; begin assign(f,'c:\input.dat'); {$I-} rewrite(f); {$I+} if ioresult = 0 then begin for i:=1 to 2500 do begin write(f,input[i]); end; close(f); end else writeln('error when writting to the file'); … | |
Re: Hi I'm using a pioneer dvd-rw dvr-109 ata,and a pioneer dvd-rw dvr-110 also ata,about three years,and no problems with them. And my burning program is the ImgBurn. ImgBurn supports all the Windows OS's - Windows 95, 98, Me, NT4, 2000, XP, 2003, Vista, 2008 and 7 (including all the 64-bit … | |
Re: I found some info about your problem,maybe win7 but same the problem site: [URL="http://www.unawave.de/windows-7-tipps/code5-error.html?lang=EN"]http://www.unawave.de/windows-7-tipps/code5-error.html?lang=EN[/URL] | |
Re: I used delete procedure as [b] finalist [/b] did it. Just I do it a bit otherwise. [code=pascal] program remove_pound; uses crt, sysutils; var s: string; (*this stores maximum 255 character,this can be treat as array too*) p: char; (*this holds only one character*) i:byte; (*loop variable*) temp:string;(*temp var*) count:integer; … | |
Re: I know that this thread already solved,but I made another solution. [CODE=pascal] program lengths; uses crt; var s:string[120]; begin write('please enter your length: '); readln(s); while (length(s) < 10) or (length(s) > 120) do begin write('please enter your length: '); readln(s); end; writeln('Ok.'); readln; end. (*by FlamingClaw 2010.01.24.*) [/CODE] | |
Re: [URL="http://delphi.about.com/od/beginners/l/blrtldatetime.htm"]http://delphi.about.com/od/beginners/l/blrtldatetime.htm[/URL] good luck | |
Re: here you can find lot of information about valid or not valid e-mail [URL="http://www.latiumsoftware.com/en/pascal/0022.php#3"]http://www.latiumsoftware.com/en/pascal/0022.php#3[/URL] | |
Re: First write some code about your problem...ok? What do you want exactly?To create a typed file,and search in its contents,with the seek command?Write about your problem a bit more,thank you. | |
Re: There are a lot of shorting algorithm [URL="http://en.wikipedia.org/wiki/Sorting_algorithm"]http://en.wikipedia.org/wiki/Sorting_algorithm[/URL] | |
Re: The Form Event Section can be set this parameters [CODE=delphi] procedure TForm1.FormShow(Sender: TObject); begin Form1.Width:=1024; Form1.Height:=768; end; [/CODE] | |
Re: Is your program a console app? Maybe I can help you,just want to know that where is your code? Pascal or delphi? I made one console app in pascal [CODE=pascal] program text_files; uses crt; var FromFile,ToFile :text; i,num:byte; begin clrscr; (*we create two files*) assign(FromFile,'c:\From.txt'); assign(ToFile,'c:\To.txt'); rewrite(FromFile); rewrite(ToFile); randomize; (*ok,let's … | |
Re: we need the ascii code table to create this application... :D [CODE=pascal] Program box; uses Crt; (*your procedure same as the procedure window in the crt unit...*) procedure draw(x1,y1,x2,y2:integer); (*local procedure line1*) procedure line1(a,b,c,e:integer); (*writes a - line to the screen*) (*a and b are the starting position*) begin gotoxy(a,b); … | |
Re: [CODE=pascal] (*my program is one alternative*) (* 1, create a program that contain 10 basic math questions. *) program main; uses crt; (*new types section*) type questions = record q:string;{the question} a:string;{the answer} r:boolean;{if answer is good then set to true,else false} end; Aquestion = array[1..10]of questions;{array that contains the … | |
Re: in pascal 123 error code meaning is the follows: Too much symbol.The program or unit declares too much symbol.Try to divide for parts your code.Or try to compile your code with the $D- | |
Re: Here you can find some unicode languages..... :D [URL="http://www.jrsoftware.org/files/istrans/"]http://www.jrsoftware.org/files/istrans/[/URL] | |
Re: What do you want to exactly?To create an app that shows an edit box and waits for the password and if it is right then send a message that it is good else send a message it is bad? | |
Re: solution here : [URL="http://www.programmersheaven.com/mb/pasprog/135405/135405/cpu-speed/?S=B20000"]http://www.programmersheaven.com/mb/pasprog/135405/135405/cpu-speed/?S=B20000[/URL] | |
Re: function FindComponent(const AName: string): TComponent; Description FindComponent returns the component in the Components property array with the name that matches the string in the AName parameter. Use FindComponent to determine whether a given component is owned by another. Component name matches are not case sensitive. maybe this can help you | |
Re: I found this,maybe can help :D [B]Why do I get the error "xx.dcu file not found" or "xx.pas file not found" when running or compiling my application in Delphi.[/B] The directory where you have installed the components is not listed in the Delphi Library Search Path. If you select tools … | |
Re: a lot of delphi components are found here [URL="http://www.synchrondata.com/pheaven/www/area44.htm"]http://www.synchrondata.com/pheaven/www/area44.htm[/URL] or jump directly [URL="http://www.programmersheaven.com/"]http://www.programmersheaven.com/[/URL] | |
Re: try to look at home page [URL="http://www.tatukgis.com/Home/home.aspx"]http://www.tatukgis.com/Home/home.aspx[/URL] Maybe they can help you.... | |
Re: You have to learn more about procedures,and its parameters :D I fixed your code :D [code=pascal] program sablon; Uses Crt; var Answer : Real; AnswerB : Real; AnswerC : Real; {***} {FIXED HERE!NOW YOU CAN INITIALIZE THE THREE REAL NUMBERS} procedure GetData(VAR A,B,C:REAL); begin Writeln('Input value a'); Readln(A); Writeln('Input value … | |
Re: 50 digit? Are these significant digits? Please add more information about the problem. :'( | |
Re: you can find here [URL="http://h10025.www1.hp.com/ewfrf/wc/softwareList?os=228&lc=en&cc=us&product=1842155&dlc=en"]http://h10025.www1.hp.com/ewfrf/wc/softwareList?os=228&lc=en&cc=us&product=1842155&dlc=en[/URL] | |
Re: first let's see the algorithm (a+b+c)/3 i made it in console application [code=delphi] program average; {$APPTYPE CONSOLE} uses SysUtils; var a,b,c,e:real; begin write('first number: ':20); readln(a); write('second number: ':20); readln(b); write('third number: ':20); readln(c); e:=(a+b+c)/3; write('the average : ':20,e:0:2); readln; end. {created by FlamingClaw 2009} [/code] | |
Re: i overwrite your program a bit :D written in dev pascal 1.9.2 [code=pascal] {game against the computer} program game_by_FlamingClaw; uses crt; type properties = record name:string[10]; attack:integer; defense:integer; health:integer; damage:integer; death:boolean; numberof_p:1..3;{number of potions} end; {forwarded functions and procedures} function takeonepotion(p:byte;var x:properties):boolean;forward; function who_begins:byte;forward; procedure statusmenu(one:properties);forward; procedure statusmenu2(two:properties);forward; procedure fight(var … | |
Re: i have an alternative,of course it is working well :D i made it with dev-pascal 1.9.2 [code=pascal] program sablon; uses crt; {"I want to have 2 characters."} type characters = record health:integer; {health point} attack:byte; {attack point} speed:byte; {and the speed point} end; const stab = 10; punch = 15; … | |
Re: in variables you can store these values | |
Re: one button,2 labels [code=delphi] procedure TForm1.Button1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); begin LABEL1.Caption:='1-34-56-778-888999-1000'; end; procedure TForm1.Button1MouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); begin LABEL2.Caption:='BUTTON RELEASED.'; end; { when you press the button then the label1's caption is the serial,and when you release the button then … | |
Re: delphi 7 has got a known problem when you install it under win 7,use a virtual machine such as microsoft virtual machine,install an xp and install delphi 7 too... | |
Re: one million records....that's nice ..... where do you store them,in a file or in the memory(is this a linked list?)? | |
Re: catch the reset(filevar) [CODE=pascal] {$I-} reset(f); {$I+} if ioresult <> 0 then writeln('error when trying to open the file'); [/CODE] | |
Re: I made a pascal source code :D [CODE=pascal] program sablon; uses crt; type range = 1..65535; const ok = 'ok.'; error = 'error'; min = 1; var one:longint; two:range; user,temp:string; function converter(x:string):string; var code:integer; begin two:=65535; {$I-} val(x,one,code); if (ioresult <> 0) then begin converter:=error; exit; end; if (code <> … |
The End.