home *** CD-ROM | disk | FTP | other *** search
/ Windows Game Programming for Dummies (2nd Edition) / WinGamProgFD.iso / pc / DirectX SDK / DXSDK / samples / Multimedia / DirectShow_WinXP / VideoControl / VisualBasic / Globals.bas < prev    next >
Encoding:
BASIC Source File  |  2001-10-08  |  1.4 KB  |  33 lines

  1. Attribute VB_Name = "Globals"
  2. '*******************************************************************************
  3. '*       This is a part of the Microsoft Platform SDK Code Samples.
  4. '*       Copyright (C) 1999-2001 Microsoft Corporation.
  5. '*       All rights reserved.
  6. '*       This source code is only intended as a supplement to
  7. '*       Microsoft Development Tools and/or SDK documentation.
  8. '*******************************************************************************
  9.  
  10. 'Microsoft Video Control - Sample Visual Basic Application
  11. Option Explicit
  12.  
  13. Public Const NTSC_GUID As String = "{8A674B4D-1F63-11D3-B64C-00C04F79498E}"
  14. Public Const ATSC_GUID As String = "{A2E30750-6C3D-11D3-B653-00C04F79498E}"
  15. Public Const DVBS_GUID As String = "{B64016F3-C9A2-4066-96F0-BD9563314726}"
  16. Public Const CC_GUID As String = "{7F9CB14D-48E4-43B6-9346-1AEBC39C64D3}"
  17. Public Const DATASVC_GUID As String = "{334125C0-77E5-11D3-B653-00C04F79498E}"
  18.  
  19. Sub Main()
  20.     frmMain.Show
  21. End Sub
  22.  
  23. 'Use this for error reporting
  24. Public Function CheckError(ErrorMsg As String)
  25.     Dim Msg As Variant
  26.     If Err.Number <> 0 Then
  27.         Msg = ErrorMsg & vbCrLf & vbCrLf & "The error returned was:" & vbCrLf & Hex(Err.Number) & ": " & Err.Description
  28.         MsgBox Msg, , "Error"
  29.     End If
  30.     'Reset the error so we don't get the same message over and over
  31.     Err.Number = 0
  32. End Function
  33.