vb.net - How to have a user control within MainForm call the MainForm Objects? -


i have user control created buttons, , placed within main form, contains things buttons , panels. want control(send messages) these fields when press buttons in user control, can't figure out oop implementation required achieve this.

i advised create initialize(f mainform) in user control code in order keep explicit reference main form, have not been able control fields of main form.

how can achieved? using visual basic, btw.

declare event in user control, , write handler event in form.

in control:

event zoomed() 

in control, raise event (call handler):

raiseevent zoomed() 

and add handler form:

sub aview_zoomed() handles aview.zoomed ... end sub 

Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -