Printing database information.
Posted: Tue Dec 02, 2014 5:46 am
Being extremely new to this, and on my first project to learn PB I am having a little trouble understanding the print function.
What I am currently trying to do is write a procedure to allow a user click the print button and print the schedule stored in the DB.
Currently I have a schedule that will display in the window from the DB... all columns populate the text gadgets with out error.
I added a button gadget to the code to allow a printing of the schedule once a user is in that window.
I have added the call from the button to the procedure getprint()
From what I know and have learned I need to query the DB for the information in the table I am looking at and store it (in this case schedule$)
I did this and ran debug to make sure the data was loading and it showed the data from column 0 to be correct. I'm not aware if you can do a debug for all columns in the DB table or not... I only know of the debug GetDatabaseString(#database, 0). When I ran this it did show the correct data from that column in the DB.
However I am having trouble trying to write the code to print the data that is in the DB table, which is sports game schedule. I did look at the IDE help file to try to get a better understanding of how to implement the print function into the program but have been unsuccessful so far.
I have looked at some of the examples in the help file for printing, but none of the examples offer insight on how I could apply them to my need.
Is it possible for someone to offer a push in the right direction so I can learn what needs to be done to do this?
I need to learn how to write the code to actually print what I have queried from the DB.
Any help is greatly appreciated.
73s
What I am currently trying to do is write a procedure to allow a user click the print button and print the schedule stored in the DB.
Currently I have a schedule that will display in the window from the DB... all columns populate the text gadgets with out error.
I added a button gadget to the code to allow a printing of the schedule once a user is in that window.
I have added the call from the button to the procedure getprint()
From what I know and have learned I need to query the DB for the information in the table I am looking at and store it (in this case schedule$)
I did this and ran debug to make sure the data was loading and it showed the data from column 0 to be correct. I'm not aware if you can do a debug for all columns in the DB table or not... I only know of the debug GetDatabaseString(#database, 0). When I ran this it did show the correct data from that column in the DB.
However I am having trouble trying to write the code to print the data that is in the DB table, which is sports game schedule. I did look at the IDE help file to try to get a better understanding of how to implement the print function into the program but have been unsuccessful so far.
I have looked at some of the examples in the help file for printing, but none of the examples offer insight on how I could apply them to my need.
Is it possible for someone to offer a push in the right direction so I can learn what needs to be done to do this?
I need to learn how to write the code to actually print what I have queried from the DB.
Any help is greatly appreciated.
73s