Creating An Adapter

An adapter is a tool used for mapping ASPForm Elements to a datasource. At this time there is only one adapter in the ASPForms component, however the design allows for seamless implementation of new types of adapters as they become available.

Example 2.12. Using CreateAdapter

	'create a new ADO adapter named 'sample'
    Set adaptADO = hASPForm.CreateAdapter("sample", ASPFORMS_ADO)
    
    'set the tablename where the data
    adaptADO.TableName = "sqlTableName"

NOTE: while it passes back a handle to the adapter, the adapter still exists within the adapters collection