Write code to add new form

  • Thread starter Thread starter mario
  • Start date Start date
M

mario

Hi there ,

I'd like to know if there is a way to write vba code to add a form in an
Access application.
The form should be created while the application is running.

ex : can I add a form with objects and this only from VBA code ?

thanks to reply
Mario
 
It can be done, by first creating the form like you want, then saving it as
a text file, and recreating it from that file from code, changing the bits
you need, but its a lot of work. There are many, many properties to set.

Look up the Application.LoadFromText and SaveAsText commands.

Since you need to create the form anyway, why not just use that ? Its
relatively easy to create a form with a lot of fields, then manipulate the
visible property to show what you want.

--
Regards,

Adrian Jansen
J & K MicroSystems
Microcomputer solutions for industrial control
 
Back
Top