473,729 Members | 2,345 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Easiest Way to Enable Groups of Controls?

I have a form with lines of controls. On some of the lines there are 3
controls (call them A,B,C); other lines have only control A. The controls
have been numbered sequentially (Q20, Q21....Q76) and they were put onto the
form in the numerical sequence. I have given the A's with B & C's on the
same line a tag=1; B.tag=2, C,tag=2)

I am trying to write 2 modules so that the following occurs (on Form_Current
and 'A' Control_Before or After Update Events).

For each line, Control A will always be enabled.
For each line if there are B & C controls, if A is not null, enable B&C,
otherwise disable them.

The only way I have found of making this work seems awfully cumbersome,
and it won't work on the Before/After _Update events because you can't send
the focus to a disabled control to enable it. Is there a simpler way to
accomplish this? I've included some of my questions in the comment lines.

My method is: On _Form Current:

Public Sub EnableBC(frmcur rent As Form, fldCurr As Variant, fldCurrName As
Variant, fldMax As Variant)
'this is for Q1-Q99
On Error GoTo Err_EnableBC

Dim fldB As Variant 'the number part of control B's name
Dim fldC As Variant 'the number part of control B's name
Dim fldBName As Variant 'B control fieldname
Dim fldCName As Variant 'C control fieldname
Dim fldCtrl1 As Control 'Actual B control
Dim fldCtrl2 As Control 'Actual C Control
Dim fldCtrlCurr As Control 'Actual A Control
Dim ocontrol As Control
Dim icount As Integer

Debug.Print "fldCurr= "; fldCurr
Debug.Print "fldMax= "; fldMax

'Enable all B and C Controls
For Each ocontrol In frmcurrent
If TypeOf ocontrol Is ComboBox And ocontrol.Tag = 2 Then
ocontrol.Enable d = True
End If

If TypeOf ocontrol Is TextBox And ocontrol.Tag = 2 Then
ocontrol.Enable d = True
End If
Next ocontrol
For Each ocontrol In frmcurrent
If TypeOf ocontrol Is ComboBox Or TypeOf ocontrol Is TextBox Then
If ocontrol.Tag = 1 Then
If IsNull(ocontrol ) = True Or ocontrol = 0 Then
Debug.Print "in the tag=1 loop"
Debug.Print "oControl.n ame= "; ocontrol.Name
fldB = Right$(ocontrol .Name, 2) + 1
Debug.Print "fldB = "; fldB
fldC = Right$(ocontrol .Name, 2) + 2
Debug.Print "fldC = "; fldC
fldBName = "Q" & fldB
Debug.Print "fldBName= "; fldBName
fldCName = "Q" & fldC

'go to the control you want to disable. This is the ONLY way I could get
this to work, unless I'm majorly missing the boat 'on the technique here.
However I can't disable a control that has the focus, I can only lock it.
Can I disable the control 'without going to it first? Until this point in
the loop I have been dealing with the B and C controls NAMES only - not the
'actual control. But I can't lock/disable a NAME, only a control. And when
I use this type of routine in the Before/After 'Update event, it won't allow
me to GOTO a disabled control, of course.

DoCmd.GoToContr ol fldBName
Set fldCtrl1 = Screen.ActiveCo ntrol
With fldCtrl1
.Locked = True
.Value = ""
End With

DoCmd.GoToContr ol fldCName
Set fldCtrl2 = Screen.ActiveCo ntrol

With fldCtrl2
.Locked = True
.Value = ""
End With
Else
Debug.Print "oControl.n ame= "; ocontrol.Name
fldB = Right$(ocontrol .Name, 2) + 1
Debug.Print "fldB = "; fldB
fldC = Right$(ocontrol .Name, 2) + 2
Debug.Print "fldC = "; fldC
fldBName = "Q" & fldB
Debug.Print "fldBName= "; fldBName
fldCName = "Q" & fldC
DoCmd.GoToContr ol fldBName
Set fldCtrl1 = Screen.ActiveCo ntrol

With fldCtrl1
.Locked = False
End With

DoCmd.GoToContr ol fldCName
Set fldCtrl2 = Screen.ActiveCo ntrol
With fldCtrl2
.Locked = False
End With
End If
End If
End If
Next ocontrol

'I put the focus on a field which will never be affected so I can now
disenable the controls I want disenabled.

frmcurrent!Q58A .SetFocus

'Now I can loop through and disable the controls which are locked. Then,
for some reason, it didn't turn them to the usual 'gray, so I had to force
the color to indicate they are disabled.

For Each ocontrol In frmcurrent
If TypeOf ocontrol Is TextBox Or TypeOf ocontrol Is ComboBox Then
Debug.Print "in the final loop"
Debug.Print "ocontrol= "; ocontrol.Name

If ocontrol.Locked = -1 Then
ocontrol.Enable d = False
ocontrol.BackCo lor = 8421504 'gray
Else
ocontrol.Enable d = True
ocontrol.BackCo lor = 16777215 'white
End If
End If
Next ocontrol

Err_EnableBC:
Exit Sub

End Sub

Now I KNOW there has to be a more reasonable way to accomplish this.
PLEASE, someone, show me the path to take on this.

Thanks!

Andi
Nov 13 '05 #1
3 3798
This is not correct: "because you can't send the focus to a disabled control
to enable it." A disabled control does not need to have the focus to enable
it. What you can't do is disable a control that has the focus. So the first
thing you must do is set the focus to an enabled control that is not a party
to the routine...

--

Tony D'Ambra
Web Site: aadconsulting.c om
Web Blog: accessextra.net

"DBQueen" <ir******@bells outh.net> wrote in message
news:6h******** **********@bign ews6.bellsouth. net...
I have a form with lines of controls. On some of the lines there are 3
controls (call them A,B,C); other lines have only control A. The controls
have been numbered sequentially (Q20, Q21....Q76) and they were put onto
the
form in the numerical sequence. I have given the A's with B & C's on the
same line a tag=1; B.tag=2, C,tag=2)

I am trying to write 2 modules so that the following occurs (on
Form_Current
and 'A' Control_Before or After Update Events).

For each line, Control A will always be enabled.
For each line if there are B & C controls, if A is not null, enable
B&C,
otherwise disable them.

The only way I have found of making this work seems awfully cumbersome,
and it won't work on the Before/After _Update events because you can't
send
the focus to a disabled control to enable it. Is there a simpler way to
accomplish this? I've included some of my questions in the comment lines.

My method is: On _Form Current:

Public Sub EnableBC(frmcur rent As Form, fldCurr As Variant, fldCurrName As
Variant, fldMax As Variant)
'this is for Q1-Q99
On Error GoTo Err_EnableBC

Dim fldB As Variant 'the number part of control B's name
Dim fldC As Variant 'the number part of control B's name
Dim fldBName As Variant 'B control fieldname
Dim fldCName As Variant 'C control fieldname
Dim fldCtrl1 As Control 'Actual B control
Dim fldCtrl2 As Control 'Actual C Control
Dim fldCtrlCurr As Control 'Actual A Control
Dim ocontrol As Control
Dim icount As Integer

Debug.Print "fldCurr= "; fldCurr
Debug.Print "fldMax= "; fldMax

'Enable all B and C Controls
For Each ocontrol In frmcurrent
If TypeOf ocontrol Is ComboBox And ocontrol.Tag = 2 Then
ocontrol.Enable d = True
End If

If TypeOf ocontrol Is TextBox And ocontrol.Tag = 2 Then
ocontrol.Enable d = True
End If
Next ocontrol
For Each ocontrol In frmcurrent
If TypeOf ocontrol Is ComboBox Or TypeOf ocontrol Is TextBox Then
If ocontrol.Tag = 1 Then
If IsNull(ocontrol ) = True Or ocontrol = 0 Then
Debug.Print "in the tag=1 loop"
Debug.Print "oControl.n ame= "; ocontrol.Name
fldB = Right$(ocontrol .Name, 2) + 1
Debug.Print "fldB = "; fldB
fldC = Right$(ocontrol .Name, 2) + 2
Debug.Print "fldC = "; fldC
fldBName = "Q" & fldB
Debug.Print "fldBName= "; fldBName
fldCName = "Q" & fldC

'go to the control you want to disable. This is the ONLY way I could get
this to work, unless I'm majorly missing the boat 'on the technique here.
However I can't disable a control that has the focus, I can only lock it.
Can I disable the control 'without going to it first? Until this point in
the loop I have been dealing with the B and C controls NAMES only - not
the
'actual control. But I can't lock/disable a NAME, only a control. And
when
I use this type of routine in the Before/After 'Update event, it won't
allow
me to GOTO a disabled control, of course.

DoCmd.GoToContr ol fldBName
Set fldCtrl1 = Screen.ActiveCo ntrol
With fldCtrl1
.Locked = True
.Value = ""
End With

DoCmd.GoToContr ol fldCName
Set fldCtrl2 = Screen.ActiveCo ntrol

With fldCtrl2
.Locked = True
.Value = ""
End With
Else
Debug.Print "oControl.n ame= "; ocontrol.Name
fldB = Right$(ocontrol .Name, 2) + 1
Debug.Print "fldB = "; fldB
fldC = Right$(ocontrol .Name, 2) + 2
Debug.Print "fldC = "; fldC
fldBName = "Q" & fldB
Debug.Print "fldBName= "; fldBName
fldCName = "Q" & fldC
DoCmd.GoToContr ol fldBName
Set fldCtrl1 = Screen.ActiveCo ntrol

With fldCtrl1
.Locked = False
End With

DoCmd.GoToContr ol fldCName
Set fldCtrl2 = Screen.ActiveCo ntrol
With fldCtrl2
.Locked = False
End With
End If
End If
End If
Next ocontrol

'I put the focus on a field which will never be affected so I can now
disenable the controls I want disenabled.

frmcurrent!Q58A .SetFocus

'Now I can loop through and disable the controls which are locked. Then,
for some reason, it didn't turn them to the usual 'gray, so I had to force
the color to indicate they are disabled.

For Each ocontrol In frmcurrent
If TypeOf ocontrol Is TextBox Or TypeOf ocontrol Is ComboBox Then
Debug.Print "in the final loop"
Debug.Print "ocontrol= "; ocontrol.Name

If ocontrol.Locked = -1 Then
ocontrol.Enable d = False
ocontrol.BackCo lor = 8421504 'gray
Else
ocontrol.Enable d = True
ocontrol.BackCo lor = 16777215 'white
End If
End If
Next ocontrol

Err_EnableBC:
Exit Sub

End Sub

Now I KNOW there has to be a more reasonable way to accomplish this.
PLEASE, someone, show me the path to take on this.

Thanks!

Andi

Nov 13 '05 #2
This is not correct: "because you can't send the focus to a disabled control
to enable it." A disabled control does not need to have the focus to enable
it. What you can't do is disable a control that has the focus. So the first
thing you must do is set the focus to an enabled control that is not a party
to the routine...

--

Tony D'Ambra
Web Site: aadconsulting.c om
Web Blog: accessextra.net

"DBQueen" <ir******@bells outh.net> wrote in message
news:6h******** **********@bign ews6.bellsouth. net...
I have a form with lines of controls. On some of the lines there are 3
controls (call them A,B,C); other lines have only control A. The controls
have been numbered sequentially (Q20, Q21....Q76) and they were put onto
the
form in the numerical sequence. I have given the A's with B & C's on the
same line a tag=1; B.tag=2, C,tag=2)

I am trying to write 2 modules so that the following occurs (on
Form_Current
and 'A' Control_Before or After Update Events).

For each line, Control A will always be enabled.
For each line if there are B & C controls, if A is not null, enable
B&C,
otherwise disable them.

The only way I have found of making this work seems awfully cumbersome,
and it won't work on the Before/After _Update events because you can't
send
the focus to a disabled control to enable it. Is there a simpler way to
accomplish this? I've included some of my questions in the comment lines.

My method is: On _Form Current:

Public Sub EnableBC(frmcur rent As Form, fldCurr As Variant, fldCurrName As
Variant, fldMax As Variant)
'this is for Q1-Q99
On Error GoTo Err_EnableBC

Dim fldB As Variant 'the number part of control B's name
Dim fldC As Variant 'the number part of control B's name
Dim fldBName As Variant 'B control fieldname
Dim fldCName As Variant 'C control fieldname
Dim fldCtrl1 As Control 'Actual B control
Dim fldCtrl2 As Control 'Actual C Control
Dim fldCtrlCurr As Control 'Actual A Control
Dim ocontrol As Control
Dim icount As Integer

Debug.Print "fldCurr= "; fldCurr
Debug.Print "fldMax= "; fldMax

'Enable all B and C Controls
For Each ocontrol In frmcurrent
If TypeOf ocontrol Is ComboBox And ocontrol.Tag = 2 Then
ocontrol.Enable d = True
End If

If TypeOf ocontrol Is TextBox And ocontrol.Tag = 2 Then
ocontrol.Enable d = True
End If
Next ocontrol
For Each ocontrol In frmcurrent
If TypeOf ocontrol Is ComboBox Or TypeOf ocontrol Is TextBox Then
If ocontrol.Tag = 1 Then
If IsNull(ocontrol ) = True Or ocontrol = 0 Then
Debug.Print "in the tag=1 loop"
Debug.Print "oControl.n ame= "; ocontrol.Name
fldB = Right$(ocontrol .Name, 2) + 1
Debug.Print "fldB = "; fldB
fldC = Right$(ocontrol .Name, 2) + 2
Debug.Print "fldC = "; fldC
fldBName = "Q" & fldB
Debug.Print "fldBName= "; fldBName
fldCName = "Q" & fldC

'go to the control you want to disable. This is the ONLY way I could get
this to work, unless I'm majorly missing the boat 'on the technique here.
However I can't disable a control that has the focus, I can only lock it.
Can I disable the control 'without going to it first? Until this point in
the loop I have been dealing with the B and C controls NAMES only - not
the
'actual control. But I can't lock/disable a NAME, only a control. And
when
I use this type of routine in the Before/After 'Update event, it won't
allow
me to GOTO a disabled control, of course.

DoCmd.GoToContr ol fldBName
Set fldCtrl1 = Screen.ActiveCo ntrol
With fldCtrl1
.Locked = True
.Value = ""
End With

DoCmd.GoToContr ol fldCName
Set fldCtrl2 = Screen.ActiveCo ntrol

With fldCtrl2
.Locked = True
.Value = ""
End With
Else
Debug.Print "oControl.n ame= "; ocontrol.Name
fldB = Right$(ocontrol .Name, 2) + 1
Debug.Print "fldB = "; fldB
fldC = Right$(ocontrol .Name, 2) + 2
Debug.Print "fldC = "; fldC
fldBName = "Q" & fldB
Debug.Print "fldBName= "; fldBName
fldCName = "Q" & fldC
DoCmd.GoToContr ol fldBName
Set fldCtrl1 = Screen.ActiveCo ntrol

With fldCtrl1
.Locked = False
End With

DoCmd.GoToContr ol fldCName
Set fldCtrl2 = Screen.ActiveCo ntrol
With fldCtrl2
.Locked = False
End With
End If
End If
End If
Next ocontrol

'I put the focus on a field which will never be affected so I can now
disenable the controls I want disenabled.

frmcurrent!Q58A .SetFocus

'Now I can loop through and disable the controls which are locked. Then,
for some reason, it didn't turn them to the usual 'gray, so I had to force
the color to indicate they are disabled.

For Each ocontrol In frmcurrent
If TypeOf ocontrol Is TextBox Or TypeOf ocontrol Is ComboBox Then
Debug.Print "in the final loop"
Debug.Print "ocontrol= "; ocontrol.Name

If ocontrol.Locked = -1 Then
ocontrol.Enable d = False
ocontrol.BackCo lor = 8421504 'gray
Else
ocontrol.Enable d = True
ocontrol.BackCo lor = 16777215 'white
End If
End If
Next ocontrol

Err_EnableBC:
Exit Sub

End Sub

Now I KNOW there has to be a more reasonable way to accomplish this.
PLEASE, someone, show me the path to take on this.

Thanks!

Andi

Nov 13 '05 #3
Thanks for your reply, Tony. I understand what you are saying, but I still
don't know how to refer to the control that I want to enable (or disable).
The part of my code before the DoCmd.GoToContr ol, finds the NAME of the
controls I want to enable. But I can't find a way to get the actual CONTROL
enabled without first jumping to it, capturing it to a Control Variable,
jumping away from it and then changing it's status. Besides seeming awkward
to me, it makes my form have a sort of small "seizure" as the GoToControl
function hops around.

What I'm looking for is a simple way to say: "For any control with a Tag of
1 whose value is not null, enable the next 2 controls after it" ?

I tried to capture the value of the current control in the Controls "array"
and then go to the next 2 controls in line:
For i=0 to 49
if ocontrol=Forms( frmCurrent).Con trols(i) then
fldctrl1=Forms( frmCurrent).Con trols(i+1)
fldctrl2=Forms( frmCurrent).Con trols(i+2)
fldctrl1.enable d=true
fldctrl2.enable d=true
end if
next i

.....but I got a type mismatch on the IF line - I guess my ocontrol isn't the
same datatype as Forms(frmCurren t).Controls(i) .

Can you offer any other insights?

Thanks!

Andi

"Tony D'Ambra" <td*****@swiftd sl.com.au> wrote in message
news:41******** *************** @news.syd.swift dsl.com.au...
This is not correct: "because you can't send the focus to a disabled control to enable it." A disabled control does not need to have the focus to enable it. What you can't do is disable a control that has the focus. So the first thing you must do is set the focus to an enabled control that is not a party to the routine...

--

Tony D'Ambra
Web Site: aadconsulting.c om
Web Blog: accessextra.net

"DBQueen" <ir******@bells outh.net> wrote in message
news:6h******** **********@bign ews6.bellsouth. net...
I have a form with lines of controls. On some of the lines there are 3
controls (call them A,B,C); other lines have only control A. The controls have been numbered sequentially (Q20, Q21....Q76) and they were put onto
the
form in the numerical sequence. I have given the A's with B & C's on the same line a tag=1; B.tag=2, C,tag=2)

I am trying to write 2 modules so that the following occurs (on
Form_Current
and 'A' Control_Before or After Update Events).

For each line, Control A will always be enabled.
For each line if there are B & C controls, if A is not null, enable
B&C,
otherwise disable them.

The only way I have found of making this work seems awfully cumbersome, and it won't work on the Before/After _Update events because you can't
send
the focus to a disabled control to enable it. Is there a simpler way to
accomplish this? I've included some of my questions in the comment lines.
My method is: On _Form Current:

Public Sub EnableBC(frmcur rent As Form, fldCurr As Variant, fldCurrName As Variant, fldMax As Variant)
'this is for Q1-Q99
On Error GoTo Err_EnableBC

Dim fldB As Variant 'the number part of control B's name
Dim fldC As Variant 'the number part of control B's name
Dim fldBName As Variant 'B control fieldname
Dim fldCName As Variant 'C control fieldname
Dim fldCtrl1 As Control 'Actual B control
Dim fldCtrl2 As Control 'Actual C Control
Dim fldCtrlCurr As Control 'Actual A Control
Dim ocontrol As Control
Dim icount As Integer

Debug.Print "fldCurr= "; fldCurr
Debug.Print "fldMax= "; fldMax

'Enable all B and C Controls
For Each ocontrol In frmcurrent
If TypeOf ocontrol Is ComboBox And ocontrol.Tag = 2 Then
ocontrol.Enable d = True
End If

If TypeOf ocontrol Is TextBox And ocontrol.Tag = 2 Then
ocontrol.Enable d = True
End If
Next ocontrol
For Each ocontrol In frmcurrent
If TypeOf ocontrol Is ComboBox Or TypeOf ocontrol Is TextBox Then
If ocontrol.Tag = 1 Then
If IsNull(ocontrol ) = True Or ocontrol = 0 Then
Debug.Print "in the tag=1 loop"
Debug.Print "oControl.n ame= "; ocontrol.Name
fldB = Right$(ocontrol .Name, 2) + 1
Debug.Print "fldB = "; fldB
fldC = Right$(ocontrol .Name, 2) + 2
Debug.Print "fldC = "; fldC
fldBName = "Q" & fldB
Debug.Print "fldBName= "; fldBName
fldCName = "Q" & fldC

'go to the control you want to disable. This is the ONLY way I could get this to work, unless I'm majorly missing the boat 'on the technique here. However I can't disable a control that has the focus, I can only lock it. Can I disable the control 'without going to it first? Until this point in the loop I have been dealing with the B and C controls NAMES only - not
the
'actual control. But I can't lock/disable a NAME, only a control. And
when
I use this type of routine in the Before/After 'Update event, it won't
allow
me to GOTO a disabled control, of course.

DoCmd.GoToContr ol fldBName
Set fldCtrl1 = Screen.ActiveCo ntrol
With fldCtrl1
.Locked = True
.Value = ""
End With

DoCmd.GoToContr ol fldCName
Set fldCtrl2 = Screen.ActiveCo ntrol

With fldCtrl2
.Locked = True
.Value = ""
End With
Else
Debug.Print "oControl.n ame= "; ocontrol.Name
fldB = Right$(ocontrol .Name, 2) + 1
Debug.Print "fldB = "; fldB
fldC = Right$(ocontrol .Name, 2) + 2
Debug.Print "fldC = "; fldC
fldBName = "Q" & fldB
Debug.Print "fldBName= "; fldBName
fldCName = "Q" & fldC
DoCmd.GoToContr ol fldBName
Set fldCtrl1 = Screen.ActiveCo ntrol

With fldCtrl1
.Locked = False
End With

DoCmd.GoToContr ol fldCName
Set fldCtrl2 = Screen.ActiveCo ntrol
With fldCtrl2
.Locked = False
End With
End If
End If
End If
Next ocontrol

'I put the focus on a field which will never be affected so I can now
disenable the controls I want disenabled.

frmcurrent!Q58A .SetFocus

'Now I can loop through and disable the controls which are locked. Then, for some reason, it didn't turn them to the usual 'gray, so I had to force the color to indicate they are disabled.

For Each ocontrol In frmcurrent
If TypeOf ocontrol Is TextBox Or TypeOf ocontrol Is ComboBox Then
Debug.Print "in the final loop"
Debug.Print "ocontrol= "; ocontrol.Name

If ocontrol.Locked = -1 Then
ocontrol.Enable d = False
ocontrol.BackCo lor = 8421504 'gray
Else
ocontrol.Enable d = True
ocontrol.BackCo lor = 16777215 'white
End If
End If
Next ocontrol

Err_EnableBC:
Exit Sub

End Sub

Now I KNOW there has to be a more reasonable way to accomplish this.
PLEASE, someone, show me the path to take on this.

Thanks!

Andi


Nov 13 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
2252
by: kea | last post by:
I have a checkbox and a textbox in a continuous taborder on a form along with a bunch of other controls. The textbox is disabled. When I leave the checkbox I want to enable the textbox and move the focus to it (only if the checkbox.checked=true). So on the checkbox Leave-event i do the following: if checkbox.checked=true then textbox.enabled = true end if
1
4435
by: @ndy | last post by:
Hi developers, i've a problem with my tabcontrol. Before i open my form with a tabcontrol with 3 tabs (Frm_Files|Frm_Lines|Frm_Guarantee) all the controls on al the tabs must be enabled. With the next code only the controls on the active form are enabled. For Each ctl In Me.Controls Select Case ctl.ControlType
6
7739
by: Stu Carter | last post by:
Hi, I have an aspx page where some controls are initially disabled by the code-behind 'Page_Load' event. I want these controls to be dynamically enabled when the user checks a checkbox. Because I don't want a post-back, I added some javascript to do this However, using client-side JS, I cannot enable any controls that have been disabled by server-side code. If the control is initially enabled, I can disable/enable it client-side.
2
3157
by: david.boone | last post by:
Hello, I am trying to enable controls based on the value of a checkbox, i.e. if value = true then enable. I have a tab control form with controls on 4 tabs. I have some code (below) on the tab control "on change" event. This works for the 'first tab' but then does not work for any other tab.
2
2504
by: Scott Emick | last post by:
I cannot remember how to enable the vertical scrollbar in my textbox for which I've added combobox controls to dynamically. I have the vertical scrollbar turned on, but it is greyed out and I cannot remember how to 'enable' it. Thanks -- Scott Emick
2
2313
by: xazos79 | last post by:
Hi All, I've come across the problem of not being able to re-enable a radio button with javascript if its initial state has been disabled in the Page_Load() method of the code behind. Might i add that it behaves fine in Firefox, but IE is unable to re-enable the radio button. IE is fine if the radio button starts in an enabled state.
1
2716
by: Francois Stander | last post by:
Hope someone could help. I read all the controls on a page using the following statement: For i = 0 To Page.Form.Controls.Count - 1 try Page.Form.Controls.Item(i).Visible = False ' here I would not like to set the property to "visible" to false. 'I would rather set the enable property to false Catch
3
2649
AccessIdiot
by: AccessIdiot | last post by:
I was successful with help from another thread (this one ) in enabling and disabling a form/subform with a button. Essentially you press a button on the form and the form controls are disabled but the subform is enabled. Then there is a button on the subform that re-enables the form controls and disables the subform. This works wonderfully but now I've got two subforms. I need the new subform to disable when the form controls are disabled and...
5
3008
by: Dan Tallent | last post by:
I have a scenerio when my forms are first opened that the user cannot modify the data. The fields are disabled to prevent them from modifying any of the data. If a user wishes to modify the data he would be required to click a "Edit" button which will test permissions or status information of the record. If the application determines it is ok for the user to modify the data, it enables the fields where the user now can make changes as...
0
8761
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
9200
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8148
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6722
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6022
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4525
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4795
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3238
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2680
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.