Click to See Complete Forum and Search --> : Can I create a report without having any database... Pls don't rate it negative.. :-)
Dr_Michael
October 12th, 1999, 09:16 AM
Can it be a report without having a database?
I mean: can I design a report which will print not fields from database, but fields from my form?
Michael Vlastos
Automation Engineer
Company Modus SA
Development Department
Athens, Greece
Lothar Haensler
October 12th, 1999, 09:47 AM
Yes, you can!
You can even use data-binding!
That's because with ADO you can create recordsets on the fly, i.e. recordsets that have NO CONNECTION to a database.
Dr_Michael
October 12th, 1999, 09:54 AM
waiting your post with details on how to print text boxes (values from) of a form to a data report!
Michael Vlastos
Automation Engineer
Company Modus SA
Development Department
Athens, Greece
Lothar Haensler
October 12th, 1999, 10:02 AM
here is an excerpt of code and documentation from one of my projects:
add a DataReport to your project.
name it "dr"
right click on the Data report design window and "insert control/textBox"
set the DataField property to "Subject"
repeat this process for all your fields.
add the following code:
myrs.Fields("Body") = "Body"
set dr.DataSource = myrs
dr.Show
That's it.
well, kind of. You still need to create the recordset in your vb program. This looks similar to the following pcode
dim rs as new adodb.recordset
rs.fields.append fieldname, fieldtype
rs.fields.append fieldname, fieldtype
...
rs.open
rs.addnew
...
and so on.
Some assembly required. Should help you getting started...
Dr_Michael
October 12th, 1999, 10:11 AM
one more time. Well I'll try it tomorrow (must go to dentist now). Thanx a lot, I think it will work (spent some time on it). I'll try and let you know if I need any further help. Thank you!!!
Michael Vlastos
Automation Engineer
Company Modus SA
Development Department
Athens, Greece
codeguru.com
Copyright Internet.com Inc., All Rights Reserved.