• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 233
  • Last Modified:

Connecting to the AppServer using Socket

Hi,
 I am new to delphi and i am doing an application using socket connection.The feature that i need is a login.I have made the server using Remote data module and the client is connecting to the server using the socket connection.

Can someone help me out in passing the information entered by the user to the server database to check that the login information is correct.


Regards
Anna.
0
anna_1315
Asked:
anna_1315
  • 2
  • 2
1 Solution
 
aubsCommented:
Hi Anna,

What version of Delphi are you using?

I have a brief tutorial on MIDAS based on D5 using Oracle database. It should point you in the right direction.

It is 160kB Word document.

http://www.complete-git.co.uk/MIDAS/MIDAStut.doc

I could explain here, but it is easier to show you screen shots.

regards

Aubs
0
 
anna_1315Author Commented:
Dear Aubs,
 Thanks a lot for the same,i shall look into it.I am using D5.i was able to create the server using the Remote Data module  and connect to it using socket connection.Also i am using the Datamodule(customer data).My database is Paradox.

Problem:
Login feature to check the user has entered the correct user name and password.In order to do that i have created a custom method called login with parameters username and password as Varient using the type libary.Now i have called the method in the login screen,but it says type mismatch error when running.

Here is the code that i have used in remote data module:

procedure TAppServerP.Logon(username, password: OleVariant);
begin
  showMessage('hi');
end;

and here is the code i have used in login form.

 customerdata.socket.Connected := true;
 ip := '192.168.0.1';
 customerdata.Socket.AppServer.Logon(username.Text,Password.Text);

Can you help me out?

Warm Regards
Anna.
0
 
aubsCommented:
You need to create the interface for the Logon function.

Have a look at page 6:

Choose View > Type Library...
0
 
anna_1315Author Commented:
thanks aubs,
 i made it work :)

Regards
Anna.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now