Sendkeys clipboard word

Résolu
cs_micam Messages postés 18 Date d'inscription dimanche 16 novembre 2003 Statut Membre Dernière intervention 15 juin 2009 - 27 févr. 2009 à 18:14
cs_micam Messages postés 18 Date d'inscription dimanche 16 novembre 2003 Statut Membre Dernière intervention 15 juin 2009 - 11 mars 2009 à 14:03
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="ProgId" content="Word.Document" />
<meta name="Generator" content="Microsoft Word 11" />
<meta name="Originator" content="Microsoft Word 11" />
<link rel="File-List" href="file:///C:%5CDOCUME%7E1%5CMic%5CLOCALS%7E1%5CTemp%5Cmsohtml1%5C01%5Cclip_filelist.xml" />
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:HyphenationZone>21</w:HyphenationZone>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
</w:WordDocument>
</xml><![endif]-->
<!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState="false" LatentStyleCount="156">
</w:LatentStyles>
</xml><![endif]-->
<style>
<!--
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{mso-style-parent:"";
margin:0cm;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";}
@page Section1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 70.85pt 70.85pt;
mso-header-margin:36.0pt;
mso-footer-margin:36.0pt;
mso-paper-source:0;}
div.Section1
{page:Section1;}
-->
</style>
<!--[if gte mso 10]>
<style>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:"Tableau Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-parent:"";
mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
mso-para-margin:0cm;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Times New Roman";
mso-ansi-language:#0400;
mso-fareast-language:#0400;
mso-bidi-language:#0400;}
</style>
<![endif]-->
Bonjour,


Débutant en en C# je développe une petite application qui me permet d’envoyer
du texte via SendKeys dans une fenêtre de word ou de notepad.


Sur xp c’est parfait, mais avec vista c’est très long, et on
voit les caractères s’afficher les uns derrière les autres. J’ai essayé sur
différentes machines, et le problème revient assez souvent.


J’ai pensé faire un collé du texte après l’avoir envoyé dans
le clipboard, mais dans word s’affiche à droite la fenêtre de gestion des
éléments copiés et collés. Cela ne me satisfait pas.


Existe-t-il un moyen d’envoyer du
texte dans une autre application (word, notepad…) sans passer par SendKeys ou
Clipboard ?


Merci de votre aide

2 réponses

Lutinore Messages postés 3246 Date d'inscription lundi 25 avril 2005 Statut Membre Dernière intervention 27 octobre 2012 41
27 févr. 2009 à 23:57
3
cs_micam Messages postés 18 Date d'inscription dimanche 16 novembre 2003 Statut Membre Dernière intervention 15 juin 2009
11 mars 2009 à 14:03
Bonjour,
Merci de ta réponse Lutinore, ça marche super bien.
0
Rejoignez-nous