Пример #1
0
        public void FindTextTest()
        {
            using var wnd = new DlgWin(RegisterWindowMessage(FINDMSGSTRING));
            var fw = new SafeCoTaskMemString(261);
            var fr = new FINDREPLACE
            {
                lStructSize   = (uint)Marshal.SizeOf(typeof(FINDREPLACE)),
                hwndOwner     = wnd.MessageWindowHandle,
                lpstrFindWhat = (IntPtr)fw,
                wFindWhatLen  = (ushort)fw.Length,
            };

            Assert.That(wnd.hdlg = FindText(ref fr), Is.True);
        }
Пример #2
0
 public extern static IntPtr FindText(ref FINDREPLACE fdr);