![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: Apr 2002
Location: East Texas
Posts: 38
|
Is there a way to have a label on a user form to show the value of a cell?
Thanks in advance [ This Message was edited by: Skyhook on 2002-05-22 08:49 ] [ This Message was edited by: Skyhook on 2002-05-25 16:45 ] |
|
|
|
|
|
#2 |
|
MrExcel MVP
Join Date: Feb 2002
Location: Helena, MT
Posts: 13,690
|
Private Sub UserForm_Initialize()
Label1.Caption = Range("A1").Value End Sub Note:You can use other Events to run the code |
|
|
|
|
|
#3 |
|
Board Regular
Join Date: Feb 2002
Location: England
Posts: 212
|
If you use this code, the label (label1) will give you the value of cell "A1" when it loads.
Private Sub UserForm_Initialize() Label1.Caption = Range("A1") End Sub hope this helps Matt |
|
|
|
|
|
#4 |
|
Board Regular
Join Date: Feb 2002
Location: England
Posts: 212
|
Excuse the repetition, Ienze beat me to it!
|
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|