This example shows the use of the VbsDbGetScreenType method. Navigate through different VBSdb screens and look at the text displayed below the object.

Current screen type is: View

  LastName FirstName BirthDate
1 Davolio Nancy 12/8/1948
2 Fuller Andrew 2/19/1952
3 Leverling Janet 8/30/1963
4 Peacock Margaret 9/19/1937
5 Buchanan Steven 3/4/1955
EmployeeId 1
LastName Davolio
FirstName Nancy
Title Sales Representative
BirthDate 12/8/1948
 First   Prev   Next   Last   Search   Add   Update   Delete 
This is the code implementing the example:
<!--#include file="VBSdb/inc.asp"-->
<%
   VbsDbNew objVbsDb
   objVbsDb( "MdbPath" ) = "data/nwind.mdb"
   objVbsDb( "Sql" ) = "select EmployeeId,LastName,FirstName,Title,BirthDate from Employees"
   objVbsDb( "GridFields" ) = "LastName;FirstName;BirthDate"
   objVbsDb( "ViewNavigationButtons" ) = "first;next;prev;last;search;add;update;delete"
   objVbsDb( "EditTableName" ) = "Employees"
   objVbsDb( "EditKeyFields" ) = "EmployeeId"
   objVbsDb( "EditFields" ) = "LastName;FirstName;Birthdate"
   response.write "<p>Current screen type is a <b>" & VbsDbGetScreenType( objVbsDb ) & "</b>"
   VbsDb objVbsDb
   VbsDbClose objVbsDb
%>
This demonstrative program connects to Nwind.mdb, the well known Microsoft Access sample database: the names of companies, products, people, characters, and/or data mentioned herein are fictious and are in no way intended to represent any real individual, company, product, or event. To download a copy of Nwind.mdb, please visit Microsoft's site.