For these tutorials, all information will be given regarding Visual Studio 6. The
run-time code should be backward compatible with Visual Basic 5 (except for hierarchical
binding). For hierarchical data-binding, you need to be using Visual Studio 6.x, or at
least the Data Access SDK 2.0 which installs the ADO Data Control (ADC DC) and the MDAC
components. Currently Visual Basic 5.0 does not have support for design-time data binding
with ADO Data-Bound controls. If you wish to bind to TreeViewX 3.0, you will need to do
this at run-time.
The following Visual Basic tutorials are offered:
- Start VB 6
- Create a new "Standard EXE" project
- Add the ADO DC and TreeViewX to your Project and place them on your form.
- Right-click on the ADO DC and select "Properties"
- On the "General" Property page, select "Use ODBC Data Source Name"
- Select your "Jet NorthWind connection" -- You may need to set this up through
the ODBC 32-bit Administrator through your Control Panel beforehand (or select New)
- On the "RecordSource" Property page, select "adCmdTable" from the
"Command Type" combobox
- Select the "Customers" table from the "Table or Stored Procedure
Name" combobox
- Click OK
- Select TreeViewX on the form
- In the "Standard Properties Window" in VB, change the DataSource property to
the ADO DC
- Right-click on TreeViewX and select "Properties..."
- On the Data-Binding Property Page, double-click on "CompanyName" in the
Available Columns list.
- Click on OK to close the Property Pages
- Run your application.
This only shows a basic table. For a hierarchical view, please refer to the sample in
VC 6 using the ADO DC.
- Start VB 6
- Create a new "Standard EXE" project
- Add the ADO DC and TreeViewX to your Project and place them on your form.
- Right-click on the ADO DC and select "Properties"
- On the "General" Property page, select "Use ODBC Data Source Name"
- Select your "Jet NorthWind connection" -- You may need to set this up through
the ODBC 32-bit Administrator through your Control Panel beforehand (or select New)
- On the "RecordSource" Property page, select "adCmdTable" from the
"Command Type" combobox
- Select the "Customers" table from the "Table or Stored Procedure
Name" combobox
- Click OK
- Double click on the background of the form to edit the code for the Form Load sub
- Add the following lines of code:
PVTreeViewX1.DataField(0) = "CompanyName"
PVTreeViewX1.DataSource = Adodc1
- Run your application
Note: Before attempting to bind TreeView hierarchically, please be sure that you
understand the purpose of the DataField property and how to use it.
One of the new features of Visual Basic 6.0 is the DataView which allows you to easily
set up a hierarchical recordset at design-time. Here’s how to use hierarchical
recordsets with TreeViewX:
Here, we will show how to bind three levels deep.
- Start VB 6
- Create a new "Standard EXE" project
- Add TreeViewX to your Project and place it on your form
- On the Toolbar in VB 6, you should have an icon for the DataView Window which looks
like:
, click on it. This will bring up the
DataView Window.
- On the DataView Window, click on the second toolbar button, "Add a Data Environment
to the Current Project". Click on it...
- In the DataEnvironment Window, click on Connection1, and in the Standard Properties
Window, change the "(Name)" field from "Connection1" to
"NWind"
- Back in the DataEnvironment Window, Connection1 should now be NWind. Right-click on it,
and select "Properties..."
- Select "Microsoft OLE DB Provider for ODBC Drivers", and click on Next
- Select your NorthWind Jet DataBase under the Data Source Name combobox. You may need to
set this up through your 32-bit ODBC Administrator in your Control Panel.
- Click on "Test Connection". You should get message box that says "Test
connection succeeded"
- Click on OK, click on OK.
- In the DataView Window, NWind should now be listed under "Data Environment
Connections" with a plus sign. Click on the plus sign to expand it.
- Click on the plus sign next to "Tables" to expand it
- Drag "Customers" from the DataView Window to the DataEnvironment Window.
- Repeat step 14 for "Orders" and "Order Details"
- In the DataEnvironment Window, right-click on Orders, and select
"Properties..."
- Click on the Relation tab, and check "Relate to a Parent Command Object"
- In the Parent Command combobox, select "Customers"
- In the Relation Definition section on that property page, you should now have CustomerID
in both comboboxes, if so click on Add. If not, select CustomerID in both comboboxes then
click on Add
- Click on OK
- Right-click on "Order_Details" in the DataEnvironment Window and select
"Properties..."
- Click on the Relation tab, and check "Relate to a Parent Command Object"
- In the Parent Command combobox, select "Orders"
- In the Relation Definition section on that property page, you should now have OrderID in
both comboboxes, if so click on Add. If not, select OrderID in both comboboxes then click
on Add
- Click OK
- Close the DataView Window
- Your DataEnvironment Window should now contain a hierarchical representation of three
tables from the NorthWind Database. Close the DataEnvironment Window
- Select TreeViewX on the form.
- In the Standard Properties Window in VB, change the DataSource property to
"DataEnvironment1"
- Change the DataMember property to "Customers"
- Right-click on TreeViewX and select "Properties"
- On the Data-Binding Property page, expand "Customers", scroll down and expand
"Orders", scroll down and expand "Order_Details"
- Scroll back up and double-click on "CompanyName" which should be a child of
"Customers".
- Scroll down and double-click on "OrderID" which should be a child of
"Orders"
- Scroll down and double-click on "ProductID" which should be a child of
"Order_Details"
- Click on OK to close the Property Pages
- Run your project
When you run your project, you will get a list of company names. Under each company is
all the orders associated with that company. Under each Order is all the products for that
order.
- Start VB 6
- Create a new "Standard EXE" project
- Add TreeViewX to your Project and place it on your form
- On the Toolbar in VB 6, you should have an icon for the DataView Window which looks
like:
, click on it. This will bring up the
DataView Window.
- On the DataView Window, click on the second toolbar button, "Add a Data Environment
to the Current Project". Click on it...
- In the DataEnvironment Window, click on Connection1, and in the Standard Properties
Window, change the "(Name)" field from "Connection1" to
"NWind"
- Back in the DataEnvironment Window, Connection1 should now be NWind. Right-click on it,
and select "Properties..."
- Select "Microsoft OLE DB Provider for ODBC Drivers", and click on Next
- Select your NorthWind Jet DataBase under the Data Source Name combobox. You may need to
set this up through your 32-bit ODBC Administrator in your Control Panel.
- Click on "Test Connection". You should get message box that says "Test
connection succeeded"
- Click on OK, click on OK.
- In the DataView Window, NWind should now be listed under "Data Environment
Connections" with a plus sign. Click on the plus sign to expand it.
- Click on the plus sign next to "Tables" to expand it
- Drag "Customers" from the DataView Window to the DataEnvironment Window.
- Repeat step 14 for "Orders" and "Order Details"
- In the DataEnvironment Window, right-click on Orders, and select
"Properties..."
- Click on the Relation tab, and check "Relate to a Parent Command Object"
- In the Parent Command combobox, select "Customers"
- In the Relation Definition section on that property page, you should now have CustomerID
in both comboboxes, if so click on Add. If not, select CustomerID in both comboboxes then
click on Add
- Click on OK
- Right-click on "Order_Details" in the DataEnvironment Window and select
"Properties..."
- Click on the Relation tab, and check "Relate to a Parent Command Object"
- In the Parent Command combobox, select "Orders"
- In the Relation Definition section on that property page, you should now have OrderID in
both comboboxes, if so click on Add. If not, select OrderID in both comboboxes then click
on Add
- Click OK
- Close the DataView Window
- Your DataEnvironment Window should now contain a hierarchical representation of three
tables from the NorthWind Database. Close the DataEnvironment Window
- Add the following code to the Form Load:
PVTreeViewX1.DataField(0) = "Customers.CompanyName"
PVTreeViewX1.DataField(1) = "Orders.OrderID"
PVTreeViewX1.DataField(2) = "Order_Details.ProductID"
PVTreeViewX1.DataMember = "Customers"
PVTreeViewX1.DataSource = DataEnvironment1
- Run your project
NOTE: When binding to a single level, you only need to specify the Field Name in
DataField(0). If you are binding to multiple level as this example shows, you need to
specify the [Table Name].[Field Name] as shown.
The DataMember property specifies which level TreeViewX should begin access to. If, for
instance, you don’t want to see the Customer’s information, just
Orders and Order Details, then specify the DataMember to be "Orders" and
TreeViewX will only have access to Orders and Order_Details.
The following Visual C++ tutorials are offered:
(Note: At the time of this release, design-time data binding in Visual C++ 6.0 is
disabled. All data-binding should be done at run-time)
- Run Microsoft VC++ 6.0
- Select File | New
- On the Projects tab, select "MFC AppWizard (exe)"
- Enter the location for the project
- For this sample, we will use the name "vcsamp" for the Project name.
- Make sure "Create new workspace" is selected, and Platforms is
"Win32"
- Click on OK
- Select "Dialog Based"
- Click Finish, click OK
- From the main menu, select Project | Add to Project | Components and Controls
- Double-click the folder "Registered ActiveX Controls"
- Scroll over to "Microsoft ADO Data Control ..." and double-click on it.
- Click on OK to insert the component
- Click on OK to generate the classes
- Repeat steps 12-14 for "ProtoView TreeViewX v3.0"
- Click on Close to close the Components and Controls Gallery
- Delete the "TODO:" static field from the dialog
- Place a TreeViewX control on your dialog, and the ADO DC
- Right-click on the ADO DC and select "Properties"
- On the Control tab, select "Use ODBC Data Source Name"
- Select your "Jet NorthWind connection" -- You may need to set this up through
the ODBC 32-bit Administrator through your Control Panel beforehand (or select New)
- On the "RecordSource" Property page, select "adCmdTable" from the
"Command Type" combobox
- Select the "Customers" table from the "Table or Stored Procedure
Name" combobox
- Close the properties window
- Right-click on TreeViewX and select "Properties"
- Click on the right-arrow to move to the All property page and view the All property page
- Change the DataSource property to IDC_ADODC1
- Move the the Data-Binding property page
- Double-click on "CompanyName"
- Close the property window
- Build and run your application
- Start Microsoft Visual C++
- Select File | New from the main menu
- On the Projects tab, select "MFC AppWizard (exe)"
- Enter a location and name for the project. In this sample, we will use vcsamp again
- Click OK
- Select "Dialog Based", then click Finish
- Click OK
- From the main menu, select Project | Add to Project | Components and Controls
- Double-click on the Registered AcitveX Controls
- Scroll over to "Microsoft ADO Data Control" and double-click on it
- Click OK to insert the component, click OK to generate the classes
- Repeat steps 10 & 11 for "ProtoView TreeViewX v3.0"
- Click on Close to close the Components and Control Gallery
- Delete the TODO static field on the dialog, then place TreeViewX and an ADO DC on the
dialog
- Right-click on the ADO DC and select Properties
- On the Control tab, select Use ODBC Data Source Name, and select your NorthWind Jet Data
Source. You may need to set this up through your 32-bit ODBC Administrator in Control
Panel beforehand.
- On the RecordSource tab, select adCmdTable under the Command Type combobox
- Select "Customers" in the Table or Stored Procedure Name combobox
- Close the Properties dialog
- Press Ctrl-W to enter ClassWizard (or select it from the View menu)
- On the Member Variables tab, double-click on IDC_ADODC1.
- Give this control the name m_adodc. Make sure the Category is Control and Variable type
is Cadodc, then click OK
- Double-click on IDC_PVTREEVIEWXCTRL1
- Give this control the name m_treeview. Make sure the Category is Control and Variable
type is CPVTreeView3, then click OK.
- On the Message Maps tab, you should have OnInitDialog listed under the Member functions.
Double-click on it to edit the code
- Look for "// TODO: Add extra initialization here" in the function and add the
following lines of code after the todo line, but before "return TRUE":
m_adodc.Refresh();
m_treeview.SetDataField(0, "CompanyName");
m_treeview..SetDataSource(m_adodc.GetRecordset().GetDataSource());
At the top of the file, add:
#include "_recordset.h"
- Build and run your application.
This sample will show how to bind TreeViewX without the use of a data control at
run-time.
- Start Microsoft Visual C++
- Select File | New from the main menu
- On the Projects tab, select "MFC AppWizard (exe)"
- Enter a location and name for the project. In this sample, we will use vcsamp again
- Click OK
- Select "Dialog Based", then click Finish
- Click OK
- From the main menu, select Project | Add to Project | Components and Controls
- Double-click on the Registered AcitveX Controls
- Scroll over to "ProtoView TreeViewX v3.0" and double-click on it
- Click OK to insert the component, click OK to generate the classes
- Click on Close to close the Components and Control Gallery
- Delete the TODO static field on the dialog, then place a TreeViewX on the dialog
- Press Ctrl-W to enter ClassWizard (or select it from the View menu)
- On the Member Variables tab, double-click on IDC_PVTREEVIEWXCTRL1
- Give this control the name m_treeview. Make sure the Category is Control and Variable
type is CPVTreeView3, then click OK.
- On the Class Info tab, click on Add Class and select From a type library...
- Locate msado15.dll (typically in the /Program Files/Common Files/System/ado directory),
and double-click on it.
- Select all the classes, and click on OK to generate the files
- On the Message Maps tab, select "CvcsampDlg" under Object Ids listbox.
- In the Message listbox, double-click on WM_CLOSE. This will add the member function to
your application.
- On the Message Maps tab, you should have OnInitDialog listed under the Member functions.
Double-click on it to edit the code
- Look for "// TODO: Add extra initialization here" in the function and add the
following lines of code after this line, but before "return TRUE":
// Your DSN=...; may be different. Please refer to your 32-bit ODBC Administrator // in
Control Panel to get the correct name.
COleVariant Connect( "DSN=OLE_DB_NWind_Jet;UID=;PWD=;" );
COleVariant Source ( "SELECT * FROM Customers" );
Rs1.CreateDispatch( "ADODB.Recordset.2.0", &e );
Rs1.Open( (VARIANT) Source, (VARIANT) Connect, 0, 1, -1 );
m_datatbl.SetAllowDBAutoConfig(TRUE);
m_datatbl.SetDataSource(Rs1.GetDataSource());
- Locate the function void CVcsampDlg::OnClose() in the .cpp file.
- Right after the TODO marker and before the CDialog::OnClose(), add the following two
lines before the "CDialog::OnClose" line:
Rs1.Close();
Rs1.ReleaseDispatch();
- Open the header file for this dialog, vcsampDlg.h
- Locate the following thress lines:
//{{AFX_INCLUDES()
#include "pvtreeview3.h"
//}}AFX_INCLUDES
- Add the following line after it:
#include "msado15.h"
- Locate the constructor, and directly after it, add the following two lines:
_Recordset Rs1;
COleException e;
- Save and close the header file
- Build and run your application
This sample will show TreeViewX being bound at design-time to the ADO DC hierarchically
(Note: At the time of this release, design-time data binding in Visual C++ 6.0 is
disabled. All data-binding should be done at run-time)
- Run Microsoft VC++ 6.0
- Select File | New
- On the Projects tab, select "MFC AppWizard (exe)"
- Enter the location for the project
- For this sample, we will use the name "vcsamp" for the Project name.
- Make sure "Create new workspace" is selected, and Platforms is
"Win32"
- Click on OK
- Select "Dialog Based"
- Click Finish, click OK
- From the main menu, select Project | Add to Project | Components and Controls
- Double-click the folder "Registered ActiveX Controls"
- Scroll over to "Microsoft ADO Data Control ..." and double-click on it.
- Click on OK to insert the component
- Click on OK to generate the classes
- Repeat steps 12-14 for "ProtoView TreeViewX v3.0"
- Click on Close to close the Components and Controls Gallery
- Delete the "TODO:" static field from the dialog
- Place a TreeViewX control and the ADO DC on your dialog.
- Right-click on the ADO DC and select "Properties"
- On the Control tab, select Use Connection String, and click on Build
- Click on MSDataShape, then click on Next
- On the Connection tab, enter the Data Source name for the NorthWind Jet Database in the
Data Source field.
- Click on Test Connection. If it succeeds, click on OK and go to the next step. If it
fails, then check your setting on this page. The only field that should be filled in it
the Data Source field. The Data Source name you specify should match the name in your
32-bit ODBC Administrator.
- Right-click on the ADO DC again and select Properties to bring up the Properties dialog
- On the RecordSource tab, select adCmdText in the Command Type combobox
- In the CommandText (SQL) Edit field, enter in the following command:
SHAPE {select * from Customers} APPEND ({select * from Orders} AS chapter RELATE
CustomerID TO CustomerID)
NOTE: For information on this command, please refer to the Microsoft help files.
- Close the Properties Dialog
- Right-click on TreeViewX, and select Properties
- On the All Property page, set the Data Source property to IDC_ADODC1
- Close the Properties Dialog
- Build and run your application
- Start Microsoft Visual C++
- Select File | New from the main menu
- On the Projects tab, select "MFC AppWizard (exe)"
- Enter a location and name for the project. In this sample, we will use vcsamp again
- Click OK
- Select "Dialog Based", then click Finish
- Click OK
- From the main menu, select Project | Add to Project | Components and Controls
- Double-click on the Registered AcitveX Controls
- Scroll over to "ProtoView TreeViewX v3.0" and double-click on it
- Click OK to insert the component, click OK to generate the classes
- Click on Close to close the Components and Control Gallery
- Delete the TODO static field on the dialog, then place a TreeViewX on the dialog
- Press Ctrl-W to enter ClassWizard (or select it from the View menu)
- On the Member Variables tab, double-click on IDC_PVTREEVIEWXCTRL1
- Give this control the name m_treeview. Make sure the Category is Control and Variable
type is CPVTreeView3, then click on OK.
- On the Class Info tab, click on Add Class and select From a type library...
- Locate msado15.dll (typically in the /Program Files/Common Files/ado directory), and
double-click on it.
- Select all the classes, and click on OK to generate the files
- On the Message Maps tab, select "CvcsampDlg" under Object Ids listbox.
- In the Messages listbox, double-click on WM_CLOSE. This will add the member function to
your application.
- On the Message Maps tab, you should have OnInitDialog listed under the Member functions.
Double-click on it to edit the code
- Look for "// TODO: Add extra initialization here" in the function and add the
following lines of code after this line, but before "return TRUE":
// Your DSN=...; may be different. Please refer to your 32-bit ODBC Administrator
// in Control Panel to get the correct name.
COleVariant Connect( "Provider=MSDataShape;DSN=OLE_DB_NWind_Jet;UID=;PWD=;" ); COleVariant
Source ( "SHAPE {select * from Customers} APPEND ({select * from Orders} AS chapter
RELATE CustomerID TO CustomerID)" );
Rs1.CreateDispatch( "ADODB.Recordset.2.0", &e );
Rs1.Open( (VARIANT) Source, (VARIANT) Connect, 0, 1, -1 );
m_treeview.SetDataField(0, "Customers.CompanyName");
m_treeview.SetDataField(1, "Orders.OrderID");
m_treeview.SetDataSource(Rs1.GetDataSource());
(Move this into its own sample)
For Visual Basic, the code is as follows:
Dim con As New ADODB.Connection
Dim rs1 As New ADODB.Recordset
con.Open "Provider=MSDataShape;DSN=OLE_DB_NWind_Jet;UID=;PWD=;"
rs1.Open "SHAPE {select * from Customers} APPEND ({select * from Orders} AS Orders
RELATE CustomerID TO CustomerID)",
"Provider=MSDataShape;DSN=OLE_DB_NWind_Jet;UID=;PWD=;"
PVTreeViewX1.DataField(0) = "Customers.CompanyName"
PVTreeViewX1.DataField(1) = "Orders.OrderID"
Set PVTreeViewX1.DataSource = rs1
- Locate the function void CVcsampDlg::OnClose() in the .cpp file.
- Right after the TODO marker and before the CDialog::OnClose(), add the following two
lines:
Rs1.Close();
Rs1.ReleaseDispatch();
- Open the header file for this dialog, vcsampDlg.h
- Locate the following thress lines:
//{{AFX_INCLUDES()
#include "pvtreeview3.h"
//}}AFX_INCLUDES
- Add the following line after it:
#include "msado15.h"
- Locate the constructor, and directly after it, add the following two lines:
_Recordset Rs1;
COleException e;
- Save and close the header file
- Build and run your application
The samples above should give you a good idea on how to do some fairly complex
data-binding. The previous tutorials should capture just about every aspect of
data-binding. The following tutorials will show how to accomplish data-binding in Java
(Visual J++) and several example of data-binding for Internet Development including RDS
and ADO.
The following Visual J++ tutorials are offered:
- Run Microsoft Visual J++ 6.0
- If the "New Project" dialog box does not come up, choose File | New Project
- Select the Visual J++ Projects | Applications in the TreeView.
- Select Appliciation Wizard in the ListView.
- Enter a location and name. For this sample we will use jsamp.
- Click on Open
- Click on Next
- Select Form Based Application with Data, and click on Next
- Select ODBC and click on Next
- Select your NorthWind Jet DSN and click on Next
- Select Single record under Form layout, and click on Code, then click on Next
- Select Customers under the Record source combobox
- Move all fields to the right listbox
- Click on Finish
- On the Toolbox, right-click on the background and select "Customize
toolbox..."
- On the ActiveX Controls tab, include ProtoView TreeViewX v3.0 and click on OK
- Select TreeViewX from the tools palette and place it on your dialog (after you make room
for it)
- Right-click on the background of the dialog, and select View Code
- Search for the function "void openDataConnection()"
- Add the following lines as the last lines in the function:
PVTreeViewX1.setDataField(0, new String("CompanyName"));
PVTreeViewX1.setDataSource((msdatsrc.DataSource) m_rs.getDataSource());
The typecasting is necessary here. Hopefully, as Visual J++ progresses to the point of
Visual C++ or Visual Basic, this won’t be necessary.
- Build and run your project
As you’ll notice in this function, all the code is spelled out here on
creating a recordset. You can simply modify this to make it hierarchical using the samples
above.
Design-time data-binding is not available as of yet, so there are no samples for it in
Java.
The following HTML and ASP tutorials are offered:
This sample assumes you already have the AdvWorks sample installed an running correctly
on your IIS Server. If you do not have this sample, you can obtain it from http://www.microsoft.com/data/rds.
- Start Microsoft Visual InterDev 6.0 and either open up an existing Web Project
containing the AdvWorks sample, or create a new Web Project using the AdvWorks Web. For
information on how to do this, please refer to Microsoft’s InterDev help files.
- From the Project Explorer Window, right-click on <myserver>/<myWebProject>
and select Add | Active Server Page...
- Select the Existing tab
- Move the the PVApps/TreeViewX/Samples/HTML/RDS directory (or
PVApps/ActiveXSuite3/Samples/HTML/RDS
- Select the RDSTEMPLATE.ASP file and click on Open.
This will add the page to your Web Project
- In the Project Explorer, double-click on RDSTEMPLE.ASP to open it.
You will get a message box saying that an object failed to load and will be open as text.
This is okay. It is the RDS Data Control. The RDS Data Control is not really a control,
rather it is installed on the client side as part of Internet Explorer 4.x.
- If you do not already have TreeViewX on your Tools palette, right-click on the Tools
Palette and choose Customize Toolbox. On the ActiveX Controls tab, check ProtoView
TreeViewX v3.0 and click OK
- You should see a line with the following text:
<!-- Insert ActiveX Controls here -->
Drag TreeViewX from the Tools Palette and position it after this line. Because of the
Design-time limitations of Visual InterDev, we will need to modify the Object Tag for
TreeViewX to set the DataSource property. Right-click on TreeViewX and select "Always
View As Text". The first line should appear as follows:
<OBJECT classid="clsid:DB625B9A-05EA-11D2-97DD-00400520799C" id=PVTreeViewX1
style="LEFT: 0px; TOP: 0px" VIEWASTEXT>
- Scroll to the last line of the OBJECT tag, add this following paramater as the last one
(don’t forget to move the </OBJECT> to appear after the parameter you
add):
<PARAM NAME=DataSource datasrc=#adc>
<OBJECT classid="clsid:DB625B9A-05EA-11D2-97DD-00400520799C" id=PVTreeViewX1
style="LEFT: 0px; TOP: 0px" VIEWASTEXT>
<PARAM NAME="_Version" VALUE="196608">
<PARAM NAME="_ExtentX" VALUE="5291">
<PARAM NAME="_ExtentY" VALUE="4762">
...
<PARAM NAME="DataField16" VALUE="">
<PARAM NAME="DataField17" VALUE="">
<PARAM NAME="DataField18" VALUE="">
<PARAM NAME="DataField19" VALUE="">
<PARAM NAME=DataSource datasrc=#adc></object>
One of the PARAMs should be DataField0, in this sample, we will set the field for
simplicity. Modify the line that reads:
<PARAM NAME="DataField0" VALUE="">
To read:
<PARAM NAME="DataField0" VALUE="ProductCode">
NOTE: If you want to set the DataField0 at run-time, you could do that in the OnLoad
routine as follows:
...
Server.Value =
"http://<%=Request.ServerVariables("SERVER_NAME")%>"
Connect.Value = "DSN=AdvWorks"
SQL.Value = "Select * from Products"
PVTreeViewX1.DataField(0) = "ProductCode"
...
- Save the file (it should update your Web on the server) and view it in your browser.
When the page comes up, click on Run.