?
Solved

Centering in a form!!!

Posted on 1999-07-08
2
Medium Priority
?
228 Views
Last Modified: 2010-05-02
How can I center a letter "E" in the middle of a form?
I still want it to be centered even if I increase the font size.
0
Comment
Question by:cheongtm
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 6

Accepted Solution

by:
setiawan earned 200 total points
ID: 1522989
Where do you put the letter "E" on the form, using label or what ?

  You can do that by this way :
 
     set label1.allignment to center at design time
 
     label1.left = (form1.width - label1.width) / 2
     label1.top = (form1.height - label1.height) / 2
 
 

0
 
LVL 5

Expert Comment

by:KDivad
ID: 1522990
Use after setting fontname and fontsize

With Form1
    .CurrentX = (Form1.ScaleWidth - Form1.TextWidth("E")) \ 2
    .CurrentY = (Form1.ScaleHeight - Form1.TextHeight("E")) \ 2
End With
Form1.Print "E"


0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Suggested Courses

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question