Options

Opening a form on the first tab

WaldoWaldo Member Posts: 3,412
Example:
You create a form with 8 tabs. On the 5th tab, you create a subform. When you open the form, no matter what you do, it always opens the form on the 5th tab - for some reason. I don't know if this happens all the time, but probably most of you allready ran into the same type of problem.

I created some (weird) way around it, but I wanted to ask you wether there is a standard way to do it? Am I forgetting something?

Eric Wauters
MVP - Microsoft Dynamics NAV
My blog

Comments

  • Options
    eromeineromein Member Posts: 589
    This is becaurse you have the primairy key of the subtable in the form!

    Try to hide all primairy key fields in your subform... And you'll that it works like it should work...

    Thing is.... Do you want to do this???
    "Real programmers don't comment their code.
    If it was hard to write, it should be hard to understand."
  • Options
    WaldoWaldo Member Posts: 3,412
    At least one field of the primary key has to be shown on the subform, so unfortunately, this is no possible solution.

    I fixed it with sendkeys (CTRL+PGUP) ... not nice, but it works.

    Eric Wauters
    MVP - Microsoft Dynamics NAV
    My blog
  • Options
    g_dreyerg_dreyer Member Posts: 123
    Hi Waldo,

    I have come across this 'feature' before. :wink:
    Have you tried to set the property "DelayedInsert" = true in your subform?
    That should fix the problem.

    Regards,
    gus
  • Options
    WaldoWaldo Member Posts: 3,412
    Indeed, that fixed the problem!

    I had three subforms on the tab (don't ask ...), two of them had the "DelayedInsert" set to "TRUE", the bottom one not. Forgot one ... .

    Thanx!

    Eric Wauters
    MVP - Microsoft Dynamics NAV
    My blog
  • Options
    eromeineromein Member Posts: 589
    g_dreyer

    =D> =D> =D> =D> =D> =D> =D> =D> =D>

    Nice one! Now let me just save this on my personal harddisk :wink:
    "Real programmers don't comment their code.
    If it was hard to write, it should be hard to understand."
  • Options
    WaldoWaldo Member Posts: 3,412
    May be something for the Tips&Tricks section?

    Eric Wauters
    MVP - Microsoft Dynamics NAV
    My blog
  • Options
    g_dreyerg_dreyer Member Posts: 123
    :oops: :oops: :oops: :oops: :oops:
    Many moons ago I got stuck on that same problem, and it took me a while to figure that one out :-k, so I will never forget it.

    Just glad I could assist. :D

    I will stick it under the tips & tricks section, as a reminder to always set delayed insert if you are going to use the form as a subform.
Sign In or Register to comment.