ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

¨p¥ÎÅܼÆ?

¨p¥ÎÅܼÆ?

¬YÅܼƥu¥Î¦b¦Û¤wªº¤u§@ªí( private)
·Q¦b§Oªº¤u§@ªí¸Ìªºµ{§Ç§ïÅÜ¥¦ªº­È?¦p¦ó°µ?

private -> Public

TOP

¥»©«³Ì«á¥Ñ luhpro ©ó 2014-10-20 21:40 ½s¿è
¬YÅܼƥu¥Î¦b¦Û¤wªº¤u§@ªí( private)
·Q¦b§Oªº¤u§@ªí¸Ìªºµ{§Ç§ïÅÜ¥¦ªº­È?¦p¦ó°µ?
t8899 µoªí©ó 2014-10-20 19:44

private -> Public
bobomi µoªí©ó 2014-10-20 21:02


¸É¥R 2#
1. ÅܼƳ]¬° Public ¥u¥i©ñ¦b ²Ä¤@­Ó Sub «ü¥Oªº¤W¤è,
¥B©ñ¦b Option Explicit ªº¤W¤è©Î¤U¤è¬Ò¥i.

2. °²³]¦b Sheets("Sheet1") ¦³³]©w Public vN
«h¦b«D Sheets("Sheet1") ¤¤¨Ï¥Î®É, (¨Ò¦p  Sheets("Sheet3"), ©Î¬O ThisWorkBook...)
­n¥Î Sheets("Sheet1").vN ªº§Î¦¡¨Ó¨Ï¥Î¸ÓÅܼÆ.

3. ­Y·Q¦b©Ò¦³°Ï°ì¦@¥Î¦¹ÅܼÆ,
½Ð±N¸Ó Public ªºÅܼƳ]¦b Module ¤º.

4. ­Y¥Hª«¥ó¾É¦Vªº·§©À¨Ó°µªº¸Ü,
À³¸Ó¬O±N¸ÓÅܼƳ]¬° Private ,
¦Ó¦b¸Ó Sheet ¤º·s¼W¤@­Ó Public Sub µ{§Ç¦W(±ý³]©wªº­È) ªº¤è¦¡¨Ó¹ê²{­×§ï©ÎÅã¥Ü¸ÓÅܼƪº¥\¯à,
¬Û¦Pªº¥i¥Î Sheets("Sheet1"). µ{§Ç¦W(±ý³]©wªº­È) ªº§Î¦¡©I¥s­×§ï¦¹ÅܼƤº®e.
³o¼Ëªº¸Ü­Y¤£³z¹L³o­Óµ{§Ç¬OµLªk­×§ï¦¹Åܼƪº.

TOP

¥»©«³Ì«á¥Ñ t8899 ©ó 2014-10-20 21:44 ½s¿è
¸É¥R 2#
1. ÅܼƳ]¬° Public ¥u¥i©ñ¦b ²Ä¤@­Ó Sub «ü¥Oªº¤W¤è,
¥B©ñ¦b Option Explicit ªº¤W¤è©Î ...
luhpro µoªí©ó 2014-10-20 21:33

private ³£§ï¦¨ public ¦p¹Ï

TOP

¦³ declare ªº¤£¯à§ï¦¨ Public ¥u¯à¥Î Private

TOP

¦^´_ 4# t8899
­n¥Î¤W­z 4. ªº¤è¦¡¨Ó¹ê²{.

TOP

©Ò¥H§A¥u¦³¤@­Ó Dim leaving As Integer ¥i¥H§ï¦¨
Public leaving As Integer

TOP

§Ú«á¨Ó·Q¨ìªº¤èªk¬O¡Aª½±µ¼g¦bprivate ªº¤u§@ªí(sheet1)
sub abc123()
§ïÅÜÅܼƪº­È
end sub
¦b§Oªº¤u§@¤W¸Ì
¥Î sheet1.abc123 ´N¥i¥H¤F

TOP

        ÀR«ä¦Û¦b : ¡i»X½ªªº¦Û¥Ñ¡j¤H±`¦b¤°»ò³£¥i¥H¦Û¥Ñ¦Û¦bªº®É­Ô¡A«o³Q³oºØÀH¤ß©Ò±ýªº¦Û¥Ñ»X½ª¡AµêÂY®É¥ú¦Ó²@µLıª¾¡C
ªð¦^¦Cªí ¤W¤@¥DÃD