ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   aligning entry in text box (https://www.excelbanter.com/excel-programming/285559-aligning-entry-text-box.html)

Candee[_14_]

aligning entry in text box
 
Happy Holidays to all!

I have a workbook that has 2 userforms in it. The first is an entry
form with a textbox (txtReject) where the user will enter a number. I
have the alignment set to 1-fmTextAlignLeft, but when the form is
opened, the cursor is actually sitting one space to the right. Is
there a way to get it to start at the very left of the text box
(instead of backspacing before each new entry is made)?

The problem I'm having is that the data from the first form is sent to
a spreadsheet when a button is pressed. The second form has a combo
box linked to the spreadsheet, and a user will select a reject # from
the list and hit a refresh button to call that data to the second form
for updating/editing. If the entry is made using a backspace, the
second form works like a charm, without the backspace, it's like the
entry doesn't exist.

Thanks in advance...


---
Message posted from http://www.ExcelForum.com/


Gandei

aligning entry in text box
 
Just as you set the TextAlign property value to 1-
fmTextAlignLeft, you should also set the SelectionMargin
property value to False. This will fix your problem.


-----Original Message-----
Happy Holidays to all!

I have a workbook that has 2 userforms in it. The first

is an entry
form with a textbox (txtReject) where the user will enter

a number. I
have the alignment set to 1-fmTextAlignLeft, but when the

form is
opened, the cursor is actually sitting one space to the

right. Is
there a way to get it to start at the very left of the

text box
(instead of backspacing before each new entry is made)?

The problem I'm having is that the data from the first

form is sent to
a spreadsheet when a button is pressed. The second form

has a combo
box linked to the spreadsheet, and a user will select a

reject # from
the list and hit a refresh button to call that data to

the second form
for updating/editing. If the entry is made using a

backspace, the
second form works like a charm, without the backspace,

it's like the
entry doesn't exist.

Thanks in advance...


---
Message posted from http://www.ExcelForum.com/

.


Candee[_15_]

aligning entry in text box
 
Gandei, thanks so much!!! works like a charm!!!!!!

--
Message posted from http://www.ExcelForum.com



All times are GMT +1. The time now is 02:45 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com