PC Review


Reply
Thread Tools Rate Thread

creating a userform

 
 
Charlie
Guest
Posts: n/a
 
      18th Dec 2007
I want my userform to have labels that are updated with data from a sheet.
Where do I put my code to change things on my form. For example, if I want
to make a checkbox.visible to be false if sheet1.a1="yes" where do I put code
for this.
If I want a page on a multi-page to be visible depanding on a sheet
reference, where does this code go?
thanks.
 
Reply With Quote
 
 
 
 
carlo
Guest
Posts: n/a
 
      18th Dec 2007
Each form has the load function which loads the form, but doesn't show
it yet. then you can arrange your stuff and make it visible with
form.visible.

load form
checkbox.visible = sheet1.range("A1").value
form.show

you can put this code on a button or anything else.

make the values of sheet1 as TRUE or FALSE, that way you can use the
value directly, without evaluating it first.

hth Carlo


On Dec 18, 1:34 pm, Charlie <Char...@discussions.microsoft.com> wrote:
> I want my userform to have labels that are updated with data from a sheet.
> Where do I put my code to change things on my form. For example, if I want
> to make a checkbox.visible to be false if sheet1.a1="yes" where do I put code
> for this.
> If I want a page on a multi-page to be visible depanding on a sheet
> reference, where does this code go?
> thanks.


 
Reply With Quote
 
john
Guest
Posts: n/a
 
      18th Dec 2007
If you unfamiliar with creating userforms have a look at this site
http://www.contextures.com/xlUserFor...serForm01.html

--
JB


"Charlie" wrote:

> I want my userform to have labels that are updated with data from a sheet.
> Where do I put my code to change things on my form. For example, if I want
> to make a checkbox.visible to be false if sheet1.a1="yes" where do I put code
> for this.
> If I want a page on a multi-page to be visible depanding on a sheet
> reference, where does this code go?
> thanks.

 
Reply With Quote
 
Charlie
Guest
Posts: n/a
 
      21st Dec 2007
This was VERY helpful! Thanks. How do I do this: I have a multipage, and
each page is to show data from a sheet that is set up as a database. It will
have 2 to 10 entrys (rows of data) with this data being shown, one entry on
each sheet. Can I programatically add pages to this multipage as the form
loads? If I have the first page set up with text boxes, list boxes, etc to
show my data, can I create more pages on this multipage, if there are more
entries (up to 10)?

"john" wrote:

> If you unfamiliar with creating userforms have a look at this site:
> http://www.contextures.com/xlUserFor...serForm01.html
>
> --
> JB
>
>
> "Charlie" wrote:
>
> > I want my userform to have labels that are updated with data from a sheet.
> > Where do I put my code to change things on my form. For example, if I want
> > to make a checkbox.visible to be false if sheet1.a1="yes" where do I put code
> > for this.
> > If I want a page on a multi-page to be visible depanding on a sheet
> > reference, where does this code go?
> > thanks.

 
Reply With Quote
 
carlo
Guest
Posts: n/a
 
      21st Dec 2007
If you know, that there are maximum 10 rows, i would make 10pages and
hide/unhide them.

hth

Carlo

On Dec 21, 12:54*pm, Charlie <Char...@discussions.microsoft.com>
wrote:
> This was VERY helpful! *Thanks. *How do I do this: *I have a multipage, and
> each page is to show data from a sheet that is set up as a database. *Itwill
> have 2 to 10 entrys (rows of data) with this data being shown, one entry on
> each sheet. *Can I programatically add pages to this multipage as the form
> loads? *If I have the first page set up with text boxes, list boxes, etcto
> show my data, can I create more pages on this multipage, if there are more
> entries (up to 10)?
>
>
>
> "john" wrote:
> > If you unfamiliar with creating userforms have a look at this site:
> >http://www.contextures.com/xlUserFor...contextures.co...

>
> > --
> > JB

>
> > "Charlie" wrote:

>
> > > I want my userform to have labels that are updated with data from a sheet. *
> > > Where do I put my code to change things on my form. *For example, ifI want
> > > to make a checkbox.visible to be false if sheet1.a1="yes" where do Iput code
> > > for this.
> > > If I want a page on a multi-page to be visible depanding on a sheet
> > > reference, where does this code go?
> > > thanks.- Hide quoted text -

>
> - Show quoted text -


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Creating a lookup in a userform BJ&theBear Microsoft Excel Misc 4 17th Mar 2010 06:51 PM
Creating a userform? Dobbin0_4 Microsoft Excel Programming 5 19th Jan 2010 09:40 PM
Creating a Userform MaxRoberts22 Microsoft Excel Programming 3 2nd Feb 2006 08:03 PM
creating a userform =?Utf-8?B?SmlsbCBE?= Microsoft Word Document Management 8 15th Nov 2005 07:25 PM
Creating first ever userform but not going how I wanted =?Utf-8?B?V2hpdGVGYWxjb24=?= Microsoft Excel Programming 4 11th May 2005 12:00 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:49 PM.