婷婷综合国产,91蜜桃婷婷狠狠久久综合9色 ,九九九九九精品,国产综合av

主頁 > 知識庫 > 利用vbs類實現css按鈕的代碼

利用vbs類實現css按鈕的代碼

熱門標簽:深圳外呼系統收費 拉薩外呼系統業務 合肥高德地圖標注 百度地圖標注是什么意思 怎么看地圖標注 廣州ai電銷機器人一般多少錢 外呼線路中繼線是什么 外呼系統telrobot 外呼系統免費招代理
復制代碼 代碼如下:


rem 文章標題: 利用vbs類實現css按鈕 
rem 作者:yanek 
rem 聯系:aspboy@263.net 

Class CssButton 

  Public Name 
  Public BackColor 
  Public BorderColor 
  Public Font 
  Public FontColor 
  Public Width 
  Public Text 
  Public Url 

  Public MouseOverColor 

     
  Public Function GenerateStyleTag() 
    'Create the STYLE tag 
    Dim strStyle 
    strStyle =     "STYLE TYPE=""text/css"">"  vbCrLf  _ 
                   "!--"  vbCrLf  _ 
                   "#mybutton"  Name  "   {border-style: inset; "  vbCrLf  _ 
                   "             border-color: "  BorderColor  ";"  vbCrLf  _ 
                   "             background-color: "  BackColor  ";"  vbCrLf  _ 
                   "             width: "  Width  ";"  vbCrLf  _ 
                   "             text-align: center; }"  vbCrLf  vbCrLf  vbCrLf  _ 
                   "A.buttontext"  Name  " {color: "  FontColor  "; "  vbCrLf  _ 
                   "              text-decoration: none; "  vbCrLf  _ 
                   "              font: "  Font  ";"  vbCrLf  _ 
                   "              cursor: hand; }"  vbCrLf  vbCrLf  vbCrLf  _ 
                   ".buttonover"  Name  " {color: "  MouseOverColor  ";"  vbCrLf  _ 
                   "             text-decoration: none; "  vbCrLf  _ 
                   "             font: "  Font  ";"  vbCrLf  _ 
                   "             cursor: hand; }"  vbCrLf  _ 
                   " // -->"  vbCrLf  _ 
                   "/STYLE>" 

    GenerateStyleTag = strStyle 
  End Function 


  Public Function GenerateButtonTag() 
    Dim strHTML 
    strHTML = "a href="""  Url  """ class=""buttontext"  Name  """ "  _ 
              "onMouseOver=""this.className='buttonover"  Name  "';"" "  _ 
              "onMouseOut=""this.className='buttontext"  Name  "';"">"  _ 
              vbCrLf  "div id=""mybutton"  Name  """>"  vbCrLf  Text  vbCrLf  "/div>/a>"  vbCrLf 

    GenerateButtonTag = strHTML 
  End Function 

End Class 

rem 建立類的實例 

Dim btnYahoo, btnLycos 
Set btnYahoo = New CssButton 
Set btnLycos = New CssButton 

rem 設置按鈕對象的相關屬性 

btnYahoo.BackColor = "#aaaaaa" 
btnYahoo.BorderColor = "#bbbbbb" 
btnYahoo.Font = "bold 12pt Verdana" 
btnYahoo.FontColor = "black" 
btnYahoo.Width = "80px" 
btnYahoo.MouseOverColor = "yellow" 
btnYahoo.Url = "http://www.yahoo.com/" 
btnYahoo.Name = "yahoo" 
btnYahoo.Text = "Yahoo!" 

rem 調用方法輸出按鈕 
Response.Write btnYahoo.GenerateStyleTag() 
Response.Write btnYahoo.GenerateButtonTag() 
Response.Write "p> /p>" 



rem 設置按鈕對象的相關屬性 
btnLycos.BackColor = "#aaaaaa" 
btnLycos.BorderColor = "#bbbbbb" 
btnLycos.Font = "10pt Arial" 
btnLycos.FontColor = "black" 
btnLycos.Width = "70px" 
btnLycos.MouseOverColor = "yellow" 
btnLycos.Url = "http://www.lycos.com/" 
btnLycos.Name = "lycos" 
btnLycos.Text = "Lycos" 

rem 調用方法輸出按鈕 
Response.Write btnLycos.GenerateStyleTag() 
Response.Write btnLycos.GenerateButtonTag() 
%> 



演示:http://www.cnaspol.com/vbsclasscssbutton.asp

標簽:廣安 臺灣 周口 六安 玉林 延安 嘉興 漳州

巨人網絡通訊聲明:本文標題《利用vbs類實現css按鈕的代碼》,本文關鍵詞  利用,vbs,類,實現,css,按鈕,;如發現本文內容存在版權問題,煩請提供相關信息告之我們,我們將及時溝通與處理。本站內容系統采集于網絡,涉及言論、版權與本站無關。
  • 相關文章
  • 下面列出與本文章《利用vbs類實現css按鈕的代碼》相關的同類信息!
  • 本頁收集關于利用vbs類實現css按鈕的代碼的相關信息資訊供網民參考!
  • 推薦文章
    主站蜘蛛池模板: 拉萨市| 镶黄旗| 资中县| 佛教| 乌拉特前旗| 布拖县| 多伦县| 吐鲁番市| 和田县| 麦盖提县| 叶城县| 简阳市| 彭阳县| 桃源县| 夏河县| 富宁县| 定结县| 黄龙县| 武夷山市| 潞城市| 横山县| 伊宁市| 北碚区| 泊头市| 武乡县| 衡水市| 扎赉特旗| 台山市| 桂平市| 大兴区| 岑溪市| 宁远县| 石林| 新沂市| 平山县| 绿春县| 西乌| 乡城县| 沁水县| 伽师县| 安远县|