Anyone ever done programming

Anyone ever done programming

Re: Anyone ever done programming Posted by Wild Card on Tue Feb 17th 2004 at 4:13pm
Wild Card
2321 posts
Posted 2004-02-17 4:13pm
2321 posts 391 snarkmarks Registered: May 20th 2002 Occupation: IT Consultant Location: Ontario, Canada
I took 2 years of Delphi programming at school, well, 2 classes over 2 years. And each year I surpased the class and last year, surpassed the teacher :biggrin:

I made a database program for cadets. It combines administration such as:

A cadets (persons) personnal information
A cadets rank and accomplishments
Attendances
Inspections
Diciplinary reports

Training which includes

what level the cadet is at
what classes he/she passed or failed
marks obtained

and Supply

what equipement/uniform parts the cadet borrowed
measurements of the cadets

...

Now that is all fine and dandy. When the program loads, you must enter your username and password. The main page has buttons for each of the above mentioned sections (Admin, trg, supply) and the program administrator has an ADMIN button to create/delete/modify users. Users are limited to certain sections of the program.

The question I have is: I have a DB_grid which displays information like last name, first name, phone number, street address. I need to put a button which will allow me to print this said list of information. Either by having it print what the DB_grid is displaying or by making it do a "print screen" and then printing it automatically.

Does anyone know how to do this?

I have searched the online help books and they dont help. My teacher dosent know how either. Heck I had to show him how to make the database :biggrin:

Ideas?

Thanks,
Wild Card
Re: Anyone ever done programming Posted by Pegs on Tue Feb 17th 2004 at 4:36pm
Pegs
312 posts
Posted 2004-02-17 4:36pm
Pegs
member
312 posts 41 snarkmarks Registered: Aug 30th 2003 Location: England
hmm soz i dont program. :sad:

Anyway you lost me at the start :wtf: .
Not realy i sort of now what you mean by Admin etc but there is no way i could help you, soz
Re: Anyone ever done programming Posted by scary_jeff on Tue Feb 17th 2004 at 4:52pm
scary_jeff
1614 posts
Posted 2004-02-17 4:52pm
1614 posts 191 snarkmarks Registered: Aug 22nd 2001
Did you try looking up 'print' on MSDN? I'm not sure, but that might only have C++ information. I'm sure crono will know, and will probably be able to say that what I said is bs in the process :smile:
Re: Anyone ever done programming Posted by matt on Tue Feb 17th 2004 at 4:57pm
matt
1100 posts
Posted 2004-02-17 4:57pm
matt
member
1100 posts 246 snarkmarks Registered: Jun 26th 2002 Occupation: Student! Location: Edinburgh
I had a homework task about Pascal from computing ages ago. Never again
Re: Anyone ever done programming Posted by Wild Card on Tue Feb 17th 2004 at 8:22pm
Wild Card
2321 posts
Posted 2004-02-17 8:22pm
2321 posts 391 snarkmarks Registered: May 20th 2002 Occupation: IT Consultant Location: Ontario, Canada
The only reference to "printing" I could find was this.

They define printing not as information comming out on a piece of paper but information being displayed on your screen. If you click a button, it "prints" the information on the screen for you. That dosent help much, lol :grenade:
Re: Anyone ever done programming Posted by Crono on Tue Feb 17th 2004 at 9:05pm
Crono
6628 posts
Posted 2004-02-17 9:05pm
Crono
super admin
6628 posts 700 snarkmarks Registered: Dec 19th 2003 Location: Oregon, USA
Yes, in almost any programming language "print" mean send numbers to screen.

Dude, Pascal? wtf lol. Try a manly language that lets you control the memory better lol.

Anyway . . . geez, I've never used Pascal before . . . Never needed to. By the way, this database you made, is like crap I have to do for all my assignments, and we only have 2 weeks, because it's not as hard, it's just how you did it. Such as, what data structure/s did you use?

Jeff . . . you couldn't be more right lol. Actually no, here's the problem. If you developed it on a Microsoft machine, or for a Microsoft machine, you should use microsofts printer library. Because printers, believe it or not, have their own language, and the one that is ONLY reconizeable by windows (by default) is GDI I believe, it's been a while so forgive me if that's wrong. Anyway, it meant it's Windows ready ... bad part, try using it with Unix. the printer will be a bitch. You can make it work it's just harder.

So, if you're doing it for Unix, you could find a printer library. I'm not really sure, since I've never sent information to a printer before . . . I'm sure you can send it to a file and let that be printed out automatically by another function (most likely in a library somewhere).

Anyway, I'll look up some pascal stuff and see if I can't help more. . . :smile:

[EDIT]
Also, you have to remember, even though Pascal is still used (sometimes) it's a REALLY old language, we're talkin right after Fortran-punch-cards-oh-my-God-there's-this-language-which-requires-a-monitor lol, So, it might not have major support for printers of today (Obviously a dot matrix printer works completly different then a laser printer or a ink jet, and yes, if you wrote your own integration for one, you'd have to write it for all, especially if you're gonna give this to people).
[/EDIT]
Re: Anyone ever done programming Posted by Wild Card on Tue Feb 17th 2004 at 9:40pm
Wild Card
2321 posts
Posted 2004-02-17 9:40pm
2321 posts 391 snarkmarks Registered: May 20th 2002 Occupation: IT Consultant Location: Ontario, Canada
Well the reason Im doing it in Pascal is because its the first language I learned and the only other one is Java which I hate, I cant do anything in it lol.

Im using standard tables for the database.. none of that SQL stuff.. I think it was paradox something like that.

And its for Windows machines.
Re: Anyone ever done programming Posted by Wild Card on Tue Feb 17th 2004 at 9:41pm
Wild Card
2321 posts
Posted 2004-02-17 9:41pm
2321 posts 391 snarkmarks Registered: May 20th 2002 Occupation: IT Consultant Location: Ontario, Canada
or maybe have it do a print screen and then print that off?
Re: Anyone ever done programming Posted by Crono on Tue Feb 17th 2004 at 9:53pm
Crono
6628 posts
Posted 2004-02-17 9:53pm
Crono
super admin
6628 posts 700 snarkmarks Registered: Dec 19th 2003 Location: Oregon, USA
First of all, Java is way more powerful then Pascal, just to let you know. Not nessesarily faster at run time lol. But more Powerful.

Uh, I'm not quite sure actually, I know for a fact with Java Sun would have made a printer library (I mean they released data structure libraries pre made). . .why do you hate Java? lol

my suggestion was to write the data to a file, then send that file to a print que of somesort. Which is probably in a Windows library somewhere.

Print screen is sending stuff to the monitor, unless the library functions need you to have your stuff in the output buffer I don't suggest it, unless the person wishes to see the stuff before it's printed of course, but in that case, I'd suggest showing them the file you should be outputting to the printer, because that should be exactly what the print out will look like. So if you wanted you could add in stuff like the program name and things like that in the file. All sorts of crazy crap lol.

Again, I haven't messed with Pascal too much, so.
Re: Anyone ever done programming Posted by Wild Card on Tue Feb 17th 2004 at 9:59pm
Wild Card
2321 posts
Posted 2004-02-17 9:59pm
2321 posts 391 snarkmarks Registered: May 20th 2002 Occupation: IT Consultant Location: Ontario, Canada
Crono said:
First of all, Java is way more powerful then Pascal, just to let you know. Not nessesarily faster at run time lol. But more Powerful.
lmao! Agreed.
my suggestion was to write the data to a file, then send that file to a print que of somesort. Which is probably in a Windows library somewhere.
I dont understand. Is this a solution to printing? If so, how do I go abouts to doing that?
Re: Anyone ever done programming Posted by Leperous on Tue Feb 17th 2004 at 10:12pm
Leperous
3382 posts
Posted 2004-02-17 10:12pm
Leperous
Creator of SnarkPit!
member
3382 posts 1635 snarkmarks Registered: Aug 21st 2001 Occupation: Lazy student Location: UK
You could always use mySQL and PHP to do that :biggrin: