I have a simple usercontrol with a few controls and a few public functions.
It basically is a time control - 1 textbox for Hour, 1 textbox for Minute
and 1 dropdown for am/pm. Some public functions for example are gettime,
settime, gethour, etc...
I dropped several of these usercontrols inside the InsertItemTemplate of a
formview control. (It's a work week time scenario.)
QUESTION: How do I call one of the usercontrols public function?
I tried this but the function won't be called:
i = CType(FormView1.FindControl("ucClosingTimeSunday"),
UserControl).GetHour()
Any ideas what I'm doing wrong? Thanks!
Cirene - 17 May 2008 03:17 GMT
This seemed to work better...
CType(FormView1.FindControl("ucClosingTimeSunday"), ucTimeSelect).GetHour()
Thanks..
>I have a simple usercontrol with a few controls and a few public functions.
>It basically is a time control - 1 textbox for Hour, 1 textbox for Minute
[quoted text clipped - 12 lines]
>
> Any ideas what I'm doing wrong? Thanks!