<div dir="ltr">Hi Mattias,<div><br></div><div>thanks to your suggestions, the results improved, but they are not what I expected.</div><div><br></div><div>After polishing my code ('clean up your project output directory and rebuild'), the warnings disappeared and now only one instance of notepad is created. </div><div><br></div><div>In the instance, the weird text </div><div>/-5 07:36 28/10/2024507:36 28/10/2024</div><div>is written.</div><div><br></div><div>The good part is: date and time are correct :)</div><div>The bad part is: I was expecting the string 'some text' to be written :) </div><div><br></div><div>The mistery thickens :)</div><div><br></div><div>procedure TForm1.btNotepadClick(Sender: TObject);<br>var<br> app: HWND;<br>begin<br> WinExec('notepad.exe', SW_NORMAL);<br> app := FindWindow(nil,'senza nome - blocco note di windows');<br> if app = 0 then<br> exit;<br> sleep(500);<br> KeyInput.Press('some text');<br>end;<br></div><div><br></div><div>Any idea?</div><div><br></div><div>Thank you</div><div><br></div><div>Peppe</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sun, Oct 27, 2024 at 11:39 PM Mattias Gaertner via lazarus <<a href="mailto:lazarus@lists.lazarus-ide.org">lazarus@lists.lazarus-ide.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
<br>
On 10/27/24 19:41, duilio foschi via lazarus wrote:<br>
>[...]<br>
> Probably it is not important, but when I compile my applet, I get the<br>
> following warnings:<br>
> <br>
> Messages, Hints: 12<br>
> Note: Duplicate unit "winmouseinput" in "p201827", orphaned ppu<br>
> "C:\lazarus_projects\automation\lib\i386-win32\winmouseinput.ppu"<br>
> Note: Duplicate unit "winmouseinput" in "LazMouseAndKeyInput 0.9",<br>
> ppu="C:\lazarus\components\mouseandkeyinput\lib\i386-win32\win32\winmouseinput.ppu",<br>
> source="C:\lazarus\components\mouseandkeyinput\winmouseinput.pas"<br>
<br>
Maybe you added the unit path C:\lazarus\components\mouseandkeyinput\ to <br>
your project. Don't. Adding the package to your project is enough.<br>
Then clean up your project output directory and rebuild.<br>
<br>
Mattias<br>
-- <br>
_______________________________________________<br>
lazarus mailing list<br>
<a href="mailto:lazarus@lists.lazarus-ide.org" target="_blank">lazarus@lists.lazarus-ide.org</a><br>
<a href="https://lists.lazarus-ide.org/listinfo/lazarus" rel="noreferrer" target="_blank">https://lists.lazarus-ide.org/listinfo/lazarus</a><br>
</blockquote></div>