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
Solved

Vertical Text Alignment / Top Margin

Posted on 2013-05-16
3
340 Views
Last Modified: 2013-05-16
Can anyone explain how to use the top margin command...

I have used txtbox.TopMargin = 1 but it does nothing whatsover but when i set the top margin on the properties it works fine.  I therefore assume the syntax is not correct but it does not error?
0
Comment
Question by:SweetingA
  • 2
3 Comments
 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 500 total points
ID: 39172038
This measurement is in "Twips" if you want to use it in code.
1 Inch=1440 Twips

So try using 1440 instead of 1 (in your code)
0
 

Author Closing Comment

by:SweetingA
ID: 39172054
So easy when you know it, thanks
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 39172140
LOL

Yes, it is funny.

Every once in a while, (when I am in a rush), I forget too...

Odd how you can enter Inches in the property box, but MS expects you to "magically" know, not only about twips, but also somehow know how they relate to inches... (1 in=1440 twips)

It is mentioned in the help files (albeit at the very end...)
http://msdn.microsoft.com/en-us/library/office/ff834473%28v=office.15%29.aspx

Glad I could help.

;-)

JeffCoachman
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

In the previous article, Using a Critera Form to Filter Records (http://www.experts-exchange.com/A_6069.html), the form was basically a data container storing user input, which queries and other database objects could read. The form had to remain op…
Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
Familiarize people with the process of utilizing SQL Server views from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Access…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

856 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