run-time error 371

karnaini
karnaini used Ask the Experts™
on
I got error when I issued this statement in my MDI form:

        frmColumn.Show vbModeless, Me

error message:
run-time error 371: the specified object can't be used as an owner form for show()


What's wrong? any solution?

Thanks,
Iskandar
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Head of Software Services
Commented:
Are you sure that this code was issued in the MDI parent form, an MDI child cannot be an owner of another form as only the MDI parent is an owner of forms within this type of application. You can use the MDI parent as the owner even if you call this from an MDI child form:

frmColumn.Show vbModeless, frmMDIParentFormName

Commented:
hi karnaini
i think that I have a solution.
If the above code is written in form_load or in any click event of the mdi form menu, then you should omit the word me.
bye
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
- answered by TimCottee
Please leave any comments here within the
next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

twalgrave
Cleanup Volunteer
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial