Skip to main content
Post a question

Notifications

Community site session details

Community site session details

Session Id : CEFEpI5BBSNi9trjmZo4T4
Microsoft Dynamics SL (Archived)

HELP, Custom windows from dynamics SL

Like (0) ShareShare
ReportReport
Posted on 5 Jun 2017 16:04:23 by

Hi, Currently i try create a new personal windows form, how part of my training on VB.net. My windows form include 2 tables (author and books), mi goal is add, modify and eliminate entries of both tables with native functions of dynamics. At this moment have probles to modufy and delete on the safgrid i cand add without problems, but only can modify the first line on the grid. If try delete a register, the application only delete the first one or if select two or more delete the same registers take the first.

When debug the proyect i see the program doesn't send a message to ask if i sure to delete the information when delete from the safgrid control.

Why need to update and/or delete entries in the saftgrid using this buttons???

This is a screen of my proyect

try to delete id 04

when save usig button "save", the id deleted is 0

i apreciate your help and any advice to create custom forms. Have a nice day

*This post is locked for comments

  • Community Member Profile Picture
    on 06 Jun 2017 at 22:21:20
    RE: HELP, Custom windows from dynamics SL

    1.- The main table is "Autores" (pk idautor varchar(6), nombre varchar(50), nacionalidad varchar(50)) and "libros" (pk idlibro varchar(6),  nombre varchar (50), editorial varchar(50), year varchar(4), fk idauthor varchar(6))

    index_keys: idlibro, idautor .

    2.- I only use a SP for posible values to idautor on level 0 (select * from autores)

    3.- To fill de grid, I use a query "select * from libros where idautor like @pamr1 order by idlibro" @parm1 is equal bautores.idautor

    4.-  Dim MemHandle_Spread1 As Object

           Call ApplInit()

          

    Call SetAddr(LEVEL0, "bautores", bautores, nautores)

           Call SetAddr(LEVEL1, "blibros", blibros, nlibros)

          

    Call SqlCursorEx(c1, LEVEL0, "c1", "autores", "autores")

           Call SqlCursorEx(c2, LEVEL1, "c2", "libros", "libros")

          

    Call ScreenInit()

           MemHandle_Spread1 = DetailSetup(c2, SafGrid1, PNULL, blibros, PNULL, PNULL, PNULL)

     


    Control SAFUpdate Levels=autores;N,libros;D Name=Update1.

     

     

  • Apps Mexico Profile Picture
    1,090 on 05 Jun 2017 at 22:05:52
    RE: HELP, Custom windows from dynamics SL

    First of all, to know better what the causes are, we need to know four things.
    1.- The structure table, principaly the primary key fields.
    2.- The definition of the store procedure
    3 - The DVNav property of the grid
    4 - The form_load code

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 293,476 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,592 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans