By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,833 Members | 2,076 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,833 IT Pros & Developers. It's quick & easy.

Can I somehow convert a VB(A) Access program into VisualBasic .NET program ?

P: n/a
I have a rather old VisualBasic program which is included inside an Access *.mdb database.

So I guess it is an VisualBasic and not and VBA program.

Can I somehow automatically convert it into a VisualBasic program outside of Access
which is working on base of .NET ?

If yes: How do I do it ?

If no: Is there way of at least let me automatically convert it with a
minimum of additional manual changes/interventions?

Camille

Jun 18 '07 #1
Share this Question
Share on Google+
5 Replies


P: n/a
This is a Visual Basic for Applications program as it is inside an Access
DB.

Depending on what it does it may not be that easy (in particular if it uses
Access non db features such as opening forms etc...). Any compelling reason
for doing this ?

---
Patrice

"Camille Petersen" <cp*********@hotmail.coma écrit dans le message de
news: 46***********************@newsspool4.arcor-online.net...
>I have a rather old VisualBasic program which is included inside an Access
*.mdb database.

So I guess it is an VisualBasic and not and VBA program.

Can I somehow automatically convert it into a VisualBasic program outside
of Access
which is working on base of .NET ?

If yes: How do I do it ?

If no: Is there way of at least let me automatically convert it with a
minimum of additional manual changes/interventions?

Camille

Jun 18 '07 #2

P: n/a
On Jun 18, 11:30 am, cpet_mag...@hotmail.com (Camille Petersen) wrote:
I have a rather old VisualBasic program which is included inside an Access *.mdb database.

So I guess it is an VisualBasic and not and VBA program.

Can I somehow automatically convert it into a VisualBasic program outside of Access
which is working on base of .NET ?

If yes: How do I do it ?

If no: Is there way of at least let me automatically convert it with a
minimum of additional manual changes/interventions?
I know of no tool to convert VBA to VB.NET, but then I have never
looked for one. If on exists, Google should turn it up eventually.

But as another responder implies, the conversion would depend on how
complex the VBA appliction is. I recently converted a VBA application
I had written for personal use to VB.NET and it really wasn't too
hard. But then, it had no real user interface, it was invoked with a
macro and simply created a structure of HTML files based on the
content of a few tables. When I re-wrote in VB.NET I added a user
interface and converted the Access table structure to an XML file
instead. The whole process took me the better part of a Saturday. Of
course, the more experiance you have with VB.NET the better.

Jun 18 '07 #3

P: n/a
On Jun 18, 4:30 pm, cpet_mag...@hotmail.com (Camille Petersen) wrote:
I have a rather old VisualBasic program which is included inside an Access *.mdb database.

So I guess it is an VisualBasic and not and VBA program.

Can I somehow automatically convert it into a VisualBasic program outside of Access
which is working on base of .NET ?

If yes: How do I do it ?

If no: Is there way of at least let me automatically convert it with a
minimum of additional manual changes/interventions?

Camille
Hi Camille,

VB inside MS Access is VBA (Visual Basic for Applications). Whether
you can 'translate' it or not will depend entirely upon how much the
code relies upon 'Access' features. I have just spent a couple of
months re-writing an Access front end into VB.Net and it is not a
simple task.

If you extract the VBA code into a .bas (or .cls) module and join
those together as a .vbp (Visual Basic 6) project, you may be able to
use the conversion by opening the .vbp file .NET, other wise you can
try doing small parts at a time using the in-line converter.

Because VBA code, whether in Access or Excel, relies fairly heavily on
built in functions of the host program, I would not expect to get
anything like a clean conversion. Depending on the size of the
project, you may be better advised to re-write from scratch.

David

Jun 18 '07 #4

P: n/a
AFAIK the answer is no ,,,

But it should be pretty easy to rewrite the program to a VB.Net desktop
application for a skilled VB.Net progger

regards

Michel Posseth [MCP]
"Camille Petersen" <cp*********@hotmail.comschreef in bericht
news:46***********************@newsspool4.arcor-online.net...
>I have a rather old VisualBasic program which is included inside an Access
*.mdb database.

So I guess it is an VisualBasic and not and VBA program.

Can I somehow automatically convert it into a VisualBasic program outside
of Access
which is working on base of .NET ?

If yes: How do I do it ?

If no: Is there way of at least let me automatically convert it with a
minimum of additional manual changes/interventions?

Camille

Jun 18 '07 #5

P: n/a
Camille,

I did this. There are multiple programs you can purchase that say it
can convert VBA to VB.NET. Some sort of work. I had to convert 12
Access apps (about 2000 forms, 3500 queries and 2000 reports) to
VB.NET. The purchased programs we tried were not good enough. So I
wrote my own conversion program. But it sounds like your Access app
is not too large and so it would probably easier just to rewrite it in
VB.NET rather than try to convert it.

Jun 18 '07 #6

This discussion thread is closed

Replies have been disabled for this discussion.