* Re: Telephone / Address directory program? (fwd)
@ rmann
` Georgina
0 siblings, 1 reply; 2+ messages in thread
From: rmann @ UTC (permalink / raw)
To: speakup
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1863 bytes --]
I meant "g++ -o address address.cpp"
---------- Forwarded message ----------
Date: Wed, 16 Jan 2002 19:52:29 -0500 (EST)
From: rmann@rmisp.net
To: speakup@braille.uwo.ca
Subject: Re: Telephone / Address directory program?
Hi.
I've attached a simple program to store People's addresses. To compile
it, do "gcc -o address address.cpp".
On Wed, 16 Jan 2002, Raul A. Gallegos wrote:
> Georgina said the following on Wed, Jan 16, 2002 at 11:23:02PM +0000:
> > Hi
>
> Howdy.
>
> > I wondered if there were any handy terminal programs for storing telephone numbers and addresses. While I've been playing with postgresql, I don't know variations of the select statements well enough for this simple task. It feels like using a sledge hammer for a very small nut. I'm just looking for a small program that I as a single user can enter names, addresses and telephone numbers and retrieve quite easily. Any ideas?
>
>
> I don't remember which distro you use but there is a Debian package
> which I use and works quite well. If you don't use Debian I'm sure you
> can find it from freshmeat.net and install it manually.
>
> Package: abook
> Priority: optional
> Section: mail
> Installed-Size: 176
> Maintainer: Alan Ford <alan@whirlnet.co.uk>
> Architecture: i386
> Version: 0.4.14-1
> Depends: libc6 (>= 2.2.3-7), libncurses5 (>= 5.2.20010310-1)
> Filename: pool/main/a/abook/abook_0.4.14-1_i386.deb
> Size: 34556
> MD5sum: 39683e77a3ad53bcd551865b82c5e7c5
> Description: A text-based ncurses address book application.
> abook is a text-based ncurses address book application. It provides
> many
> different fields of user info. abook is designed for use with mutt, but
> can be used independently.
>
> _______________________________________________
> Speakup mailing list
> Speakup@braille.uwo.ca
> http://speech.braille.uwo.ca/mailman/listinfo/speakup
>
[-- Attachment #2: Type: TEXT/PLAIN, Size: 1167 bytes --]
#include <iostream.h>
#include <fstream.h>//header file for file IO
int main()
{
char name[30];
char address[30];
char city[30];
char state[3];
char zip[6];
char phone[13];
int cont = 1;
ofstream outfile;
outfile.open("address.txt", ios::app);
if(outfile)
{
while(cont != 0)
{
cout << "Enter the person's name.\n";
cin.get(name, 30);
cin.ignore(80, '\n');
cout << "Enter the person's address.\n";
cin.get(address, 30);
cin.ignore(80, '\n');
cout << "Enter the city.\n";
cin.get(city, 30);
cin.ignore(80, '\n');
cout << "Enter the two letter state abreviation.\n";
cin.get(state, 3);
cin.ignore(80, '\n');
cout << "Enter the postal code.\n";
cin.get(zip, 6);
cin.ignore(80, '\n');
cout << "Enter the phone number.\n";
cin.get(phone, 13);
cin.ignore(80, '\n');
outfile << name << "\n";
outfile << address << "\n";
outfile << city << "\n";
outfile << state << ",";
outfile << zip << "\n";
outfile << phone << "\n";
cout << "To quit this program type 0 then return.\n";
cout << "Type return to continue.\n";
cin >> cont;
}
}
else
{
cout << "Their was an error opening the file.\n";
}
outfile.close();
return 0;
}
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: Telephone / Address directory program? (fwd)
Telephone / Address directory program? (fwd) rmann
@ ` Georgina
0 siblings, 0 replies; 2+ messages in thread
From: Georgina @ UTC (permalink / raw)
To: speakup
Hi
Well thanks to all, I've installed abook and had a brief look at how it works. But I'm interested in the attached c++ code. I will enjoy examining it more closely. Thank you.
Gena
> This message is in MIME format. The first part should be readable text,
> while the remaining parts are likely unreadable without MIME-aware tools.
> Send mail to mime@docserver.cac.washington.edu for more info.
>
>--655616-122326073-1011228749=:6649
>Content-Type: TEXT/PLAIN; CHARSET=US-ASCII
>Content-ID: <Pine.LNX.4.33.0201161959232.6748@rmnet>
>
>
>I meant "g++ -o address address.cpp"
>
>
>---------- Forwarded message ----------
>Date: Wed, 16 Jan 2002 19:52:29 -0500 (EST)
>From: rmann@rmisp.net
>To: speakup@braille.uwo.ca
>Subject: Re: Telephone / Address directory program?
>
>Hi.
>I've attached a simple program to store People's addresses. To compile
>it, do "gcc -o address address.cpp".
>
>
>On Wed, 16 Jan 2002, Raul A. Gallegos wrote:
>
>> Georgina said the following on Wed, Jan 16, 2002 at 11:23:02PM +0000:
>> > Hi
>>
>> Howdy.
>>
>> > I wondered if there were any handy terminal programs for storing telephone
numbers and addresses. While I've been playing with postgresql, I don't know
variations of the select statements well enough for this simple task. It feels
like using a sledge hammer for a very small nut. I'm just looking for a small
program that I as a single user can enter names, addresses and telephone numbe
rs and retrieve quite easily. Any ideas?
>>
>>
>> I don't remember which distro you use but there is a Debian package
>> which I use and works quite well. If you don't use Debian I'm sure you
>> can find it from freshmeat.net and install it manually.
>>
>> Package: abook
>> Priority: optional
>> Section: mail
>> Installed-Size: 176
>> Maintainer: Alan Ford <alan@whirlnet.co.uk>
>> Architecture: i386
>> Version: 0.4.14-1
>> Depends: libc6 (>= 2.2.3-7), libncurses5 (>= 5.2.20010310-1)
>> Filename: pool/main/a/abook/abook_0.4.14-1_i386.deb
>> Size: 34556
>> MD5sum: 39683e77a3ad53bcd551865b82c5e7c5
>> Description: A text-based ncurses address book application.
>> abook is a text-based ncurses address book application. It provides
>> many
>> different fields of user info. abook is designed for use with mutt, but
>> can be used independently.
>>
>> _______________________________________________
>> Speakup mailing list
>> Speakup@braille.uwo.ca
>> http://speech.braille.uwo.ca/mailman/listinfo/speakup
>>
>
>--655616-122326073-1011228749=:6649
>Content-Type: TEXT/PLAIN; CHARSET=US-ASCII; NAME="address.cpp"
>Content-Transfer-Encoding: BASE64
>Content-ID: <Pine.LNX.4.33.0201161952290.6649@rmnet>
>Content-Description:
>Content-Disposition: ATTACHMENT; FILENAME="address.cpp"
>
>I2luY2x1ZGUgPGlvc3RyZWFtLmg+DQojaW5jbHVkZSA8ZnN0cmVhbS5oPi8v
>aGVhZGVyIGZpbGUgZm9yIGZpbGUgSU8NCmludCBtYWluKCkNCnsNCmNoYXIg
>bmFtZVszMF07DQpjaGFyIGFkZHJlc3NbMzBdOw0KY2hhciBjaXR5WzMwXTsN
>CmNoYXIgc3RhdGVbM107DQpjaGFyIHppcFs2XTsNCmNoYXIgcGhvbmVbMTNd
>Ow0KaW50IGNvbnQgPSAxOw0Kb2ZzdHJlYW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QgdGhpcyBwcm9ncmFtIHR5cGUg
>MCB0aGVuIHJldHVybi5cbiI7DQpjb3V0IDw8ICJUeXBlIHJldHVybiB0byBj
>b250aW51ZS5cbiI7DQpjaW4gPj4gY29udDsNCn0NCn0NCmVsc2UNCnsNCglj
>b3V0IDw8ICJUaGVpciB3YXMgYW4gZXJyb3Igb3BlbmluZyB0aGUgZmlsZS5c
>biI7DQp9DQpvdXRmaWxlLmNsb3NlKCk7DQpyZXR1cm4gMDsNCn0NCg0K
>--655616-122326073-1011228749=:6649--
>
>_______________________________________________
>Speakup mailing list
>Speakup@braille.uwo.ca
>http://speech.braille.uwo.ca/mailman/listinfo/speakup
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~ UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
Telephone / Address directory program? (fwd) rmann
` Georgina
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).