45 using System.Collections.Generic;
46 using System.Runtime.InteropServices;
81 public const int AU3_INTDEFAULT = -2147483647;
82 public const int ERROR = 1;
83 public const int SW_HIDE = 2;
84 public const int SW_MAXIMIZE = 3;
85 public const int SW_MINIMIZE = 4;
86 public const int SW_RESTORE = 5;
87 public const int SW_SHOW = 6;
88 public const int SW_SHOWDEFAULT = 7;
89 public const int SW_SHOWMAXIMIZED = 8;
90 public const int SW_SHOWMINIMIZED = 9;
91 public const int SW_SHOWMINNOACTIVE = 10;
92 public const int SW_SHOWNA = 11;
93 public const int SW_SHOWNOACTIVATE = 12;
94 public const int SW_SHOWNORMAL = 13;
95 public const int VERSION = 110;
97 const string AUTOITX3_DLL =
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll";
104 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
105 public static extern int AU3_AutoItSetOption([MarshalAs(UnmanagedType.LPWStr)]
string Option,
int Value);
108 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
109 public static extern void AU3_BlockInput(
int Flag);
112 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
113 public static extern int AU3_CDTray(
114 [MarshalAs(UnmanagedType.LPWStr)]
string Drive,
115 [MarshalAs(UnmanagedType.LPWStr)]
string Action);
123 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
124 public static extern void AU3_ClipGet([MarshalAs(UnmanagedType.LPWStr)]StringBuilder Clip,
int BufSize);
127 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
128 public static extern void AU3_ClipPut([MarshalAs(UnmanagedType.LPWStr)]
string Clip);
131 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
132 public static extern int AU3_ControlClick(
133 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
134 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
135 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
136 [MarshalAs(UnmanagedType.LPWStr)]
string Button,
142 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
143 public static extern void AU3_ControlCommand(
144 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
145 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
146 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
147 [MarshalAs(UnmanagedType.LPWStr)]
string Command,
148 [MarshalAs(UnmanagedType.LPWStr)]
string Extra,
149 [MarshalAs(UnmanagedType.LPWStr)] StringBuilder Result,
153 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
154 public static extern int AU3_ControlDisable(
155 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
156 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
157 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
160 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
161 public static extern int AU3_ControlEnable(
162 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
163 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
164 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
167 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
168 public static extern int AU3_ControlFocus(
169 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
170 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
171 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
174 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
175 public static extern void AU3_ControlGetFocus(
176 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
177 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
178 [MarshalAs(UnmanagedType.LPWStr)] StringBuilder ControlWithFocus,
182 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
183 public static extern void AU3_ControlGetHandle(
184 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
185 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
186 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
187 [MarshalAs(UnmanagedType.LPWStr)] StringBuilder RetText,
191 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
192 public static extern int AU3_ControlGetPosHeight(
193 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
194 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
195 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
198 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
199 public static extern int AU3_ControlGetPosWidth(
200 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
201 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
202 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
205 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
206 public static extern int AU3_ControlGetPosX(
207 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
208 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
209 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
212 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
213 public static extern int AU3_ControlGetPosY(
214 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
215 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
216 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
219 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
220 public static extern void AU3_ControlGetText(
221 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
222 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
223 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
224 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder ControlText,
228 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
229 public static extern int AU3_ControlHide(
230 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
231 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
232 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
235 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
236 public static extern void AU3_ControlListView(
237 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
238 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
239 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
240 [MarshalAs(UnmanagedType.LPWStr)]
string Command,
241 [MarshalAs(UnmanagedType.LPWStr)]
string Extral1,
242 [MarshalAs(UnmanagedType.LPWStr)]
string Extra2,
243 [MarshalAs(UnmanagedType.LPWStr)] StringBuilder Result,
247 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
248 public static extern int AU3_ControlMove(
249 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
250 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
251 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
258 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
259 public static extern int AU3_ControlSend(
260 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
261 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
262 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
263 [MarshalAs(UnmanagedType.LPWStr)]
string SendText,
267 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
268 public static extern int AU3_ControlSetText(
269 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
270 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
271 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
272 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControlText);
275 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
276 public static extern int AU3_ControlShow(
277 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
278 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
279 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl);
282 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
283 public static extern void AU3_ControlTreeView(
284 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
285 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
286 [MarshalAs(UnmanagedType.LPWStr)]
string fpsControl,
287 [MarshalAs(UnmanagedType.LPWStr)]
string Command,
288 [MarshalAs(UnmanagedType.LPWStr)]
string Extra1,
289 [MarshalAs(UnmanagedType.LPWStr)]
string Extra2,
290 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder Result,
294 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
295 public static extern void AU3_DriveMapAdd(
296 [MarshalAs(UnmanagedType.LPWStr)]
string Device,
297 [MarshalAs(UnmanagedType.LPWStr)]
string Share,
299 [MarshalAs(UnmanagedType.LPWStr)]
string User,
300 [MarshalAs(UnmanagedType.LPWStr)]
string Pwd,
301 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder Result,
305 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
306 public static extern int AU3_DriveMapDel([MarshalAs(UnmanagedType.LPWStr)]
string Device);
309 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
310 public static extern void AU3_DriveMapGet(
311 [MarshalAs(UnmanagedType.LPWStr)]
string Device,
312 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder Mapping,
316 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
317 public static extern int AU3_error();
320 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
321 public static extern int AU3_IniDelete(
322 [MarshalAs(UnmanagedType.LPWStr)]
string Filename,
323 [MarshalAs(UnmanagedType.LPWStr)]
string Section,
324 [MarshalAs(UnmanagedType.LPWStr)]
string Key);
327 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
328 public static extern void AU3_IniRead(
329 [MarshalAs(UnmanagedType.LPWStr)]
string Filename,
330 [MarshalAs(UnmanagedType.LPWStr)]
string Section,
331 [MarshalAs(UnmanagedType.LPWStr)]
string Key,
332 [MarshalAs(UnmanagedType.LPWStr)]
string Default,
333 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder Value,
338 [DllImport(AUTOITX3_DLL, SetLastError =
true, CharSet = CharSet.Auto)]
339 public static extern void AU3_Init();
342 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
343 public static extern int AU3_IniWrite(
344 [MarshalAs(UnmanagedType.LPWStr)]
string Filename,
345 [MarshalAs(UnmanagedType.LPWStr)]
string Section,
346 [MarshalAs(UnmanagedType.LPWStr)]
string Key,
347 [MarshalAs(UnmanagedType.LPWStr)]
string Value);
350 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
351 public static extern int AU3_IsAdmin();
354 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
355 public static extern int AU3_MouseClick(
356 [MarshalAs(UnmanagedType.LPWStr)]
string Button,
363 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
364 public static extern int AU3_MouseClickDrag(
365 [MarshalAs(UnmanagedType.LPWStr)]
string Button,
373 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
374 public static extern void AU3_MouseDown([MarshalAs(UnmanagedType.LPWStr)]
string Button);
377 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
378 public static extern int AU3_MouseGetCursor();
381 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
382 public static extern int AU3_MouseGetPosX();
385 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
386 public static extern int AU3_MouseGetPosY();
389 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
390 public static extern int AU3_MouseMove(
int X,
int Y,
int Speed);
393 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
394 public static extern void AU3_MouseUp([MarshalAs(UnmanagedType.LPWStr)]
string Button);
397 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
398 public static extern void AU3_MouseWheel([MarshalAs(UnmanagedType.LPWStr)]
string Direction,
int Clicks);
401 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
402 public static extern int AU3_Opt([MarshalAs(UnmanagedType.LPWStr)]
string Option,
int Value);
405 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
406 public static extern int AU3_PixelChecksum(
int Left,
int Top,
int Right,
int Bottom,
int Step);
409 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
410 public static extern int AU3_PixelGetColor(
int X,
int Y);
435 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
436 public static extern void AU3_PixelSearch(
447 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
448 public static extern int AU3_ProcessClose([MarshalAs(UnmanagedType.LPWStr)]
string Process);
451 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
452 public static extern int AU3_ProcessExists([MarshalAs(UnmanagedType.LPWStr)]
string Process);
455 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
456 public static extern int AU3_ProcessSetPriority([MarshalAs(UnmanagedType.LPWStr)]
string Process,
int Priority);
460 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
461 public static extern int AU3_ProcessWait([MarshalAs(UnmanagedType.LPWStr)]
string Process,
int Timeout);
464 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
465 public static extern int AU3_ProcessWaitClose([MarshalAs(UnmanagedType.LPWStr)]
string Process,
int Timeout);
468 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
469 public static extern int AU3_RegDeleteKey([MarshalAs(UnmanagedType.LPWStr)]
string fpsKeyname);
472 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
473 public static extern int AU3_RegDeleteVal(
474 [MarshalAs(UnmanagedType.LPWStr)]
string fpsKeyname,
475 [MarshalAs(UnmanagedType.LPWStr)]
string ValueName);
478 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
479 public static extern void AU3_RegEnumKey(
480 [MarshalAs(UnmanagedType.LPWStr)]
string fpsKeyname,
482 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder Result,
486 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
487 public static extern void AU3_RegEnumVal(
488 [MarshalAs(UnmanagedType.LPWStr)]
string fpsKeyname,
490 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder Result,
494 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
495 public static extern void AU3_RegRead(
496 [MarshalAs(UnmanagedType.LPWStr)]
string fpsKeyname,
497 [MarshalAs(UnmanagedType.LPWStr)]
string Valuename,
498 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder RetText,
502 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
503 public static extern int AU3_RegWrite(
504 [MarshalAs(UnmanagedType.LPWStr)]
string fpsKeyname,
505 [MarshalAs(UnmanagedType.LPWStr)]
string Valuename,
506 [MarshalAs(UnmanagedType.LPWStr)]
string Type,
507 [MarshalAs(UnmanagedType.LPWStr)]
string Value);
510 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
511 public static extern int AU3_Run(
512 [MarshalAs(UnmanagedType.LPWStr)]
string Run,
513 [MarshalAs(UnmanagedType.LPWStr)]
string Dir,
517 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
518 public static extern int AU3_RunAsSet(
519 [MarshalAs(UnmanagedType.LPWStr)]
string User,
520 [MarshalAs(UnmanagedType.LPWStr)]
string Domain,
521 [MarshalAs(UnmanagedType.LPWStr)]
string Password,
525 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
526 public static extern int AU3_RunWait(
527 [MarshalAs(UnmanagedType.LPWStr)]
string Run,
528 [MarshalAs(UnmanagedType.LPWStr)]
string Dir,
532 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
533 public static extern void AU3_Send([MarshalAs(UnmanagedType.LPWStr)]
string SendText,
int Mode);
537 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
538 public static extern void AU3_SendA([MarshalAs(UnmanagedType.LPStr)]
string SendText,
int Mode);
541 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
542 public static extern int AU3_Shutdown(
int Flags);
545 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
546 public static extern void AU3_Sleep(
int Milliseconds);
549 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
550 public static extern void AU3_StatusbarGetText(
551 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
552 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
554 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder StatusText,
558 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
559 public static extern void AU3_ToolTip(
560 [MarshalAs(UnmanagedType.LPWStr)]
string Tip,
565 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
566 public static extern void AU3_WinActivate(
567 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
568 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
571 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
572 public static extern int AU3_WinActive(
573 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
574 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
577 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
578 public static extern int AU3_WinClose(
579 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
580 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
583 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
584 public static extern int AU3_WinExists(
585 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
586 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
589 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
590 public static extern int AU3_WinGetCaretPosX();
593 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
594 public static extern int AU3_WinGetCaretPosY();
597 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
598 public static extern void AU3_WinGetClassList(
599 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
600 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
601 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder RetText,
605 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
606 public static extern int AU3_WinGetClientSizeHeight(
607 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
608 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
611 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
612 public static extern int AU3_WinGetClientSizeWidth(
613 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
614 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
617 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
618 public static extern void AU3_WinGetHandle(
619 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
620 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
621 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder RetText,
625 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
626 public static extern int AU3_WinGetPosHeight(
627 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
628 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
631 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
632 public static extern int AU3_WinGetPosWidth(
633 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
634 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
637 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
638 public static extern int AU3_WinGetPosX(
639 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
640 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
643 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
644 public static extern int AU3_WinGetPosY(
645 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
646 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
649 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
650 public static extern void AU3_WinGetProcess(
651 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
652 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
653 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder RetText,
657 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
658 public static extern int AU3_WinGetState(
659 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
660 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
663 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
664 public static extern void AU3_WinGetText(
665 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
666 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
667 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder RetText,
671 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
672 public static extern void AU3_WinGetTitle(
673 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
674 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
675 [MarshalAs(UnmanagedType.LPWStr)]StringBuilder RetText,
679 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
680 public static extern int AU3_WinKill(
681 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
682 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText);
685 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
686 public static extern int AU3_WinMenuSelectItem(
687 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
688 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
689 [MarshalAs(UnmanagedType.LPWStr)]
string Item1,
690 [MarshalAs(UnmanagedType.LPWStr)]
string Item2,
691 [MarshalAs(UnmanagedType.LPWStr)]
string Item3,
692 [MarshalAs(UnmanagedType.LPWStr)]
string Item4,
693 [MarshalAs(UnmanagedType.LPWStr)]
string Item5,
694 [MarshalAs(UnmanagedType.LPWStr)]
string Item6,
695 [MarshalAs(UnmanagedType.LPWStr)]
string Item7,
696 [MarshalAs(UnmanagedType.LPWStr)]
string Item8);
699 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
700 public static extern void AU3_WinMinimizeAll();
703 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
704 public static extern void AU3_WinMinimizeAllUndo();
707 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
708 public static extern int AU3_WinMove(
709 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
710 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
717 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
718 public static extern int AU3_WinSetOnTop(
719 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
720 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
724 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
725 public static extern int AU3_WinSetState(
726 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
727 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
731 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
732 public static extern int AU3_WinSetTitle(
733 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
734 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
735 [MarshalAs(UnmanagedType.LPWStr)]
string NewTitle);
738 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
739 public static extern int AU3_WinSetTrans(
740 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
741 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
745 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
746 public static extern int AU3_WinWait(
747 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
748 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
753 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
754 public static extern int AU3_WinWaitA(
755 [MarshalAs(UnmanagedType.LPStr)]
string fpsTitle,
756 [MarshalAs(UnmanagedType.LPStr)]
string fpsText,
760 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
761 public static extern int AU3_WinWaitActive(
762 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
763 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
768 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
769 public static extern int AU3_WinWaitActiveA(
770 [MarshalAs(UnmanagedType.LPStr)]
string fpsTitle,
771 [MarshalAs(UnmanagedType.LPStr)]
string fpsText,
775 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
776 public static extern int AU3_WinWaitClose(
777 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
778 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
783 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
784 public static extern int AU3_WinWaitCloseA(
785 [MarshalAs(UnmanagedType.LPStr)]
string fpsTitle,
786 [MarshalAs(UnmanagedType.LPStr)]
string fpsText,
790 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
791 public static extern int AU3_WinWaitNotActive(
792 [MarshalAs(UnmanagedType.LPWStr)]
string fpsTitle,
793 [MarshalAs(UnmanagedType.LPWStr)]
string fpsText,
798 [DllImport(
@"C:\Program Files(x86)\AutoIt3\AutoItX\AutoItX3.dll", SetLastError =
true, CharSet = CharSet.Auto)]
799 public static extern int AU3_WinWaitNotActiveA(
800 [MarshalAs(UnmanagedType.LPStr)]
string fpsTitle,
801 [MarshalAs(UnmanagedType.LPStr)]
string fpsText,
816 StringBuilder clip =
new StringBuilder();
819 Log.Logger.Instance.LogFunctionStartDebug(
"AutoItX3.ClipGet");
821 AutoItX3.AU3_ClipGet(clip, clip.Length);
823 Log.Logger.Instance.LogPrint(
AutoItX3.AU3_error().ToString());
825 Log.Logger.Instance.LogFunctionEndDebug(clip.ToString());
827 return clip.ToString();
837 public static void Run(
string process,
string dir)
839 AU3_Run(process, dir, SW_SHOWMAXIMIZED);
855 public static void Run(
string process,
string dir,
int showflag)
857 AU3_Run(process, dir, showflag);
static void Run(string process, string dir, int showflag)
Runs an external program.
static void Run(string process, string dir)
Runs an external program.
static string ClipGet()
List den aktuellen Wert des Clipboard via Autoit.