Bonjour j'ai la formule suivante dans une de mes macro
ActiveCell.PasteSpecial
comment fait-on pour faire un coller avec liaison ??
si je le fait sans macro se qui veut dire que je fait un copier de ma
cellule et je vais faire un collage special a l'endroit desirer et bien j'ai
loption coller avec liaison . quelle est la formule avec mon
ActiveCell.PasteSpecial pour faire une liaison
Merci a l'avance
Public MaFeuille As Object ___________________________________ Private Sub content() Dim AnyString, MyStr AnyString = ActiveCell.Text MyStr = Left(AnyString, 3) If MyStr = "M.O" Then MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER", vbInformation Else 'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column 'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1 MaFeuille.Select ActiveSheet.Paste link:=True Application.CutCopyMode = False ActiveCell.Select End If End Sub
comme tu peu le voir j'ai enlever ce codage : 'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column 'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
car il me manquait une cellule qui n'etait pas copier
j'ai donc mit celle la a la place : Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1
mais il buge a cette etape: ActiveSheet.Paste link:=True
je croi que ses normal car ya aucun .copy tk je pense tu aurais une iddée ?????
ok sa marche mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir, est ce qu'il y a toujours deux lignes constituant la plage, ou bien si ça peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow If Application.CountA(plg) Mod 2 <> 0 Then Derc = (Application.CountA(plg) + 1) / 2 Else: Derc = Application.CountA(plg) / 2 End If
isabelle
:(
voici mon code au complet
Public MaFeuille As Object
___________________________________
Private Sub content()
Dim AnyString, MyStr
AnyString = ActiveCell.Text
MyStr = Left(AnyString, 3)
If MyStr = "M.O" Then
MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER",
vbInformation
Else
'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column
'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow
Derc = plg.Find("", , , , xlByColumns).Column - 1
MaFeuille.Select
ActiveSheet.Paste link:=True
Application.CutCopyMode = False
ActiveCell.Select
End If
End Sub
comme tu peu le voir j'ai enlever ce codage :
'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column
'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
car il me manquait une cellule qui n'etait pas copier
j'ai donc mit celle la a la place :
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow
Derc = plg.Find("", , , , xlByColumns).Column - 1
mais il buge a cette etape:
ActiveSheet.Paste link:=True
je croi que ses normal car ya aucun .copy tk je pense
tu aurais une iddée ?????
"isabelle" <hoHoho@hohoHo> a écrit dans le message de news:
%23TRz2u9gFHA.3936@TK2MSFTNGP10.phx.gbl...
ok sa marche
mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir,
est ce qu'il y a toujours deux lignes constituant la plage, ou bien si ça
peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow
If Application.CountA(plg) Mod 2 <> 0 Then
Derc = (Application.CountA(plg) + 1) / 2
Else:
Derc = Application.CountA(plg) / 2
End If
Public MaFeuille As Object ___________________________________ Private Sub content() Dim AnyString, MyStr AnyString = ActiveCell.Text MyStr = Left(AnyString, 3) If MyStr = "M.O" Then MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER", vbInformation Else 'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column 'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1 MaFeuille.Select ActiveSheet.Paste link:=True Application.CutCopyMode = False ActiveCell.Select End If End Sub
comme tu peu le voir j'ai enlever ce codage : 'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column 'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
car il me manquait une cellule qui n'etait pas copier
j'ai donc mit celle la a la place : Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1
mais il buge a cette etape: ActiveSheet.Paste link:=True
je croi que ses normal car ya aucun .copy tk je pense tu aurais une iddée ?????
ok sa marche mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir, est ce qu'il y a toujours deux lignes constituant la plage, ou bien si ça peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow If Application.CountA(plg) Mod 2 <> 0 Then Derc = (Application.CountA(plg) + 1) / 2 Else: Derc = Application.CountA(plg) / 2 End If
isabelle
jps
hum....palatalisation, voulais-je dire... jps
"jps" a écrit dans le message de news: eS2s8a%
heureusement qu'aucune palatisation n'est venue affecter le mot "colonne" pour en faire "cholonne"... jps
ok sa marche mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir, est ce qu'il y a toujours deux lignes constituant la plage, ou bien si ça peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow If Application.CountA(plg) Mod 2 <> 0 Then Derc = (Application.CountA(plg) + 1) / 2 Else: Derc = Application.CountA(plg) / 2 End If
isabelle
hum....palatalisation, voulais-je dire...
jps
"jps" <vaderetrosp@amas> a écrit dans le message de news:
eS2s8a%23gFHA.576@tk2msftngp13.phx.gbl...
heureusement qu'aucune palatisation n'est venue affecter le mot "colonne"
pour en faire "cholonne"...
jps
"isabelle" <hoHoho@hohoHo> a écrit dans le message de news:
%23TRz2u9gFHA.3936@TK2MSFTNGP10.phx.gbl...
ok sa marche
mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir,
est ce qu'il y a toujours deux lignes constituant la plage, ou bien si
ça peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow
If Application.CountA(plg) Mod 2 <> 0 Then
Derc = (Application.CountA(plg) + 1) / 2
Else:
Derc = Application.CountA(plg) / 2
End If
ok sa marche mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir, est ce qu'il y a toujours deux lignes constituant la plage, ou bien si ça peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow If Application.CountA(plg) Mod 2 <> 0 Then Derc = (Application.CountA(plg) + 1) / 2 Else: Derc = Application.CountA(plg) / 2 End If
isabelle
isabelle
re bonjour David,
il faut laisser la ligne .copy
Public MaFeuille As Object ___________________________________ Private Sub content() Dim AnyString, MyStr AnyString = ActiveCell.Text MyStr = Left(AnyString, 3) If MyStr = "M.O" Then MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER", vbInformation Else Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1 Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy MaFeuille.Select ActiveSheet.Paste link:=True Application.CutCopyMode = False ActiveCell.Select End If End Sub
isabelle
:( voici mon code au complet
Public MaFeuille As Object ___________________________________ Private Sub content() Dim AnyString, MyStr AnyString = ActiveCell.Text MyStr = Left(AnyString, 3) If MyStr = "M.O" Then MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER", vbInformation Else 'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column 'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1 MaFeuille.Select ActiveSheet.Paste link:=True Application.CutCopyMode = False ActiveCell.Select End If End Sub
comme tu peu le voir j'ai enlever ce codage : 'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column 'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
car il me manquait une cellule qui n'etait pas copier
j'ai donc mit celle la a la place : Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1
mais il buge a cette etape: ActiveSheet.Paste link:=True
je croi que ses normal car ya aucun .copy tk je pense tu aurais une iddée ?????
ok sa marche mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir, est ce qu'il y a toujours deux lignes constituant la plage, ou bien si ça peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow If Application.CountA(plg) Mod 2 <> 0 Then Derc = (Application.CountA(plg) + 1) / 2 Else: Derc = Application.CountA(plg) / 2 End If
isabelle
re bonjour David,
il faut laisser la ligne .copy
Public MaFeuille As Object
___________________________________
Private Sub content()
Dim AnyString, MyStr
AnyString = ActiveCell.Text
MyStr = Left(AnyString, 3)
If MyStr = "M.O" Then
MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER",
vbInformation
Else
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow
Derc = plg.Find("", , , , xlByColumns).Column - 1
Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
MaFeuille.Select
ActiveSheet.Paste link:=True
Application.CutCopyMode = False
ActiveCell.Select
End If
End Sub
isabelle
:(
voici mon code au complet
Public MaFeuille As Object
___________________________________
Private Sub content()
Dim AnyString, MyStr
AnyString = ActiveCell.Text
MyStr = Left(AnyString, 3)
If MyStr = "M.O" Then
MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER",
vbInformation
Else
'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column
'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow
Derc = plg.Find("", , , , xlByColumns).Column - 1
MaFeuille.Select
ActiveSheet.Paste link:=True
Application.CutCopyMode = False
ActiveCell.Select
End If
End Sub
comme tu peu le voir j'ai enlever ce codage :
'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column
'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
car il me manquait une cellule qui n'etait pas copier
j'ai donc mit celle la a la place :
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow
Derc = plg.Find("", , , , xlByColumns).Column - 1
mais il buge a cette etape:
ActiveSheet.Paste link:=True
je croi que ses normal car ya aucun .copy tk je pense
tu aurais une iddée ?????
"isabelle" <hoHoho@hohoHo> a écrit dans le message de news:
%23TRz2u9gFHA.3936@TK2MSFTNGP10.phx.gbl...
ok sa marche
mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir,
est ce qu'il y a toujours deux lignes constituant la plage, ou bien si ça
peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow
If Application.CountA(plg) Mod 2 <> 0 Then
Derc = (Application.CountA(plg) + 1) / 2
Else:
Derc = Application.CountA(plg) / 2
End If
Public MaFeuille As Object ___________________________________ Private Sub content() Dim AnyString, MyStr AnyString = ActiveCell.Text MyStr = Left(AnyString, 3) If MyStr = "M.O" Then MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER", vbInformation Else Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1 Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy MaFeuille.Select ActiveSheet.Paste link:=True Application.CutCopyMode = False ActiveCell.Select End If End Sub
isabelle
:( voici mon code au complet
Public MaFeuille As Object ___________________________________ Private Sub content() Dim AnyString, MyStr AnyString = ActiveCell.Text MyStr = Left(AnyString, 3) If MyStr = "M.O" Then MsgBox "VOUS N'AVEZ PAS SELECTIONNER LA BONNE CELLULE SVP RECOMMENCER", vbInformation Else 'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column 'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1 MaFeuille.Select ActiveSheet.Paste link:=True Application.CutCopyMode = False ActiveCell.Select End If End Sub
comme tu peu le voir j'ai enlever ce codage : 'Derc = Range("IV" & ActiveCell.Row).End(xlToLeft).Column 'Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row + 1, Derc)).Copy
car il me manquait une cellule qui n'etait pas copier
j'ai donc mit celle la a la place : Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow Derc = plg.Find("", , , , xlByColumns).Column - 1
mais il buge a cette etape: ActiveSheet.Paste link:=True
je croi que ses normal car ya aucun .copy tk je pense tu aurais une iddée ?????
ok sa marche mais la tu va me trouver fatiquant en tabarnouche
meuhnon, c'est avec plaisir, est ce qu'il y a toujours deux lignes constituant la plage, ou bien si ça peux varier ?
Set plg = Range(ActiveCell, ActiveCell.Offset(1, 0)).EntireRow If Application.CountA(plg) Mod 2 <> 0 Then Derc = (Application.CountA(plg) + 1) / 2 Else: Derc = Application.CountA(plg) / 2 End If