home *** CD-ROM | disk | FTP | other *** search
/ Planet Source Code Jumbo …e CD Visual Basic 1 to 7 / 1_2002.ISO / Data / Zips / CODE_UPLOAD40293162000.psc / Form1.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  2000-03-15  |  10.5 KB  |  325 lines

  1. VERSION 5.00
  2. Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "COMDLG32.OCX"
  3. Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
  4. Object = "{3B7C8863-D78F-101B-B9B5-04021C009402}#1.2#0"; "RICHTX32.OCX"
  5. Begin VB.Form Form1 
  6.    Caption         =   "Source Documentor"
  7.    ClientHeight    =   6735
  8.    ClientLeft      =   165
  9.    ClientTop       =   450
  10.    ClientWidth     =   7290
  11.    Icon            =   "Form1.frx":0000
  12.    LinkTopic       =   "Form1"
  13.    ScaleHeight     =   6735
  14.    ScaleWidth      =   7290
  15.    StartUpPosition =   2  'CenterScreen
  16.    Begin RichTextLib.RichTextBox RichTextBox1 
  17.       Height          =   5535
  18.       Left            =   720
  19.       TabIndex        =   5
  20.       Top             =   600
  21.       Visible         =   0   'False
  22.       Width           =   6495
  23.       _ExtentX        =   11456
  24.       _ExtentY        =   9763
  25.       _Version        =   393217
  26.       BackColor       =   16777215
  27.       HideSelection   =   0   'False
  28.       ScrollBars      =   3
  29.       TextRTF         =   $"Form1.frx":08CA
  30.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  31.          Name            =   "MS Sans Serif"
  32.          Size            =   8.25
  33.          Charset         =   0
  34.          Weight          =   400
  35.          Underline       =   0   'False
  36.          Italic          =   0   'False
  37.          Strikethrough   =   0   'False
  38.       EndProperty
  39.    End
  40.    Begin MSComDlg.CommonDialog commdlg 
  41.       Left            =   1080
  42.       Top             =   4440
  43.       _ExtentX        =   847
  44.       _ExtentY        =   847
  45.       _Version        =   393216
  46.    End
  47.    Begin MSComctlLib.ImageList ImageList2 
  48.       Left            =   2400
  49.       Top             =   4080
  50.       _ExtentX        =   1005
  51.       _ExtentY        =   1005
  52.       BackColor       =   -2147483643
  53.       ImageWidth      =   16
  54.       ImageHeight     =   16
  55.       MaskColor       =   12632256
  56.       _Version        =   393216
  57.       BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628} 
  58.          NumListImages   =   4
  59.          BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  60.             Picture         =   "Form1.frx":0978
  61.             Key             =   "unread"
  62.          EndProperty
  63.          BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  64.             Picture         =   "Form1.frx":0AE0
  65.             Key             =   "writing"
  66.          EndProperty
  67.          BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  68.             Picture         =   "Form1.frx":0C3C
  69.             Key             =   "ok"
  70.          EndProperty
  71.          BeginProperty ListImage4 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  72.             Picture         =   "Form1.frx":0D98
  73.             Key             =   "error"
  74.          EndProperty
  75.       EndProperty
  76.    End
  77.    Begin MSComctlLib.ListView ListView1 
  78.       Height          =   3615
  79.       Left            =   0
  80.       TabIndex        =   2
  81.       Top             =   480
  82.       Width           =   3855
  83.       _ExtentX        =   6800
  84.       _ExtentY        =   6376
  85.       View            =   3
  86.       Sorted          =   -1  'True
  87.       LabelWrap       =   -1  'True
  88.       HideSelection   =   -1  'True
  89.       GridLines       =   -1  'True
  90.       _Version        =   393217
  91.       SmallIcons      =   "ImageList2"
  92.       ForeColor       =   -2147483640
  93.       BackColor       =   -2147483643
  94.       BorderStyle     =   1
  95.       Appearance      =   1
  96.       NumItems        =   1
  97.       BeginProperty ColumnHeader(1) {BDD1F052-858B-11D1-B16A-00C0F0283628} 
  98.          Text            =   "File Name"
  99.          Object.Width           =   2540
  100.       EndProperty
  101.    End
  102.    Begin MSComctlLib.ImageList ImageList1 
  103.       Left            =   0
  104.       Top             =   4080
  105.       _ExtentX        =   1005
  106.       _ExtentY        =   1005
  107.       BackColor       =   -2147483643
  108.       ImageWidth      =   16
  109.       ImageHeight     =   16
  110.       MaskColor       =   12632256
  111.       _Version        =   393216
  112.       BeginProperty Images {2C247F25-8591-11D1-B16A-00C0F0283628} 
  113.          NumListImages   =   3
  114.          BeginProperty ListImage1 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  115.             Picture         =   "Form1.frx":0EF4
  116.             Key             =   ""
  117.          EndProperty
  118.          BeginProperty ListImage2 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  119.             Picture         =   "Form1.frx":1050
  120.             Key             =   ""
  121.          EndProperty
  122.          BeginProperty ListImage3 {2C247F27-8591-11D1-B16A-00C0F0283628} 
  123.             Picture         =   "Form1.frx":11AC
  124.             Key             =   ""
  125.          EndProperty
  126.       EndProperty
  127.    End
  128.    Begin MSComctlLib.Toolbar Toolbar1 
  129.       Align           =   1  'Align Top
  130.       Height          =   360
  131.       Left            =   0
  132.       TabIndex        =   1
  133.       Top             =   0
  134.       Width           =   7290
  135.       _ExtentX        =   12859
  136.       _ExtentY        =   635
  137.       ButtonWidth     =   609
  138.       ButtonHeight    =   582
  139.       Appearance      =   1
  140.       Style           =   1
  141.       ImageList       =   "ImageList1"
  142.       _Version        =   393216
  143.       BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628} 
  144.          NumButtons      =   3
  145.          BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  146.             Object.ToolTipText     =   "New"
  147.             ImageIndex      =   1
  148.          EndProperty
  149.          BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  150.             Object.ToolTipText     =   "Open"
  151.             ImageIndex      =   2
  152.          EndProperty
  153.          BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628} 
  154.             Object.ToolTipText     =   "Document"
  155.             ImageIndex      =   3
  156.          EndProperty
  157.       EndProperty
  158.       BorderStyle     =   1
  159.       Begin VB.PictureBox Picture1 
  160.          BorderStyle     =   0  'None
  161.          Height          =   375
  162.          Left            =   1200
  163.          ScaleHeight     =   375
  164.          ScaleWidth      =   4575
  165.          TabIndex        =   3
  166.          Top             =   0
  167.          Width           =   4575
  168.          Begin MSComctlLib.ProgressBar ProgressBar1 
  169.             Height          =   255
  170.             Left            =   0
  171.             TabIndex        =   4
  172.             Top             =   25
  173.             Width           =   3975
  174.             _ExtentX        =   7011
  175.             _ExtentY        =   450
  176.             _Version        =   393216
  177.             Appearance      =   1
  178.          End
  179.       End
  180.    End
  181.    Begin MSComctlLib.StatusBar StatusBar1 
  182.       Align           =   2  'Align Bottom
  183.       Height          =   255
  184.       Left            =   0
  185.       TabIndex        =   0
  186.       Top             =   6480
  187.       Width           =   7290
  188.       _ExtentX        =   12859
  189.       _ExtentY        =   450
  190.       _Version        =   393216
  191.       BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628} 
  192.          NumPanels       =   2
  193.          BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  194.             Alignment       =   1
  195.             Bevel           =   2
  196.             Text            =   "Status:"
  197.             TextSave        =   "Status:"
  198.          EndProperty
  199.          BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  200.             AutoSize        =   1
  201.             Object.Width           =   9790
  202.             Text            =   "Idle"
  203.             TextSave        =   "Idle"
  204.          EndProperty
  205.       EndProperty
  206.    End
  207.    Begin VB.Menu mnuFile 
  208.       Caption         =   "File"
  209.       Begin VB.Menu mnuNew 
  210.          Caption         =   "New"
  211.       End
  212.       Begin VB.Menu mnuOpen 
  213.          Caption         =   "Open"
  214.       End
  215.       Begin VB.Menu mnuzz1 
  216.          Caption         =   "-"
  217.       End
  218.       Begin VB.Menu mnuExit 
  219.          Caption         =   "Exit"
  220.       End
  221.    End
  222.    Begin VB.Menu mnuDoc 
  223.       Caption         =   "Document"
  224.       Begin VB.Menu mnudo 
  225.          Caption         =   "Do it now"
  226.       End
  227.    End
  228. Attribute VB_Name = "Form1"
  229. Attribute VB_GlobalNameSpace = False
  230. Attribute VB_Creatable = False
  231. Attribute VB_PredeclaredId = True
  232. Attribute VB_Exposed = False
  233. Private Sub Form_Load()
  234. ListView1.ListItems.Clear
  235. sLastFile = ""
  236. ProjectName = ""
  237. ProjectVersion = ""
  238. Prodir = ""
  239. ProType = ""
  240. ProMinVer = ".0"
  241. 'RichTextBox1.SelColor = vbBlack
  242. 'RichTextBox1.SelColor = &H800000
  243. 'RichTextBox1.SelColor = &H8000&
  244. End Sub
  245. Private Sub Form_Resize()
  246. On Error Resume Next
  247. ListView1.Width = Me.Width - 120
  248. ListView1.Height = Me.Height - 1400
  249. Picture1.Width = Me.Width - Picture1.Left - 120
  250. ProgressBar1.Width = Picture1.Width - 75
  251. ListView1.ColumnHeaders(1).Width = ListView1.Width - 350
  252. End Sub
  253. Private Sub mnudo_Click()
  254. Dim sPath As String
  255. If ListView1.ListItems.Count > 0 Then
  256.     sPath = BrowseForFolder(Me.hWnd, "Select a Folder to Write to", "c:\")
  257.     If Len(sPath) > 0 Then
  258.     'do the conversion
  259.     DocDir = sPath & "\"
  260.         Select Case ProType
  261.         Case Is = ".vbp" 'visual basic
  262.         Call InitColorize ' for the html to rtf coloring
  263.         WriteVBHTMLFiles
  264.         Case Is = ".dpr" 'delphi
  265.         'comming soon?
  266.         Case Is = "dsw" 'visual c++
  267.         'comming soon?
  268. End Select
  269.     End If
  270. End If
  271. End Sub
  272. Private Sub mnuExit_Click()
  273. End Sub
  274. Private Sub mnuNew_Click()
  275. ListView1.ListItems.Clear
  276. sLastFile = ""
  277. ProjectName = ""
  278. ProjectVersion = ""
  279. Prodir = ""
  280. ProType = ""
  281. ProMinVer = ".0"
  282. End Sub
  283. Private Sub mnuOpen_Click()
  284. 'show the comdlg
  285. On Error GoTo cCan
  286. Dim sEXT As String
  287. commdlg.FileName = ""
  288. commdlg.Filter = "Visual Basic Project (*.vbp)|*.vbp|Delphi Project (*.dpr)|*.dpr|Visual C++ Project (*.dsw)|*.dsw"
  289. commdlg.FilterIndex = 1
  290. commdlg.Flags = cdlOFNFileMustExist + cdlOFNExplorer
  291. commdlg.DefaultExt = ".vbp"
  292. commdlg.CancelError = True
  293. 'commdlg.InitDir = App.Path
  294. commdlg.ShowOpen
  295. 'select case here
  296. sEXT = ParsePath(commdlg.FileName, 3)
  297. MousePointer = 11
  298. ProType = LCase(sEXT)
  299. Select Case ProType
  300. Case Is = ".vbp"
  301. ParseProjectFileVB commdlg.FileName
  302. MousePointer = 0
  303. Case Is = ".dpr"
  304. Case Is = "dsw"
  305. End Select
  306. 'DocDir = ParsePath(commdlg.FileName, 0) & ParsePath(commdlg.FileName, 1) & "Documentation\"
  307. Exit Sub
  308. cCan:
  309. If Err <> cdlCancel Then
  310. MsgBox Err.Description
  311. MousePointer = 0
  312. End If
  313. Exit Sub
  314. End Sub
  315. Private Sub Toolbar1_ButtonClick(ByVal Button As MSComctlLib.Button)
  316. Select Case Button.Index
  317. Case Is = 1 'new
  318. mnuNew_Click
  319. Case Is = 2 'open
  320. mnuOpen_Click
  321. Case Is = 3 'document
  322. mnudo_Click
  323. End Select
  324. End Sub
  325.