Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Rob
 
Posts: n/a
Default Populating a UserForm'sTextBox with a value

Hi,

I would like to know how to get a UserForm's TextBox to show the value of a
cell when the UserForm is opened.
I named the TextBox GiftTextBox, and I was hoping something like
GiftTextBox.Value = ActiveCell.Offset(0, 6).Value would do it but I can't
get that to work. Is there a simple way for the ActiveCell.Offset(0,
6).Value to be shown somehow on the UserForm? I don't care whether it's in a
TextBox or some other box, as long as I can get the value to appear on the
UserForm.

Rob


  #2   Report Post  
Jim Cone
 
Posts: n/a
Default


Rob,

Something like...
UserForm1.GiftTextBox.Value = ActiveCell.Offset(0, 6).Value

Jim Cone
San Francisco, USA


"Rob" wrote in message
u...
Hi,
I would like to know how to get a UserForm's TextBox to show the value of a
cell when the UserForm is opened.
I named the TextBox GiftTextBox, and I was hoping something like
GiftTextBox.Value = ActiveCell.Offset(0, 6).Value would do it but I can't
get that to work. Is there a simple way for the ActiveCell.Offset(0,
6).Value to be shown somehow on the UserForm? I don't care whether it's in a
TextBox or some other box, as long as I can get the value to appear on the
UserForm.
Rob


  #3   Report Post  
Henry
 
Posts: n/a
Default

Rob,

Try
GiftTextBox.Text = ActiveCell.Offset(0, 6).Value

Henry


"Rob" wrote in message
u...
Hi,

I would like to know how to get a UserForm's TextBox to show the value of
a cell when the UserForm is opened.
I named the TextBox GiftTextBox, and I was hoping something like
GiftTextBox.Value = ActiveCell.Offset(0, 6).Value would do it but I can't
get that to work. Is there a simple way for the ActiveCell.Offset(0,
6).Value to be shown somehow on the UserForm? I don't care whether it's in
a TextBox or some other box, as long as I can get the value to appear on
the UserForm.

Rob



  #4   Report Post  
Rob
 
Posts: n/a
Default

Hi Henry,

Thanks for that, but in my application I needed Jim's suggestion by adding
the UserForm's name to the beginning of the line.

Rob

"Henry" wrote in message
...
Rob,

Try
GiftTextBox.Text = ActiveCell.Offset(0, 6).Value

Henry


"Rob" wrote in message
u...
Hi,

I would like to know how to get a UserForm's TextBox to show the value of
a cell when the UserForm is opened.
I named the TextBox GiftTextBox, and I was hoping something like
GiftTextBox.Value = ActiveCell.Offset(0, 6).Value would do it but I can't
get that to work. Is there a simple way for the ActiveCell.Offset(0,
6).Value to be shown somehow on the UserForm? I don't care whether it's
in a TextBox or some other box, as long as I can get the value to appear
on the UserForm.

Rob





  #5   Report Post  
Rob
 
Posts: n/a
Default

Hi Jim,

I was so close....but thanks! It did the trick. You can try so many things
and miss the obvious.

Rob

"Jim Cone" wrote in message
...

Rob,

Something like...
UserForm1.GiftTextBox.Value = ActiveCell.Offset(0, 6).Value

Jim Cone
San Francisco, USA


"Rob" wrote in message
u...
Hi,
I would like to know how to get a UserForm's TextBox to show the value of
a
cell when the UserForm is opened.
I named the TextBox GiftTextBox, and I was hoping something like
GiftTextBox.Value = ActiveCell.Offset(0, 6).Value would do it but I can't
get that to work. Is there a simple way for the ActiveCell.Offset(0,
6).Value to be shown somehow on the UserForm? I don't care whether it's in
a
TextBox or some other box, as long as I can get the value to appear on the
UserForm.
Rob




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Auto Populating cells from a master spreadsheet Steve K Excel Discussion (Misc queries) 0 July 1st 05 05:01 PM
Populating another tab. Brian Excel Discussion (Misc queries) 1 June 24th 05 12:29 AM
Populating a cell when certain cell is clicked Anthony Slater Excel Discussion (Misc queries) 3 April 14th 05 01:55 PM
populating sheets based on data from parent sheets seve Excel Discussion (Misc queries) 2 January 15th 05 09:22 PM
Automatically Populating Worksheet from Collected Input for Pricelist David Littrell via OfficeKB.com Excel Worksheet Functions 1 January 6th 05 05:04 PM


All times are GMT +1. The time now is 11:24 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"