Thema
|
Datum
|
Von Nutzer
|
Rating
|
Antwort
|
|
06.06.2013 15:42:04 |
Hawkins Okeyo |
|
|
|
07.06.2013 08:22:32 |
schokobons |
|
|
|
07.06.2013 10:06:44 |
Hawkins Okeyo |
|
|
|
07.06.2013 10:22:38 |
Gast3280 |
|
|
|
07.06.2013 11:24:25 |
Gast69626 |
|
|
|
07.06.2013 11:25:50 |
Hawkins Okeyo |
|
|
modify formula Index Match in Macro to "go to next" if match not found |
07.06.2013 13:44:54 |
schokobons |
|
|
|
07.06.2013 14:09:30 |
Hawkins Okeyo |
|
|
|
07.06.2013 14:16:06 |
schokobons |
|
|
|
07.06.2013 14:20:05 |
Hawkins Okeyo |
|
|
|
07.06.2013 14:41:15 |
schokobons |
|
|
|
07.06.2013 15:13:54 |
Hawkins Okeyo |
|
|
|
07.06.2013 17:15:23 |
schokbons |
|
|
|
08.07.2013 00:22:36 |
schokobons |
|
|
Von:
schokobons |
Datum:
07.06.2013 13:44:54 |
Views:
1368 |
Rating:
|
Antwort:
|
Thema:
modify formula Index Match in Macro to "go to next" if match not found |
Hello
This code shows you what you want:
Sub macroschokobons()
Dim Row, Row2 As Integer
For Each CellinWb1 In ThisWorkbook.Worksheets("1").Range("A1:A6") 'go each cell in the column A(in Workbook 1)
Row = CellinWb1.Row
For Each CellinWb2 In Workbooks("tmp2.xls").Worksheets("1").Range("A1:A10") ' go each cell in the column A(in Workbook 2)
Row2 = CellinWb2.Row
'compare the current cell in column A of Workbook 1 Sheet "" with the cell in column A of Workbook 2 Sheet "" (both cell have logical the same rownumber)
If (CellinWb1.Value = CellinWb2.Value) Then
Workbooks("tmp2.xls").Worksheets("1").Cells(Row2, 2).Value = ThisWorkbook.Worksheets("1").Cells(Row, 2).Value 'copy the current cell of the column b of the workbook 1 in the current cell b of the workbook 2
MsgBox (Row2)
End If
Next
Next
End Sub
Now it s your turn adapt that code ;)
__________________________
schokobons
|
- Bitte beschreiben Sie Ihr Problem möglichst ausführlich. (Wichtige Info z.B.: Office Version, Betriebssystem, Wo genau kommen Sie nicht weiter)
- Bitte helfen Sie ebenfalls wenn Ihnen geholfen werden konnte und markieren Sie Ihre Anfrage als erledigt (Klick auf Häckchen)
- Bei Crossposting, entsprechende Links auf andere Forenbeiträge beifügen / nachtragen
- Codeschnipsel am besten über den Code-Button im Text-Editor einfügen
- Die Angabe der Emailadresse ist freiwillig und wird nur verwendet, um Sie bei
Antworten auf Ihren Beitrag zu benachrichtigen
Bitte geben Sie ein aussagekräftiges Thema an.
Bitte geben Sie eine gültige Email Adresse ein!
- Bitte beschreiben Sie Ihr Problem möglichst ausführlich. (Wichtige Info z.B.: Office Version, Betriebssystem, Wo genau kommen Sie nicht weiter)
- Bitte helfen Sie ebenfalls wenn Ihnen geholfen werden konnte und markieren Sie Ihre Anfrage als erledigt (Klick auf Häckchen)
- Bei Crossposting, entsprechende Links auf andere Forenbeiträge beifügen / nachtragen
- Codeschnipsel am besten über den Code-Button im Text-Editor einfügen
- Die Angabe der Emailadresse ist freiwillig und wird nur verwendet, um Sie bei
Antworten auf Ihren Beitrag zu benachrichtigen
Thema
|
Datum
|
Von Nutzer
|
Rating
|
Antwort
|
|
06.06.2013 15:42:04 |
Hawkins Okeyo |
|
|
|
07.06.2013 08:22:32 |
schokobons |
|
|
|
07.06.2013 10:06:44 |
Hawkins Okeyo |
|
|
|
07.06.2013 10:22:38 |
Gast3280 |
|
|
|
07.06.2013 11:24:25 |
Gast69626 |
|
|
|
07.06.2013 11:25:50 |
Hawkins Okeyo |
|
|
modify formula Index Match in Macro to "go to next" if match not found |
07.06.2013 13:44:54 |
schokobons |
|
|
|
07.06.2013 14:09:30 |
Hawkins Okeyo |
|
|
|
07.06.2013 14:16:06 |
schokobons |
|
|
|
07.06.2013 14:20:05 |
Hawkins Okeyo |
|
|
|
07.06.2013 14:41:15 |
schokobons |
|
|
|
07.06.2013 15:13:54 |
Hawkins Okeyo |
|
|
|
07.06.2013 17:15:23 |
schokbons |
|
|
|
08.07.2013 00:22:36 |
schokobons |
|
|