Database
  Home arrow Database arrow Page 6 - Using ADO Record to Create and Navigate In...
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
ASP Web Hosting  
ASP.NET Web Hosting 
Dedicated Servers 
Download TestComplete 
Windows Web Hosting
 
IBM® developerWorks 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
DATABASE

Using ADO Record to Create and Navigate Intranet Files and Folders
By: Jayaram Krishnaswamy
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 3 stars3 stars3 stars3 stars3 stars / 2
    2006-10-04

    Table of Contents:
  • Using ADO Record to Create and Navigate Intranet Files and Folders
  • Creating folders
  • Creating files
  • Adding files to folders
  • Navigating the files and folders
  • Copying files from one folder to another

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
     
    ADVERTISEMENT

    TestComplete™ automates software testing for a fraction of what the big guys charge. Easy functional and load testing for all Windows, .NET, Java and Web apps. Download a free trial now.

    Using ADO Record to Create and Navigate Intranet Files and Folders - Copying files from one folder to another
    (Page 6 of 6 )

    Although only copying is shown in the next code listing, it is also possible to move and delete (at your own risk) files and folders as well. Copying requires defining source and destination as well as what needs copying, as shown in the pop-up help.

    Option Compare Database
    Private rec As ADODB.Record
    Private rec2 As ADODB.Record
    Private Sub Command0_Click()
    Set rec = New ADODB.Record
    'open the file location
    rec.Open "", "URL=http://hodentek/DevHome/ASPFree/"
    MsgBox ("Rec is open" & rec.State)
    'copy from ASPFree folder to DevShed folder with the overwrite flag.
    rec.CopyRecord "http://hodentek/DevHome/AspFree", _
    "http://hodentek/DevHome/DevShed", , , adCopyOverWrite
    rec.Close
    End Sub
    

    The result of this copying is shown in the next picture.

    Summary

    ADO is a powerful tool and should be in your arsenal if you are working with the VB 6 environment. The Record object confers considerable power to ADO. Great caution must be exercised while moving or deleting folders in the web site as there may be other dependencies to be considered such as links. Pay careful attention to the Options argument in the syntax for all objects. When an XLS file is created, as shown in the tutorial, you could open the file with the Excel application. Also for the XLS file-type, overwriting may result in an error as the Excel program by default may not allow overwriting, and care should be exercised.


    DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.

       · This is very important if you are planning to make changes to your web site. I can...
     

    DATABASE ARTICLES

    - Database Programming in C# with MySQL : Usin...
    - Formatting Techniques for Data Access from E...
    - Data Access from Excel VBA
    - Generating a Multiple Table Crystal Report u...
    - ADO and the Command Object
    - On Wiring Up an ADO Data Control
    - Reading and Writing to Files on the Intranet
    - Using ADO Record to Create and Navigate Intr...
    - Using Data Access Pages to Access Data on a ...
    - Using ADO with the SQL Native Client
    - ADO`s Stream Object
    - Opening a Record Object Referencing an Open ...
    - Introducing Jasper (SQL Anywhere 10 Beta)
    - Creating a Database Project in VS 2005
    - Manipulating ADO Recordsets

     
    Accelerating Trading Partner Performance
     
    Competing on Analytics
     
    Cost Effective Scaling with Virtualization and Coyote Point Systems
     
    Five Checkpoints to Implementing IP Telephony
     
    Hosted Email Security: Staying Ahead of New Threats
     




    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway