yeah it is a vb6 project.
>From what i understand, with vb you can pretty much do whatever you
want with applications. So, i'm opening excel, doing all sort of stuff
with it, etc.
sample of my code :
....
Cells(1, 1).Select
Rows(Selection.Row).Insert shift:=xlUp
Cells(1, 1).Select
ActiveCell.Value = "Unité Administrative"
Cells(1, 2).Select
ActiveCell.Value = "Poste de travail"
....
Then i'm opening access, the program imports both my excel sheets that
have been saved prior to this. Then, with slq text, i make 3-4 requests
with the tables created with the import of the excel sheets. something
like this :
....
slqtext = "TRANSFORM Count([installs].[Poste de travail]) AS
[CompteDePoste de travail] SELECT [installs].[Unité Administrative]
>From installs, total, uachoisi Where ((([installs].[Unité
Administrative]) Like [uachoisi]![uachoisi])) GROUP BY
[installs].[Unité Administrative] PIVOT total.total;"
'on crée la requete
For Each qry In CurrentDb.QueryDefs
If qry.Name = "totalpartiel" Then
CurrentDb.QueryDefs.Delete ("totalpartiel")
End If
Next
Set req = CurrentDb.CreateQueryDef("totalpartiel", slqtext)
....
its all working very well. I know its not pretty but it still works
fine.
In the database that i'm using via my vb program. I have a report that
i need the user to see. I want the user to be able to click on a button
in the vb form of my .exe and see the report. So the button would do
something like this:
....
open access
open report in view mode
ask the user to close when finished viewing or something
<---------possible or no ?
ask for print ( optional )
quit access
....
Its possible to have a sub that prints the report, but to view it, the
sub would have to kinda "stop" if you see what i mean. That's where i
dont know what to do.
I'm thinking i could copy/paste the code generated with the creation of
the button in a form in access maybe, i dont know.
I hope i made myself clearer. I know i'm not good in expressing myself
uin english.
Thx in advance
Alex