on 02-24-2006 7:32 AM
I have a problem using UI-API to auto create delivery and invoice once the user press the add button. The problem i am encountering is, when i use the after_success event, even if a message box appears and the record is not added in yet, the event triggered. Is there anyway to get the message box return value or check if the item is added first before the messagebox tiggers?
I know there is a work around using SBO_SP_TransactionNotification but there isnt many examples around to refer to. Do i need to create a dll or and exe is sufficient? Can anyone provide me with an example using VB.NET and UI API with the whole source code? Just a simple code to show when the item is added, a message box appears. I want the program just to capture the last transaction made and not generate it into notepad or into another table.
Thank you
Hi Melvin,
Here is the code which is added by the IBolt program
if not exists (
select *
from sysobjects
where id = object_id(N'ibolt_trigger') and
OBJECTPROPERTY(id, N'IsUserTable') = 1)
Begin
if exists (
select *
from sysobjects
where id = object_id(N'SAPB1_Triggered') and
OBJECTPROPERTY(id, N'IsUserTable') = 1)
Begin
EXEC sp_rename 'SAPB1_Triggered', 'ibolt_trigger'
End
Else
CREATE TABLE ibolt_trigger (
[recID] [int] IDENTITY (1, 1) NOT NULL ,
[DataObj] [int] NOT NULL ,
[TransType] [nchar] (1) COLLATE Hebrew_CI_AS NULL ,
[ListKeys] [nvarchar] (255) COLLATE Hebrew_CI_AS NULL ,
[ListValues] [nvarchar] (255) COLLATE Hebrew_CI_AS NULL ,
[TriggerDate] [datetime] NULL ,
[HandleStatus] [smallint] NOT NULL DEFAULT (0),
[HandleDate] [datetime] NULL ,
[HandleError] [smallint] NOT NULL DEFAULT (0)
) ON [PRIMARY]
End
INSERT INTO ibolt_trigger
(DataObj, TransType, ListKeys, ListValues, TriggerDate, HandleStatus, HandleError)
VALUES
(@object_type, @transaction_type,@list_of_key_cols_tab_del, @list_of_cols_val_tab_del, GetDate(), 0, 0);
As this is the sbo client which calls the stored procedure, I cannot see of any ways your add-on can capture that event (the procedure call) directly.
Beware that code may subject to copyright
Cheers,
Cyril
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
110 | |
12 | |
11 | |
6 | |
5 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.