Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 413
Default ActiveX Control (TextBox) question

Using Excel 2000.

The textbox is embedded directly into the sheet.
When the workbook (with its single sheet) is opened,
the textbox is visible and accessible to the user.

Can I control access to the textbox, so that it is
only accessible under certain conditions?

For example, in the ThisWorkbook module I have
code in the Workbook_Open Event. Can I do
something like:
If ContractMaster = True Then
Enable the Contol
Else
User cannot edit the textbox

Is this possible please?

Regards.



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.714 / Virus Database: 470 - Release Date: 02/07/2004


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,302
Default ActiveX Control (TextBox) question

Hi Stuart,

To hide the textbox,try:

ActiveSheet.OLEObjects("Textbox1").Visible = True

To prevent editing, try:

ActiveSheet.OLEObjects("Textbox1").Enabled = True


---
Regards,
Norman

"Stuart" wrote in message
...
Using Excel 2000.

The textbox is embedded directly into the sheet.
When the workbook (with its single sheet) is opened,
the textbox is visible and accessible to the user.

Can I control access to the textbox, so that it is
only accessible under certain conditions?

For example, in the ThisWorkbook module I have
code in the Workbook_Open Event. Can I do
something like:
If ContractMaster = True Then
Enable the Contol
Else
User cannot edit the textbox

Is this possible please?

Regards.



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.714 / Virus Database: 470 - Release Date: 02/07/2004




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 413
Default ActiveX Control (TextBox) question

Many thanks.

Will give them a go.

Regards.

"Norman Jones" wrote in message
...
Hi Stuart,

To hide the textbox,try:

ActiveSheet.OLEObjects("Textbox1").Visible = True

To prevent editing, try:

ActiveSheet.OLEObjects("Textbox1").Enabled = True


---
Regards,
Norman

"Stuart" wrote in message
...
Using Excel 2000.

The textbox is embedded directly into the sheet.
When the workbook (with its single sheet) is opened,
the textbox is visible and accessible to the user.

Can I control access to the textbox, so that it is
only accessible under certain conditions?

For example, in the ThisWorkbook module I have
code in the Workbook_Open Event. Can I do
something like:
If ContractMaster = True Then
Enable the Contol
Else
User cannot edit the textbox

Is this possible please?

Regards.



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.714 / Virus Database: 470 - Release Date: 02/07/2004






---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.714 / Virus Database: 470 - Release Date: 02/07/2004


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
2007 Form Control/ActiveX Control font difference Nikko963 Excel Discussion (Misc queries) 0 April 15th 09 04:21 PM
Excel ActiveX TextBox Question dhstein Excel Discussion (Misc queries) 4 January 29th 09 02:12 PM
Tab to an ActiveX control? Karin Excel Discussion (Misc queries) 0 July 6th 05 05:08 AM
Question regarding an activex control button slim[_2_] Excel Programming 2 February 25th 04 04:00 PM
Dynamic TextBox ActiveX events Tom Ogilvy Excel Programming 0 September 29th 03 08:56 PM


All times are GMT +1. The time now is 05:07 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"