How to create Intraweb application connected to relativity?

Hello,

I am looking to create an IntraWeb ‘hello world’ type application that uses relativity server. I can do the 2 separately but I have no idea how to bring them together in one app.
What I would like to know is how to create relativity connection without using the RemObject new app wizard, ie. which components/what settings are needed and where in IntraWeb(ie. ServerController, UserSessionUnit, MainForm) will these components go.

I am using Delpi XE2 Pro, IntraWeb XII RemObjects 2.0.1.109

Regards

Hello,
Please look at the attached project. Can you check your RemObjects version? RemObjects 2.0.1.109 is too old!

Dear vovanl,
Thank you a bunch! I was trying to arrive at this point for some time, however with the limited amount of information regarding this subject mixed in together with deprecated features, as well as being new to delphi, remobjects and intraweb it was quite a struggle. Your example is exactly what I needed.

Regarding my RemObjects version- you’re right, it’s not what I stated in my first post (although I don’t see why the splash indicates this old version when I look @ Delphi XE2->help-> ‘About RemObjects Everwood’), anyway the correct version no is : 7.0.65.1067.

Again, big cheers!

Sergey , theres any way to implement events on intraweb clients?

Hello,
You wrote:

theres any way to implement events on intraweb clients?

Try to use the following:

  1. Drop corresponded RO components on TIWForm and add EventSink interface here:
TIWForm1 = class(TIWAppForm, IMessageEventSink)
........................
    ROMessage: TROBinMessage;
    ROChannel: TROWinInetHTTPChannel;
    RORemoteService: TRORemoteService;
    ROEventReceiver1: TROEventReceiver;
    ROEventsChannel: TROWinInetHTTPChannel;
  public
    procedure OnSendMessage(const aText: AnsiString);
  end;
  1. Activate TROEventReceiver on creating form:
procedure TIWForm1.IWAppFormCreate(Sender: TObject);
begin
  ROEventReceiver1.RegisterEventHandler(EID_MessageEventSink, Self);
  ROEventReceiver1.Activate;
end;
  1. Call a remote service
procedure TIWForm1.IWButton1Click(Sender: TObject);
begin
  (RORemoteService as INewService).SendMessage('test');
end;
  1. Start time in event to update IW components:
procedure TIWForm1.OnSendMessage(const aText: AnsiString);
begin
  IWTimer1.Enabled := True;
end;
  1. Stop timer and update IW components:
procedure TIWForm1.IWTimer1Timer(Sender: TObject);
begin
  IWTimer1.Enabled := False;
  //update IW components
end;