Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default help to change data in cells


I want to view cell data from a row that have 6 colums in textboxes and
I want to be able to change data in the cell by typing a value in a
textbox that contains the cell data from that row and then want a macro
to update the sheet with the new value for example I have cell that
contains a number, say 5, and when I write 10 in the textbox and click
on a commandbutton I want the macro to change the cell value from 5 to
10.

How do I do that?

I would be grateful if someone can help me :)


--
trixxarn
------------------------------------------------------------------------
trixxarn's Profile: http://www.excelforum.com/member.php...o&userid=25036
View this thread: http://www.excelforum.com/showthread...hreadid=385635

  #2   Report Post  
Posted to microsoft.public.excel.programming
jjk jjk is offline
external usenet poster
 
Posts: 42
Default help to change data in cells

Hi Trixxarn,

Did you try the LinkedCell property of the textbox?
You could assign the address of the cell you want to modify there. This
way you wouldnt need another event handler to modify the values.

HTH
Jayant

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 692
Default help to change data in cells

Much depends on where you got the text box from.
If it is from one of the Toolboxes than you can set the LinkedCell or
ControlSource property.

If it is a drawing text box - you can assign code to it. In fact you can
assign code to most text boxes.

But first we need to know what kind of text box you are using...

--
steveB

Remove "AYN" from email to respond
"trixxarn" wrote in
message ...

I want to view cell data from a row that have 6 colums in textboxes and
I want to be able to change data in the cell by typing a value in a
textbox that contains the cell data from that row and then want a macro
to update the sheet with the new value for example I have cell that
contains a number, say 5, and when I write 10 in the textbox and click
on a commandbutton I want the macro to change the cell value from 5 to
10.

How do I do that?

I would be grateful if someone can help me :)


--
trixxarn
------------------------------------------------------------------------
trixxarn's Profile:
http://www.excelforum.com/member.php...o&userid=25036
View this thread: http://www.excelforum.com/showthread...hreadid=385635



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default help to change data in cells


How about a simple input box?
Give this a try.

You will need the first cell on the row you want to change as the
active cell before starting the macro.

Sub ChangeCellValue()
Dim x As Integer
For x = 0 To 5
ActiveCell.Offset(0, x).Value = InputBox(ActiveCell.Offset(0,
x).Value, _
"Enter the New Value Here")
Next x
End Sub

HTH


--
bhofsetz
------------------------------------------------------------------------
bhofsetz's Profile: http://www.excelforum.com/member.php...o&userid=18807
View this thread: http://www.excelforum.com/showthread...hreadid=385635

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default help to change data in cells


Hi!

Thanks for the help :) It worked perfect


--
trixxarn
------------------------------------------------------------------------
trixxarn's Profile: http://www.excelforum.com/member.php...o&userid=25036
View this thread: http://www.excelforum.com/showthread...hreadid=385635

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
change fill color in 2 cells when data entered in one tweets75 Excel Worksheet Functions 4 July 10th 07 07:29 PM
Copy data of two cells into one and change formula accordinaly maperalia Excel Discussion (Misc queries) 3 June 8th 07 09:34 PM
How to change data in cells of an existing saved form- Maggie Excel Discussion (Misc queries) 0 October 26th 06 09:40 PM
Change results , change data in othe cells across the row Jennifer1960 Excel Worksheet Functions 0 August 21st 06 10:37 PM
Change the right click menu on cells with imported data? Beth Trainer Excel Worksheet Functions 0 December 8th 05 06:43 PM


All times are GMT +1. The time now is 08:07 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"