Re: Using VBA need to add a text box to a form



You cannot do this while the form is in use, so this technique is not
suitable for any database where you plan to release an MDE for users.

If you are designing some kind of wizard/tool for development purposes, you
can create a text box like this (assuming Form1 is open in design view):

Dim txt As TextBox
Set txt = CreateControl("Form1", acTextBox, acDetail, , , _
1440, 1440, 1440, 285)
txt.Name = "MyNewControl"

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Trever B" <TreverB@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:B1EFA54B-E78D-4CD4-9E32-5B5732E185CF@xxxxxxxxxxxxxxxx
Hi,

Thanks in advance.

Using VBA I want to a boxes to a form.

I am ok with the loop but just how do you add a textbox to a form using
code.


.



Relevant Pages

  • Re: Text box with a "visible" value seems to be Null
    ... Simplest solution might be to allow the blank new record to show. ... Tips for Access users - http://allenbrowne.com/tips.html ... txt_Header_Dept is in the form header or footer? ... > My question is why if I can see the textbox with "Radiology" in it,> when I ...
    (microsoft.public.access.formscoding)
  • Re: Access 2007 wheres the spacing tool?
    ... Perth, Western Australia ... Tips for Access users - http://allenbrowne.com/tips.html ... designing a form, and I can't seem to find the spacing tool. ...
    (microsoft.public.access.forms)
  • Re: Text box with a "visible" value seems to be Null
    ... Tips for Access users - http://allenbrowne.com/tips.html ... try to assign that same value to another textbox, ... > I have a main menu that opens different forms. ... I can see the "Radiology" text in the textbox. ...
    (microsoft.public.access.formscoding)
  • Re: Adding a button to a datagrid
    ... Are you designing a control? ... I still think that including the textbox in the grid is not good idea, ... "Chris" wrote in message ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Help w/ Filter
    ... Tips for Access users - http://allenbrowne.com/tips.html ... > I have a popup modal form that I use to search with. ... > in the textbox. ...
    (microsoft.public.access.forms)

Loading