Salut,
Mon probleme c'est que j'ai une fonction qui cherche et remplace dans un document word, mais lorseque la taille du texte de remplacement est grande alors ça ne marche plus. (Remplacement.Text).
Voici la méthode que j'utilise :
-------------------------------------
---------------------------------------
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13 With DocApp.Selection.Find .Text = "#" & texte1 & "#" .Replacement.Text = texte2.ToString() .Forward = True .Wrap = Word.WdFindWrap.wdFindContinue .Format = False .MatchCase = False .MatchWholeWord = False .MatchWildcards = False .MatchSoundsLike = False .MatchAllWordForms = False End With DocApp.Selection.Find.Execute(Replace:=Word.WdReplace.wdReplaceAll)
Merci.
Partager