PC Review


Reply
Thread Tools Rate Thread

How create report controls at runtime (VBA)

 
 
Roberto Carabajal
Guest
Posts: n/a
 
      5th Sep 2008
Hello:
I would appreciate that somebody shows how to create textboxs or labels in a
report from VBA code, I tried sintaxis like used in VB6 but didn´t work. I
need to create an object within the Report_Page() event.
Thanks in advance.
Roberto
 
Reply With Quote
 
 
 
 
Allen Browne
Guest
Posts: n/a
 
      5th Sep 2008
You cannot do that.

You can create controls in report design view only, not while any of its
events are running.

In general, you don't want to use design view as it will prevent you
releasing an MDE later. CreateControl is useful only for things like
wizards.

--
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.

"Roberto Carabajal" <(E-Mail Removed)> wrote in
message
news:011FED52-F08D-4337-B9D1-(E-Mail Removed)...
> Hello:
> I would appreciate that somebody shows how to create textboxs or labels in
> a
> report from VBA code, I tried sintaxis like used in VB6 but didn´t work.
> I
> need to create an object within the Report_Page() event.
> Thanks in advance.
> Roberto


 
Reply With Quote
 
Marshall Barton
Guest
Posts: n/a
 
      5th Sep 2008
Roberto Carabajal wrote:
>I would appreciate that somebody shows how to create textboxs or labels in a
>report from VBA code, I tried sintaxis like used in VB6 but didn´t work. I
>need to create an object within the Report_Page() event.



Even if you could find a way to do that, it would be a
really bad idea. Instead, precreate a sufficient number of
invisible text boxes and make them visible as needed.

--
Marsh
MVP [MS Access]
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
help me to create an array of controls at runtime =?Utf-8?B?UGhpbGlw?= Microsoft Dot NET Framework Forms 1 30th Jan 2007 11:06 AM
Create controls at runtime TonyMast Microsoft VB .NET 6 6th Apr 2006 12:16 PM
How to create controls at runtime Andy Chan Microsoft Excel Programming 3 30th Aug 2004 10:07 AM
How to create controls at runtime michele Microsoft ASP .NET 1 4th Aug 2004 08:28 PM
Create controls in runtime Alberto Microsoft ASP .NET 4 10th Mar 2004 05:58 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:36 AM.