½Ð±Ðinputbox¦h«¿é¤Jªº°ÝÃD¡C
| ©«¤l209 ¥DÃD43 ºëµØ0 ¿n¤À262 ÂI¦W0  §@·~¨t²Îwin 7 ³nÅ骩¥»office 20** ¾\ŪÅv20 ©Ê§O¨k µù¥U®É¶¡2011-11-3 ³Ì«áµn¿ý2017-4-16 
 | 
 ½Ð±Ðinputbox¦h«¿é¤Jªº°ÝÃD¡C
| ¦U¦ì¦n¡A½Ð±Ð¤@Ó°ÝÃD¡G§Ú»Ýn¦bexcel¸Ì±¡A·í¨Ï¥ÎªÌÂI¿ï«ö¶s¤§«á¡A¸õ¥X¤@Óµøµ¡¡A¸ß°Ýþ¨âÃDn¹ï´«¡A¨Ï¥ÎªÌ¿é¤J¨âÓÃD¸¹¤§«á¡Aµ{¦¡·|±N¨º¨âÃDªº¬Y¨Ç¯S©wÄæ¦ì¸ê®Æ¹ï´«¡C Ä´¦pªþ¥ó©Ò¥Ü¡A«ö¤U¤@Ó«ö¶s¡A¥X²{¤@Óµøµ¡¡A¥X²{¡§¿é¤J¹ï´«ÃD¸¹¡¨¡A¨Ï¥ÎªÌ¿é¤J¡§3¡¨©M¡§5¡¨¡A´N·|§â¡§¤@¤G¤T¥|¤¡¨(B4:F4)»P¡§¹«¤ûªê¨ßÀs¡¨(B6:F6)µ¹¹ï´«¡AÃD¸¹«hºû«ù¤£ÅÜ¡C
     | 
 | 
|  | 
|  |  | 
|  |  | 
| ©«¤l4901 ¥DÃD44 ºëµØ24 ¿n¤À4916 ÂI¦W265  §@·~¨t²ÎWindows 7 ³nÅ骩¥»Office 20xx ¾\ŪÅv150 ©Ê§O¨k ¨Ó¦Û¥x¥_ µù¥U®É¶¡2010-4-30 ³Ì«áµn¿ý2025-10-29 
                
 | 
                
| ¦^´_ 1# tku0216 ½Æ»s¥N½XPrivate Sub CommandButton1_Click()
Dim i%, j%, a As Range, b As Range, ar(), ar1()
i = InputBox("¿é¤JÃD¸¹1")
j = InputBox("¿é¤JÃD¸¹2")
Set a = Columns("A").Find(i, lookat:=xlWhole)
Set b = Columns("A").Find(j, lookat:=xlWhole)
If a Is Nothing Or b Is Nothing Then MsgBox "µL¦¹ÃD¸¹": Exit Sub
ar = a.Offset(, 1).Resize(, 5).Value
ar1 = b.Offset(, 1).Resize(, 5).Value
a.Offset(, 1).Resize(, 5) = ar1
b.Offset(, 1).Resize(, 5) = ar
End Sub
 | 
 | 
| ¾Ç®üµL²P_¤£®¢¤U°Ý | 
|  |  | 
|  |  | 
| ©«¤l209 ¥DÃD43 ºëµØ0 ¿n¤À262 ÂI¦W0  §@·~¨t²Îwin 7 ³nÅ骩¥»office 20** ¾\ŪÅv20 ©Ê§O¨k µù¥U®É¶¡2011-11-3 ³Ì«áµn¿ý2017-4-16 
 | 
                
| ·PÁ¿½¤j¡A§Úè¤]¸Õ¥X¤F¤èªk Private Sub CommandButton1_Click()
 Dim q1, q2 As Integer
 q1 = InputBox("¿é¤JÃD¸¹¤@") + 2 '¦]¬°§Úªº²Ä¤@ÃD¬O±q²Ä¤T¦C¶}©l
 q2 = InputBox("¿é¤JÃD¸¹¤G") + 2
 r1 = Range(Cells(q1, 3), Cells(q1, 15)) '±N¬YÃD²Ä3Äæ~²Ä15Äæªº¸ê®Æ¹ï´«
 r2 = Range(Cells(q2, 3), Cells(q2, 15))
 msgaa = MsgBox("½T»{²Ä" & q1 - 2 & "»P²Ä" & q2 - 2 & "ÃD¹ï´«?~~", 4)
 If msgaa = 6 Then  'Y½T»{¹ï´«¡A«ö¤Uok
 Range(Cells(q2, 3), Cells(q2, 15)) = r1
 Range(Cells(q1, 3), Cells(q1, 15)) = r2
 End If
 
 End Sub
 | 
 | 
|  | 
|  |  | 
|  |  | 
| ©«¤l209 ¥DÃD43 ºëµØ0 ¿n¤À262 ÂI¦W0  §@·~¨t²Îwin 7 ³nÅ骩¥»office 20** ¾\ŪÅv20 ©Ê§O¨k µù¥U®É¶¡2011-11-3 ³Ì«áµn¿ý2017-4-16 
 | 
                
| ¿½¤j±z¦n¡A §Úµo²{±zªºµ{¦¡½X¡AÀ³¦b¾¹7»P8¦æ¤§¶¡¥[¤@Óelse¡A§_«hµLªk°õ¦æ¡AÁÙ¦³¦ü¥G¨S¦³¥[¤Jend ifªº¸Ü¡Aµ{¦¡¤]µLªk°õ¦æ¡A¥i¥H½Ð°ÝÀ³¸Ó¥[¦bþ¸Ì¶Ü¡H
 | 
 | 
|  | 
|  |  | 
|  |  | 
| ©«¤l559 ¥DÃD58 ºëµØ0 ¿n¤À626 ÂI¦W0  §@·~¨t²Îwin8 ³nÅ骩¥»office2013 ¾\ŪÅv50 ©Ê§O¨k ¨Ó¦ÛTW µù¥U®É¶¡2010-11-22 ³Ì«áµn¿ý2024-6-14 
 | 
                
| ¦^´_ 4# tku0216 
 ¥H¤U´XºØifªº¨Ï¥Î¤è¦¡,¨Ñ§A°Ñ¦Ò~
 (H¤j¤jªº¼gªk~ ¨Ã¨S¦³°ÝÃDò~ )
 
 if   ±ø¥ó  then
 ²Å¦X±ø¥ó,°õ¦æµ²ªG
 end if
 
 if   ±ø¥ó  then
 ²Å¦X±ø¥ó,°õ¦æµ²ªG
 else
 ¤£²Å¦X±ø¥ó,°õ¦æµ²ªG
 end if
 
 if   ±ø¥ó1  then
 ²Å¦X±ø¥ó,°õ¦æµ²ªG
 elseif   ±ø¥ó2  then
 ²Å¦X±ø¥ó2,°õ¦æµ²ªG
 else
 ¤£²Å¦X±ø¥ó1»P¤£²Å¦X±ø¥ó2,°õ¦æµ²ªG
 end if
 
 if ±ø¥ó  then exit sub
 | 
 | 
| ¾Ç²ß¤~¯à´£¤É¦Û¤v | 
|  |  | 
|  |  | 
| ©«¤l2035 ¥DÃD24 ºëµØ0 ¿n¤À2031 ÂI¦W0  §@·~¨t²ÎWin7 ³nÅ骩¥»Office2010 ¾\ŪÅv100 ©Ê§O¨k µù¥U®É¶¡2012-3-22 ³Ì«áµn¿ý2024-2-1 
 | 
                
| ¥»©«³Ì«á¥Ñ c_c_lai ©ó 2012-7-27 15:24 ½s¿è 
 ¦^´_ 3# tku0216
 ²Ä7¦æ¡B»P²Ä 8¦æ¬O¨âÓ¤£¦PÅ骺±Ôz¡C°£«D¬O§A±N If ±Ôz¼g¦¨¡G
 If a Is Nothing Or b Is Nothing Then
 MsgBox "µL¦¹ÃD¸¹"
 Exit Sub
 End If
 ¥t¥~§Ú¬°¤F¦Û§Ú´ú¸Õ¡A µy¥[×§ï¤F i%, j% ªº«Å§i¤è¦¡¡G
 ' Dim i%, j%, a As Range, b As Range, ar(), ar1()
 Dim i, j, a As Range, b As Range, ar(), ar1()
 
 i = InputBox("¿é¤JÃD¸¹1")    ' i% ¦pªG¿é¤JȬ° a¡A«h·|¥X²{«¬ºA¤£²Åªº¿ù»~°T®§
 j = InputBox("¿é¤JÃD¸¹2")    ' j ¤¹³\¿é¤J¥ô¦ó¼ÆÈ¡B¦r¤¸©Î¦r¦ê
 | 
 | 
|  | 
|  |  | 
|  |  | 
| ©«¤l209 ¥DÃD43 ºëµØ0 ¿n¤À262 ÂI¦W0  §@·~¨t²Îwin 7 ³nÅ骩¥»office 20** ¾\ŪÅv20 ©Ê§O¨k µù¥U®É¶¡2011-11-3 ³Ì«áµn¿ý2017-4-16 
 | 
                
| ÁÙ¦³·Q½Ð±Ð¡Ainputboxªº³¡¤À¡A¦pªG·QÅý¨Ï¥ÎªÌ¿é¤J«D¼Æ¦r®É¡A§YÅã¥Ü¿ù»~°T®§¦Ón¨D«·s¿é¤J¡A§Ú¬Ýºô¸ô¤Wªº°µªk¬O¥Îapplication.inputbox¤èªk¡A¦ýYn¥[¤J¨Ï¥ÎªÌ¥i¥HÂI¿ïcancel®É¡Aµ{¦¡ÀH§Y¸õ¥X¡A½Ð°ÝÀ³¸Ó¦p¦ó³B¸Ì¡H | 
 | 
|  | 
|  |  | 
|  |  |