need help - Access to DLL to Access (1 Viewer)

smig

Registered User.
Local time
Today, 23:58
Joined
Nov 25, 2009
Messages
2,209
here is my situation.

I want to create a small tightly closed access database for tax data that will be accessed via DLL only.
what I mean by tightly clsed is that it will not be accessiable. not even linking to tables. only by the DLL. how do I do that ?

the db must be tightly closed for the tax authorities.

the DLL itself should have few functions to create data in this closed database.
example:
fn_CreateInvoice(InvoiceDate as Date, InvoiceDescription as String, InvoiceItems as Invoice.Items)

I want it to be in DLL because I want the db to be used by any VB/.Net/Access... application.

I have no idea how to create a DLL. never did that. never wrote in C, C++

Thanks :)
 

Rank Am

Registered User.
Local time
Tomorrow, 04:58
Joined
Apr 30, 2005
Messages
68
I don't think that you can write DLL's using VBA you would have to use .NET / visual studio or some other language.
You can use VBA class modules and collections and compile these into an MDE but if you require robust user security and access restrictions SQL server using stored procedures on the server would be the way to go.

Regards

Jon
 

smig

Registered User.
Local time
Today, 23:58
Joined
Nov 25, 2009
Messages
2,209
thanks for the quick reply :)

some db that got the tax authority OK are done in Access, so I guess I'll be OK with this too. no need for SQL server.

I tried one application that did it and created a DLL as an API to their main access db application. unfortunately I can't find all the details I need in it, and get no reply from their technical assistance, so I think of creating a one of my oun.

the DLL should only be used as a link from one application to the other. a function in the DLL will invoke a function in access to store/get data.
 

DCrake

Remembered
Local time
Today, 21:58
Joined
Jun 8, 2005
Messages
8,632
You should be able to use VB 6.0 to make DLL's, OCX's, EXE's etc
 

gemma-the-husky

Super Moderator
Staff member
Local time
Today, 21:58
Joined
Sep 12, 2006
Messages
15,694
I take it you are concerned that users could see the data, or change the data without going through appropriate controls -

this is normal to do in access though anyway. - its just a matter of designing an appropriate interface.
 

smig

Registered User.
Local time
Today, 23:58
Joined
Nov 25, 2009
Messages
2,209
let me put some more light on this:
I made an application for a small office client.
this application include all the data they need - clients management, service schedules.... it also include all the money income services - invoices and receipts.

now my client want all his money data to be authorized by the tax authority.
I'm trying several access made tax applications that also include an API to be used by outside applications (in this case mine).
these applications are full scale applications, which I don't need. I don't need big parts of them, and I don't need all the interface they made. for me it's not a big problem. they are expensive, and my client will pay for them not me.

this led me to the idea of creating a low scale application with very minimal interface, only the required reports for the tax authority, that will be used by users like myself.
as I spoke to one of the companies they don't use an API but I need to link to their tables, mean tight closing the tables might not be required.

Thanks again
 

Banana

split with a cherry atop.
Local time
Today, 13:58
Joined
Sep 1, 2005
Messages
6,318
I'm kind of lost on the what is the real objective here.

You say you do not want anyone to access the data directly on the backend application so you want to use the DLL. If I'm following you, the backend itself is Access as well. Which means that any one in the office can just create a new blank database and link to that backend directly. In other words, all you would accomplish is making your front-end application less robust without actually securing the data.

A more practical approach would be:

1) As suggested already, move the data to a server-based RDBMS (doesn't have to be SQL Server. Can be MySQL, PostgreSQL, Oracle Lite, whatever)

2) Trust the users but deny access to nonusers by using filesystem permissions (e.g. restrict the folder where the data is to only those who actually need it)

3) (NOTE: Highly theoretical and untested!) Expanding upon #2, Use RunAs within the application to change to an account that has permissions to the backend and nothing else, thus forcing your users to go through the Access.


Maybe your DLL already does a variant of #3 in which it would actually make sense but I want to point out that if this isn't being done, then it's just more work for no gain because the users can just go to the data folder and link there directly in a blank database.
 

vbaInet

AWF VIP
Local time
Today, 21:58
Joined
Jan 22, 2010
Messages
26,374
now my client want all his money data to be authorized by the tax authority.
I'm trying several access made tax applications that also include an API to be used by outside applications (in this case mine).
these applications are full scale applications, which I don't need. I don't need big parts of them, and I don't need all the interface they made. for me it's not a big problem. they are expensive, and my client will pay for them not me.
Suggestion: If accessed externally by the Tax Authority which I guess is not located on the same network or location, then create a web interface just for that (tax) module of your db, and control access to it through that interface.
 

smig

Registered User.
Local time
Today, 23:58
Joined
Nov 25, 2009
Messages
2,209
all I need is some help/advice creting the DLL that will be an interface from one database to the other.
just think of using a DLL instead of linking the tables from the back end to the front end.
As I said I have no previous experience creating a DLL, and I don't know exactly how they work.

why I want to use a DLL, and not linking to tables ?
1. I want it to be registered into Access through the objects references. I think it's a more clean way doing it and no need for relinking with any new version installed
2. I'll might want to disable any other way connecting/linking to the tables. this is not sure yet.

I need no help in Access itself. I use access for the last 15 years, since Access 2
 

Users who are viewing this thread

Top Bottom