Question about Oracle 10g Database Standard (ODBSEONUPP0)

1 Answer

About visual basic coding

How to writ the code in visual basic to create database in Ms Access

Posted by on

1 Answer

  • Level 1:

    An expert who has achieved level 1.

    MVP:

    An expert that got 5 achievements.

    Scholar:

    An expert who has written 20 answers of more than 400 characters.

    Hot-Shot:

    An expert who has answered 20 questions.

  • Contributor
  • 40 Answers

Hello,
The standard way of creating a database using VBA, which can be modified to suit your needs is this--> Note: the code (wspDefault.CreateDatabase("Newdb.mdb"...), can be altered to save the database in a folder  such as "C:\NEWDB\text.mdb". sub NewDatabase()     Dim wspDefault As Workspace, dbs As Database     Dim tdf As TableDef, fld1 As Field, fld2 As Field     Dim idx As Index, fldIndex As Field     Set wspDefault = DBEngine.Workspaces(0)     ' Create new, encrypted database.     Set dbs = wspDefault.CreateDatabase("Newdb.mdb", _         dbLangGeneral, dbEncrypt)     ' Create new table with two fields.     Set tdf = dbs.CreateTableDef("Contacts")     Set fld1 = tdf.CreateField("ContactID", dbLong)     fld1.Attributes = fld1.Attributes + dbAutoIncrField     Set fld2 = tdf.CreateField("ContactName", dbText, 50)     ' Append fields.     tdf.Fields.Append fld1     tdf.Fields.Append fld2     ' Create primary key index.     Set idx = tdf.CreateIndex("PrimaryKey")     Set fldIndex = idx.CreateField("ContactID", dbLong)     ' Append index fields.     idx.Fields.Append fldIndex     ' Set Primary property.     idx.Primary = True     ' Append index.     tdf.Indexes.Append idx     ' Append TableDef object.     dbs.TableDefs.Append tdf     dbs.TableDefs.Refresh     Set dbs = Nothing End Sub
Hope this helps! Please let me know if you have any questions.Thank You,Raph30

Posted on Jan 24, 2009

1 Suggested Answer

6ya6ya
  • 2 Answers

SOURCE: I have freestanding Series 8 dishwasher. Lately during the filling cycle water hammer is occurring. How can this be resolved

Hi,
a 6ya expert can help you resolve that issue over the phone in a minute or two.
best thing about this new service is that you are never placed on hold and get to talk to real repairmen in the US.
the service is completely free and covers almost anything you can think of (from cars to computers, handyman, and even drones).
click here to download the app (for users in the US for now) and get all the help you need.
goodluck!

Posted on Jan 02, 2017

Add Your Answer

Uploading: 0%

my-video-file.mp4

Complete. Click "Add" to insert your video. Add

×

Loading...
Loading...

Related Questions:

4 Answers

HOW TO SOLVE VFP FILE CURRUPT WHEN POWER FAILURE


At times, you may view that your MS Visual FoxPro 9.0 database is behaving abnormally. Some of the abnormal symptoms could be an error message while opening any database table, invalid characters in place of pre-defined values, and and more. The main reason for abnormal behavior of the database is its corruption due some logical crash. Few common reasons for corruption of MS Visual FoxPro 9.0 database are abnormal termination, faulty network devices, simultaneous modifications, conflicting third-party software, and incompatible service packs.
To overcome such database corruption scenarios, the user can use an up-to-date backup and perform restoration. However, restoration fails in cases where the user either forgets to create a database or the database backup itself gets damaged. In such cases, the database users can use a third-party DBF File Repair application to repair his/her corrupted database.
To illustrate the above case, consider a real-time scenario wherein you execute a query to modify your MS Visual FoxPro 9.0 database. While the query was performing the modification, the system shutdown due to power failure. However, the next time you tried to mount the database, you encountered an error message that did not allow you to access the database records. Moreover, the same error message appears every time you try to access the database.
Cause:
The root cause for the error message is MS Visual FoxPro 9.0 database corruption due to improper system shutdown.
Resolution:
The database corruption error message can be surmounted by following the below steps:
Use a complete database backup and perform restoration. However, in case of database backup unavailability, you will need to search for a commercial DBF File Repair utility.
A third-party DBF Repair application uses effective repair techniques to repair logically damaged MS Visual FoxPro 9.0 database and restore it at a new and safe location. The original database during the repair process remains intact. The tool is easy-to-understand and allows even a non-technical person to perform repair.
DBF Recovery Software is a comprehensive solution to repair databases created in MS Visual FoxPro 9.0, MS Visual FoxPro 8.0, and MS Visual FoxPro 7.0. The tool also repairs databases built in dBase III, dBase IV, and dBase V. Supported by Windows 7, Vista, 2003, XP, and 2000, the DBF Repair tool creates a new repaired file that can be attached to existing database.
Tanvi Sharma is a self employed Internet entrepreneur and product reviewer. This DBF Repair utility is extremely useful when the dBase and Foxpro database gets corrupted due to internal program errors, hardware malfunctioning, accidental deletion of data and more. This DBF Repair software repairs all types of database components including table name, column name, column data type, indexes and primary keys.

May 31, 2010 | Microsoft Visual FoxPro Professional...

1 Answer

I want to programaticaly modify an SQL statement in VB6


If I remember correctly you need to call ExecuteQuery or something similar otherwise it does not update the database.


Regards
GeWiz.

Jun 16, 2009 | Microsoft Visual Basic Enterprise Edition...

1 Answer

How to access data from ms access with buffer in class code with vb application


Use ADO and create a connection string for a Jet file (version matters here when creating the string). Then use ADO commands and return recordsets to buffer your data.

Mar 26, 2009 | Microsoft Visual Basic 6.0 for PC

1 Answer

What is the compatible database for visual basic 6.0?


Microsoft Access uses the Jet Engine. In VB 6, you can create a data connection using ODBC or OLE DB. Here is an example of OLE DB:

"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\YourAccessDB.mdb;User Id=;Password=;" Good luck

Mar 09, 2009 | Microsoft Press MS Access 2000 and Visual...

1 Answer

How do copy a table from an access database in one folder to another access database in another folder through visual basic code


Simple method Open both tables (or create second) and copy each record from source to target through 'do while not eof' or 'for each' syntax.

Second solution create link in target DB for first table, and use SELECT INTO statment in SQL.

Mar 02, 2009 | Microsoft Visual Basic 6.0 for PC

1 Answer

Write into excel format


Your code does not save in access format it just makes a copy of existing file. You need to open table by table and export data using csv format.
It can be done using access OLE to export, or
write some VB code to access the database tables via ODBC and save row data to csv file

Feb 17, 2009 | Microsoft Visual Basic Professional...

1 Answer

Write into excel format


You can use ADO or SQL to open the excel file directly (provided it is constructed correctly, ie fields names) and write the data to it without Access.
That might be eaiser thatn converting it from Access to Excel, if that can even be done.

Feb 17, 2009 | Microsoft Visual Basic 6.0 for PC

1 Answer

How to create a program using ms access?


you need to study the basics of database programming. take short courses for database programming.

Dec 04, 2008 | Microsoft Access 2002 for PC

1 Answer

Coding in ms word by using visual basic editor


Hello Kavita! If you want to get the most of VB then i advice that you install Microsoft visual studio...But just in case you want it for free you can find it here..
http://www.brothersoft.com/downloads/vb6.html

Nov 10, 2007 | Oracle 10g Database Standard (ODBSEONUPP0)

Not finding what you are looking for?
Oracle 10g Database Standard (ODBSEONUPP0) Logo

Related Topics:

232 people viewed this question

Ask a Question

Usually answered in minutes!

Top Oracle Computers & Internet Experts

robertmoore1

Level 2 Expert

179 Answers

Fred Block
Fred Block

Level 2 Expert

289 Answers

Tom Chichester

Level 3 Expert

28117 Answers

Are you an Oracle Computer and Internet Expert? Answer questions, earn points and help others

Answer questions

Manuals & User Guides

Loading...