我的一个程序中,需要在工具栏中添加设置字体颜色、填充颜色和表格框线的控件,但是我找不到头绪,请教各位大虾,给点思路。100分赠送,不够另外给。

解决方案 »

  1.   

    Public Declare Function GetCharABCWidths Lib "gdi32" Alias "GetCharABCWidthsA" (ByVal hdc As Long, ByVal uFirstChar As Long, ByVal uLastChar As Long, lpabc As ABC) As Long
    Public Declare Function AddFontResource Lib "gdi32" Alias "AddFontResourceA" (ByVal lpFileName As String) As LongPublic Declare Function CreateFont Lib "gdi32" Alias "CreateFontA" (ByVal H As Long, ByVal W As Long, ByVal E As Long, ByVal O As Long, ByVal W As Long, ByVal I As Long, ByVal u As Long, ByVal S As Long, ByVal C As Long, ByVal OP As Long, ByVal CP As Long, ByVal Q As Long, ByVal PAF As Long, ByVal F As String) As LongPublic Declare Function CreateFontIndirect Lib "gdi32" Alias "CreateFontIndirectA" (lpLogFont As LOGFONT) As LongPublic Declare Function TextOut Lib "gdi32" Alias "TextOutA" (ByVal hdc As Long, ByVal x As Long, ByVal y As Long, ByVal lpString As String, ByVal nCount As Long) As Long
      

  2.   

    common dialog control:字体颜色控件;
    windows common control:->ToolBar:工具栏
    还要什么头绪?
      

  3.   

    直接在工具栏上加上快捷按扭,在按扭的单击事件下写代码。
        CommonDialog1.ShowFont '字体
        CommonDialog1.ShowColor '颜色
      

  4.   

    使用commandDialog可没有办法形成在word上的操作效果啊
      

  5.   

    有颜色的用图片就是了,不过toolbar实在弱,国外的站上已经开发出比较好看的toolbar和word差不多你可以找下,因为我不记得网站地址了:D
      

  6.   

    定制界面是VB的弱项,楼主改用VC或Delphi吧