Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Connecting to DB off the Internet

Posted on 1998-12-03
5
143 Views
Last Modified: 2010-05-03
I am trying to load a data control with a database off a server from the internet, rather than a local hard drive.  Does anyone know how to do this using the iNet transfer control (or any other way)?
0
Comment
Question by:EvanL
  • 2
  • 2
5 Comments
 
LVL 14

Expert Comment

by:waty
ID: 1447995
I have see an article in a magazine for doing that. I will try to retrieve this magazine and read the article.
0
 
LVL 1

Expert Comment

by:lbk
ID: 1447996
I'm not 100% sure this is what you need, but lets give it a shot. Use RDS (Remote Data Service) to connect to a database over the inet. You need to reference RDS and RDO in your project and set up an ODBC source on the server to the DB you want to access.

Once done so, use the following code to create a recordset on the client machine. That code can then be assigned to a RDO data aware control.

DIM ds AS RDS.DataSpace
DIM df
DIM cn AS RDO.rdConnection

SET ds = NEW RDS.DataSpace
SET df = ds.CreateObject("RDSServer.DataFactory")
SET cn = df.Connect("SERVER=MyServer;DSN=MyODBCRef;"

SET myDataAwareControl.Resultset = cn.OpenResultset("SELECT * FROM etc..."

good luck
LK
0
 
LVL 1

Author Comment

by:EvanL
ID: 1447997
Thanks for the input, but I need a more simple solution.  The server where the DB lies is a leased space.  Therefore, I can't add an ODBC source on there.

Any way to use the MS iNet control and FTP to get the DB?
0
 
LVL 1

Accepted Solution

by:
lbk earned 110 total points
ID: 1447998
In this case I see only one solution. And even that only works if the server is IIS, therefor windows based. You CANNOT access the database via ftp or inet, unless you want to download the DB manually and then access it on the cloent side. Instead you might want to use ASP scripts and return a MIME type, resp. a streeam containing a byte stream with the result data of the query.

So in the ASP file you would write

Respone.WriteBinary Data

and on the client side you would retrieve the data using the INet control as follows

Inet1.GetDocument MyServer/DB.Asp

The asp file then returns the data, and you retrieve it much like an HTML document, excpet that you would have to partse it first.
Good luck... I don't see any other way, sorry
LK
0
 
LVL 1

Author Comment

by:EvanL
ID: 1447999
If the database is a text file, I could download it to the user's PC, access it in the form, and then send the text database back to the server.  

Any ideas on how that can be done?
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question