SBX - Search With Button

SBX - Forum Post Title

How can I add functionality in Standard button event in Custom screens

Microsoft Dynamics SL Forum

ThillaiRaja asked a question on 22 Dec 2015 3:29 AM
My Badges

Question Status

Suggested Answer

Hi,

    I am creating new custom screen in visual studio 2010,here i can not add functionality in standard button like New,Cancel,Save and Delete.Please can anyone help.Thanks in advance.

Below my sample code(not working one):

Private Sub Update1_CancelEvent(ByVal Level As Short, ByRef RetVal As Short) Handles Update1.CancelEvent
MsgBox("Clik")
End Sub

Private Sub Update1_DeleteEvent(ByVal Level As Short, ByVal LevelsDone As Short, ByRef RetVal As Short) Handles Update1.DeleteEvent
MsgBox("Clik")
End Sub

Private Sub Update1_NewLevelEvent(ByVal Level As Short, ByRef RetVal As Short) Handles Update1.NewLevelEvent
MsgBox("Clik")
End Sub

Private Sub Update1_UpdateEvent(ByVal Level As Short, ByVal InsertFlg As Short, ByVal LevelsDone As Short, ByVal LevelsLeft As Short, ByRef RetVal As Short) Handles Update1.UpdateEvent
MsgBox("Clik")
End Sub

Reply
PerumalSamy R responded on 23 Dec 2015 5:20 AM
My Badges
Suggested Answer

Hello Thillairaja,

You can add your business logics in Menu controls like New,Save, Delete, Cancel & Navigation button if you need to do some specific logic check.

You don't have to add logic to save, delete, update operation in custom screen since Standard SL should automatically do those operations for you. If you would want to add some special checks on your screen, you could potentially add your custom logic.

At what circumstances/scenarios you're looking to add the custom logic in your code.

please let me know.

Reply
ThillaiRaja responded on 23 Dec 2015 5:41 AM
My Badges

Hi PerumalSamy,

       In My custom screen the Standard buttons not doing any actions,I am not sure what i did wrong.And i want to add some custom logic in New button and Save button .Please can you give syntax   for this code.

Thanks,

Thillairaja

Reply
PerumalSamy R responded on 23 Dec 2015 5:56 AM
My Badges

Hello Thillairaja,

you can refer the syntax in customization manager pdf which you could find in User Manuals of Dynamics SL SDK software package.

Did you install the User Guides while installing the Dynamics SL software? Also can you please tell the what version of Dynamics SL you are using?

Reply
ThillaiRaja responded on 23 Dec 2015 7:43 AM
My Badges

I am using SL 2011 FP1-Advance Management version 8.12.40821.00(8.0.0)

Have looked that document and followed that doc syntax but still the event not called.

below my sample code:

Sub Update1_NewLevel(ByVal level%, ByVal retval%)

       MsgBox("Click")

   End Sub

   Sub Update1_Update(ByVal level%, ByVal retval%)

       MsgBox("ClicK)

   End Sub

   Sub Update1_Delete(ByVal level%, ByVal levelsdone%, ByVal retval%)

       MsgBox("ClicK")

   End Sub

   Sub Update1_Finish(ByVal Level, ByVal Updated, ByVal RetVal)

       MsgBox("click")

   End Sub

Thanks,

ThillaiRaja

Reply
PerumalSamy R responded on 24 Dec 2015 1:38 AM
My Badges

Thillairaja,

I believe something is related to standard issue. Do you have microsoft partner/customer source login? if you have, you can check to see if there is any hot fixes for those issue.

I hope Microsoft definitely released hotfixes for those issues. please verify it.

Reply
ThillaiRaja responded on 26 Dec 2015 6:24 AM
My Badges

Hi PerumalSamy,

   Very thanks for your time.

Reply
Alex Dupuis responded on 12 Jun 2018 8:29 AM
My Badges

Hi,

I know that it's not really a new topic but, I have the exact same problem.

Did you find out how to solve that?

Thanks.

Reply
PerumalSamy R responded on 23 Dec 2015 5:20 AM
My Badges
Suggested Answer

Hello Thillairaja,

You can add your business logics in Menu controls like New,Save, Delete, Cancel & Navigation button if you need to do some specific logic check.

You don't have to add logic to save, delete, update operation in custom screen since Standard SL should automatically do those operations for you. If you would want to add some special checks on your screen, you could potentially add your custom logic.

At what circumstances/scenarios you're looking to add the custom logic in your code.

please let me know.

Reply

SBX - Two Col Forum

SBX - Migrated JS