Bryta ut text ur en cell räknat från höger

Loranga

New Member
Joined
Jan 30, 2007
Messages
36
Aloha,

Jag har en fil där f kolumnen:s värden består av en lång text ex.
4834810.Blabla.2006-10-09.22905
4798344.Jadajada.2006-09-29.1699
9515241...20060925-31

vad jag försöker göra är att få fram en vba snutt som kan bryta ut värderna till höger om den sista punkten och placera dem i en annan kolumn:
4834810.Blabla.2006-10-09. | 22905
4798344.Jadajada.2006-09-29. | 1699
9515241... | 20060925-31
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
Hej Loranga!

Testa:

Code:
Sub xxx()

Dim Omr As Range
Dim AktCell As Range

Set Omr = Range("F2:F" & Range("F" & Rows.Count).End(xlUp).Row)

With CreateObject("vbscript.regexp")
    .Pattern = "[^\.]+$"
    For Each AktCell In Omr
        Set mönster = .Execute(AktCell.Value)
            AktCell = .Replace(AktCell, "")
            AktCell.Offset(0, 1) = mönster(0)
    Next AktCell

End With
 
Upvote 0

Forum statistics

Threads
1,223,964
Messages
6,175,658
Members
452,664
Latest member
alpserbetli

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top