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

[µo°Ý] ½Ð±Ðweb¸ê®ÆÂ^¨ú°ÝÃD

[µo°Ý] ½Ð±Ðweb¸ê®ÆÂ^¨ú°ÝÃD

¥Øªº:±N¹d¦ëºô¤Wªº¾ú¥v¸ê®Æ(¥i¥H¦Û¥Ñ¿ï¨ú¤é´Á)¡A¥Hvbaµ{¦¡¦Û°Ê¶×¤Jexcel¤º
°ÝÃD:µ{¦¡°õ¦æ«á¡A¨Ã«D¨C¦¸³£·|¦¨¥\§ì¨ú¸ê®Æ¡A¦³®É¦¨¥\¡A¦³®É¥¢±Ñ¡A
¤U¦C»¡©ú¡A¬O§Úªºµ{¦¡³¡¤À¡A³Â·Ð¦U¦ìÀ°¦£¸Ñ´b¡A¤p§Ì·P¿E¤£ºÉ!!

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------
§Ú¬O¥Î¿ý»s¥¨¶°¤U¥h¼gªº¡AµM«á§â¥L½Æ»s¨ì«ö¶s(CommandButton1)¸Ì­±

¥N½X¡B¤é´Áªº³¡¤À§Ú¤À§O¥Î¥N½X=cells(1,3)¡B°_©l=Cells(2, 3) ¡B²×¤î=Cells(3, 3)>>>>³o­Ó³¡¤À¤]¸Õ¹L¥HTextBox1¡BTextBox2¡BTextBox3·í§@¿é¤J

±µµÛ¹B¦æ«á²Ä¤@¦¸³q±`³£¸ê®Æ§ì¨ú³£OK¡A µM«á´N³£²§±`¤F¡A¦ý¦³®É­ÔÁÙ¬O·|©¿µM¤S¦¨¥\¤@¦¸

Private Sub CommandButton1_Click()
With ActiveSheet.QueryTables.Add(Connection:= _
"URL;http://www.cnyes.com/twstock/ps_historyprice.aspx?code=" & cells(1,3) & "&ctl00$ContentPlaceHolder1$startText=" & Cells(2, 3) & "&ctl00$ContentPlaceHolder1$endText=" & Cells(3, 3) _
, Destination:=Range("$A$10"))
.Name = "16_24"
.FieldNames = True
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = False
.RefreshOnFileOpen = False
.BackgroundQuery = False
.RefreshStyle = xlOverwriteCells
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = False
.RefreshPeriod = 0
.WebSelectionType = xlSpecifiedTables
.WebFormatting = xlWebFormattingNone
.WebTables = "2"
.WebPreFormattedTextToColumns = True
.WebConsecutiveDelimitersAsOne = True
.WebSingleBlockTextImport = False
.WebDisableDateRecognition = False
.WebDisableRedirections = False
.Refresh BackgroundQuery:=False
End With

¤£¦n·N«ä§Ú¦b¸É¥R¤@¤U: ¥N½X¬OªÑ²¼¥N½X
                                          °_©l¬O°_©l¤é­È:®æ¦¡¬°yyyy/mm/dd ex:2012/01/01 (¤ë¡B¤é¤@©w­n¨â¦ì¼Æ)
                                          ²×¤î¬O²×¤î¤é´Á:®æ¦¡¬°yyyy/mm/dd

TOP

        ÀR«ä¦Û¦b : ­n§åµû§O¤H®É¡A¥ý·Q·Q¦Û¤v¬O§_§¹¬üµL¯Ê¡C
ªð¦^¦Cªí ¤W¤@¥DÃD