473,287 Members | 1,868 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,287 software developers and data experts.

Interfacing with a database using an API (i think...)

At least I think it's using an API (i don't totally understand the
concept.)

I'm using Act 6. I need to interface with the act database and add
'contacts' to the database. The reason I need to do this is because i'm

writing a little program to add a new prospect to the database when a
telephone lead rings through, the receptionist will use this program,
enter a few pieces of information and then transfer the call to the
salesman - at which point the salesman can pick up the new contact in
the Act program. This should be fairly straightforward.
I'm stuck. I cant figure out how to connect to the database. Or how to
add contacts to it. There is an extensive SDK pack which shows you how
to do this but i've had no joy (partly because the examples are in c++
and i use c# (i've only been learning it over the past couple of
months.)
PLEASE can you take a look www.strident.net/act i've included all the
files and the SDK. And can you then please offer any advice you can on
how I can do this.
So far i've managed to get access to the act namespace, but thats about

it - i can't figure out how to use it. (I got access by running tlbimp
on a .tlb file and referenceing the .dll this created - all of this has

been a very steep learning curve for me!)
I'd really appreciate your effort, i'm totally stumped at the moment.
I just need to
(a) connect to a database.
(b) write / edit it.
Thanks for your time, and do please take a look / offer any advice you
can.
Gary.

Mar 21 '06 #1
5 1476
Hi Gary,

The first question I would ask is, is there any overpowering reason you must
use this database product?

After reviewing the PDF in the SDK, and visiting their web site, I am
strongly impressed that this is a poor database solution for any company
that is looking at an extensible or scalable framework for their future.
This product does not have any OLE DB or ODBC drivers, and in fact, the
documentation discourages anyone from trying to obtain or use any such
products with it. You can't even read the Help documentation online without
an account. They make only ONE product for allowing their database product
to interact with any other type of database product, and it only interacts
with Microsoft Access, and only in one direction. That product costs more
than twice as much as the database product.

It is the sort of product which may seem to be "cheap" (inexpensive) in the
short run, but the hidden costs associated with upgrading, in terms of
extensibility and scalability, which involve buying more and more
proprietary software from the company, or buying support from the company,
and/or the cost of paying a programmer for the incredible number of hours
needed to write a custom proprietary application to interact with the
database, make it a cost nightmare in the long run.

In other words, this is the sort of tar baby that very small companies,
headed by technologically ignorant people, innocently buy, thinking that
they are saving money. Eventually, assuming that the company which is using
this software prospers, it *will* have to be abandoned in favor of some real
professional, scalable, extensible product, and the longer they put it off,
the more it will cost.

If you work for this company, you have my sympathies. If you do not work for
this company, but are an independent contractor, my advice would be to
recommend a change in products, and if that recommendation is not heeded,
run, do not walk, to the nearest exit.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer

Presuming that God is "only an idea" -
Ideas exist.
Therefore, God exists.

<ga********@myway.com> wrote in message
news:11**********************@t31g2000cwb.googlegr oups.com...
At least I think it's using an API (i don't totally understand the
concept.)

I'm using Act 6. I need to interface with the act database and add
'contacts' to the database. The reason I need to do this is because i'm

writing a little program to add a new prospect to the database when a
telephone lead rings through, the receptionist will use this program,
enter a few pieces of information and then transfer the call to the
salesman - at which point the salesman can pick up the new contact in
the Act program. This should be fairly straightforward.
I'm stuck. I cant figure out how to connect to the database. Or how to
add contacts to it. There is an extensive SDK pack which shows you how
to do this but i've had no joy (partly because the examples are in c++
and i use c# (i've only been learning it over the past couple of
months.)
PLEASE can you take a look www.strident.net/act i've included all the
files and the SDK. And can you then please offer any advice you can on
how I can do this.
So far i've managed to get access to the act namespace, but thats about

it - i can't figure out how to use it. (I got access by running tlbimp
on a .tlb file and referenceing the .dll this created - all of this has

been a very steep learning curve for me!)
I'd really appreciate your effort, i'm totally stumped at the moment.
I just need to
(a) connect to a database.
(b) write / edit it.
Thanks for your time, and do please take a look / offer any advice you
can.
Gary.

Mar 21 '06 #2
Thankyou for your reply, this is the first reply i've had all day - so
I really do appreciate it.

I'm afraid i'm already commited. The thing was the company I work had
already settled on Act! as another company in the same industry had
implemented a CRM solution based on it. And it was working well for
them. The problem has come because I want to write this little program
to simply add a new contact to the database. It should be easy enough,
and someone was in the process of writing such a program for me and
gave me a prototype and then dissapeared off the face of the earth
(about 3 months ago.)

15 licences have already been purchased for this Act, by my company.
And I have purchased VS 2005 prof. with the intention of mastering c#
and this is really the first real-world project i've tried. I know
there must be a way to get this to connect. I'm very close now and have
managed to get some communication with the API - but at the moment im
getting error code 87 which means it can't open the database. If i
change the filename to a file i know doesn't exist i get error 50 (file
not found) - so by getting error 87 it does at least seem to be seeing
the file. I just can't figure out why it can't open it... here is the
code i have so far:

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace actproject
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
ActOle.DATABASE database = new ActOle.DATABASE();

string mydbf = @"c:\ccleasing.dbf";
database.Close();
MessageBox.Show(database.Error.ToString());
database.Open(mydbf);

MessageBox.Show(database.Error.ToString());
MessageBox.Show(database.LastError.ToString());
}

I really am dependent on the good will of experts at the moment in
these forums. So thank you again for your reply.

Mar 21 '06 #3
I am not familiar with ACT, but the .dbf file appears to be a standard
dBase or FoxPro database file and the .mdx file is the index. Perhaps
you can setup a dsn for a dBase or FoxPro and access it that way.

Hope this helps a little.

Mar 21 '06 #4
I may be an expert on .Net programming, but I know nothing about the
proprietary API of Act. Have you visited their support web site?

--
HTH,

Kevin Spencer
Microsoft MVP
Professional Numbskull

Show me your certification without works,
and I'll show my certification
*by* my works.

<ga********@myway.com> wrote in message
news:11**********************@u72g2000cwu.googlegr oups.com...
Thankyou for your reply, this is the first reply i've had all day - so
I really do appreciate it.

I'm afraid i'm already commited. The thing was the company I work had
already settled on Act! as another company in the same industry had
implemented a CRM solution based on it. And it was working well for
them. The problem has come because I want to write this little program
to simply add a new contact to the database. It should be easy enough,
and someone was in the process of writing such a program for me and
gave me a prototype and then dissapeared off the face of the earth
(about 3 months ago.)

15 licences have already been purchased for this Act, by my company.
And I have purchased VS 2005 prof. with the intention of mastering c#
and this is really the first real-world project i've tried. I know
there must be a way to get this to connect. I'm very close now and have
managed to get some communication with the API - but at the moment im
getting error code 87 which means it can't open the database. If i
change the filename to a file i know doesn't exist i get error 50 (file
not found) - so by getting error 87 it does at least seem to be seeing
the file. I just can't figure out why it can't open it... here is the
code i have so far:

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace actproject
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
ActOle.DATABASE database = new ActOle.DATABASE();

string mydbf = @"c:\ccleasing.dbf";
database.Close();
MessageBox.Show(database.Error.ToString());
database.Open(mydbf);

MessageBox.Show(database.Error.ToString());
MessageBox.Show(database.LastError.ToString());
}

I really am dependent on the good will of experts at the moment in
these forums. So thank you again for your reply.

Mar 21 '06 #5
Yes Kevin but unfortunately Act was bought out by Sage and Sage don't
provide any support for the API...

They advise not to use a directly link bypassing the API (which is what
i assume DSN is?) but now i have no other option. I'll read up on it
all and give it a go.

My one worry was that this dbf is networked but then i suddenly thought
i'm sure this DSN shouldn't have a problem working with an opened
networked database, after all - what are most databases these days are
networked anyway.

I'm a little anxious about what would happen if Act and my program
tried to update the same field at the same time, but then I guess I
just need to bite the bullet and go for it...

Thanks again!

Gary.

Mar 22 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
by: David Walker | last post by:
Hi I have a program which I need to interface with a webpage - the webpage will accept an input (probably a 'post' string from the program) and then will process it and needs to return a value. ...
19
by: Adam Short | last post by:
I am trying to write a routine that will connect a .NET server with a classic ASP server. I know the following code doesn't work! The data is being returned as a dataset, however ASP does not...
2
by: headware | last post by:
I'm relatively new to ASP.NET and ADO.NET, but I have a basic design question regarding the use of web services and APS.NET applications. Right now we have an application that uses web services to...
1
by: Neil | last post by:
Our hosting company's server went down a few days ago. After they fixed it, our PHP Page and Database are not interfacing. They are not believing me that I have done nothing on my end in several...
1
by: keliie | last post by:
Hello, I've recently completed a database that tracks my food purchases and inventory and I want to add another piece to the database that tracks sales. Our company's waitstaff enters order...
0
by: garyusenet | last post by:
At least I think it's using an API (i don't totally understand the concept.) I'm using Act 6. I need to interface with the act database and add 'contacts' to the database. The reason I need to...
6
by: dev | last post by:
hi i want to know about interfacing or accessing a serial port using c-program please help me with an example thanks for whom who reply me soon
8
by: David | last post by:
Hi, I'm looking for advice on where to start with interfacing VB 2005 with Access 2003. For starters I would like to be able to add data to tables and retrieve queries from tables. Thanks, ...
0
by: tontobiker | last post by:
I have a 2003 server. A server 2008 with exchange and several laptops with vista business, windows 7 and xp. I use an EMR(i am a doc) that appears to be an addon for MS word. The backend is SQL...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.