Posts by ´romanenko

    Re: Replace text in fields


    Thank you so much! I almost got everything working now.


    The last thing is that I want to add a number into two fields and I've tested using And but cant get it to work.


    ElseIf ActiveCell.Offset(-1, 0).Value = 4 Then
    ActiveCell.Offset(-1, 0).Value = "00:00-8:00"
    ActiveCell.Offset(-1,10).Value = 8
    End If


    What I really want is the number 6 to be put in field 10 and the number 2 in field 11. I tried
    ActiveCell.Offset(-1,10).Value = 8 And ActiveCell.Offset(-1,11).Value = 2 but that returns the number 0 in field 10.

    Re: Newbie: Replace text in fields


    This is great! One problem though. Now when I enter a 2 it changes it to text in every field, I only want it to change in column B (sorry that I said A earlier).


    Another thing. It would be nice to have a line that I can modify myself. Something like:
    x=line


    "If Bx=2 then replace 2 with "18:30-00.00" and put the number 5.5 in Mx"


    Really appreciate your help.

    Re: Newbie: Replace text in fields


    Quote from Steve at work

    What are the cell references of your fields?


    Do you mean the A4 and so on?
    I want to enter the numbers that is to be replaced with text in column A starting on line 4 and all the way down to 20. The number that is going to be added is going to be added in column M on the same line. Is this what you mean?

    Hello!


    First of all, excuse if my english is bad.


    I would like to create a very simple Excel file that makes the following:


    If I enter 2 in a field I want that 2 replaced with "07.15-19.00" and also a 1 entered to the field next to it. If I enter a 4 I want the 4 replaced with 00:00-08:00 and the number 8 entered in the field next to it.


    I assume this is very simple but I can't find anything in the help.


    Any tips?


    Thanks!
    Romanenko