<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Серый форум &mdash; VBA, Word: Событие KeyDown]]></title>
	<link rel="self" href="http://forum.script-coding.com/extern.php?action=feed&amp;tid=11614&amp;type=atom" />
	<updated>2016-05-21T15:37:28Z</updated>
	<generator>PunBB</generator>
	<id>http://forum.script-coding.com/viewtopic.php?id=11614</id>
		<entry>
			<title type="html"><![CDATA[Re: VBA, Word: Событие KeyDown]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104028#p104028" />
			<content type="html"><![CDATA[<p>Скажите, что это за тип, откуда он берётся и как его объявить. Почему он указан в приложеной ссылке, ведь у меня на другом ПК в офисе 2007 через Integer работает как оказалось. Правда не как хотел, но отвечает. Вот это:<br />Sub commandbutton1_keydown(ByVal KeyCode As MSForms.ReturnInteger, ByVal Shift As Integer)<br />&nbsp; &nbsp;If KeyCode = vbKeyTab Then MsgBox &quot;test right&quot;<br />&nbsp; &nbsp;If KeyCode = vbKeyTab And Shift = 1 Then MsgBox &quot;ответ&quot;<br />End Sub<br />При шифт-таб оба сообщения выдаёт. Ответьте тогда вот про этот пример не привязанный к другим программным текстам, он на пустом &quot;проекте&quot;.</p>]]></content>
			<author>
				<name><![CDATA[o5andrey]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=31046</uri>
			</author>
			<updated>2016-05-21T15:37:28Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104028#p104028</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[VBA, Word: Событие KeyDown]]></title>
			<link rel="alternate" href="http://forum.script-coding.com/viewtopic.php?pid=104008#p104008" />
			<content type="html"><![CDATA[<p>Private Sub NextN_KeyDown(ByVal KeyCode As MSForms.ReturnInteger, ByVal Shift As <strong>fmShiftState</strong>)<br />&nbsp; &nbsp;If KeyCode = vbKeyTab Then Call NextN_Click<br />&nbsp; &nbsp;If KeyCode = vbKeyTab And Shift = 1 Then Call PrevN_Click&nbsp; &nbsp;&#039; (NextN&nbsp; - это кнопка)<br />End Sub</p><p>Не запускается - не понимает &quot;...Shift As fmShiftState&quot;:<br />Compile error:<br />User-defined type not defined</p><p>Раньше у меня было написано Shift As Integer, запускалось, но по Shift+Tab не работало, только по Tab.<br />Галочка в References &quot;Microsoft Forms 2.0 Object Library&quot; стоит.</p><p>Тут написано что я вроде правильно делаю...<br />http://www.intuit.ru/studies/courses/112/112/lecture/3291?page=7</p>]]></content>
			<author>
				<name><![CDATA[o5andrey]]></name>
				<uri>http://forum.script-coding.com/profile.php?id=31046</uri>
			</author>
			<updated>2016-05-21T03:26:25Z</updated>
			<id>http://forum.script-coding.com/viewtopic.php?pid=104008#p104008</id>
		</entry>
</feed>
