If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Stephen Lebans Forms: Formatting Labels/Data
Hi:
Per a suggestion on this forum, I downloaded Stephen Lebans zip file so I can center text on labels and form fields. I looked at the example of what he did and that's exactly what I want. However, there is no explanation of how he did such, at least I can't find one. I tried comparing the properties of two form fields, one centered and one which was the traditional Access set up aligned with the top of the box. For the life of me, I can't figure out which properties he modified that moved text to the center of the box. Can someone please help? Thanks, Robert |
#2
|
|||
|
|||
If it would be possible to do this with the standard properties, Stephen
wouldn't have made the sample database Check out the Modules and Customer forms VB-script. Later, Philo -- Message posted via http://www.accessmonster.com |
#3
|
|||
|
|||
Robert,
I just took a quick peek at Stephen's code... Did you look at the "external" Module that came with the file? That's where all the centering code is. The form just calls the centering function from the Module. Al Camp "Robert T" wrote in message news Hi: Per a suggestion on this forum, I downloaded Stephen Lebans zip file so I can center text on labels and form fields. I looked at the example of what he did and that's exactly what I want. However, there is no explanation of how he did such, at least I can't find one. I tried comparing the properties of two form fields, one centered and one which was the traditional Access set up aligned with the top of the box. For the life of me, I can't figure out which properties he modified that moved text to the center of the box. Can someone please help? Thanks, Robert |
#4
|
|||
|
|||
Hello Al:
I thought the answer was somewhere to be found in the field or label's Proprerties Box. But I finally figured out the modifications were done via coding and a function. Now I have to figuure out exactly how it works. Thanks, Robert |
#5
|
|||
|
|||
The logic is,
For each selected TextBox control in the Detail section: 1) Determine the height of the control's contents 2) Set the TextBox Top Margin property to simulate Centered for a Vertical Alignment prop -- HTH Stephen Lebans http://www.lebans.com Access Code, Tips and Tricks Please respond only to the newsgroups so everyone can benefit. "Robert T" wrote in message ... Hello Al: I thought the answer was somewhere to be found in the field or label's Proprerties Box. But I finally figured out the modifications were done via coding and a function. Now I have to figuure out exactly how it works. Thanks, Robert |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Stephen Lebans' PictureBox Class - Transparent option? | Peter Danes | Using Forms | 1 | May 9th, 2005 11:45 PM |
How to change merge forms from Word Perfect to Microsoft Word | Charles Kenyon | General Discussion | 1 | December 30th, 2004 03:35 PM |
Can I close all open forms? | DBS | General Discussion | 3 | October 7th, 2004 04:35 PM |
Required Field Conditional | Katherine R | New Users | 2 | September 1st, 2004 05:52 AM |
formatting datasheet forms | Michael D. McGill | Using Forms | 1 | August 12th, 2004 03:49 PM |