Label placed on top of Continuous SubForm

ARW17

Board Regular
Joined
Oct 31, 2016
Messages
109
I have a form that has a continuous subform showing historical data. There's a field in this continuous subform called Notes. When someone clicks there, I want to tell them that they cannot edit these. It's working right now, but my setup is that the message appears in the Form Header in a label box. Here's the code I'm using:

Private Sub NOTE_Click()

Forms!ENTRY_MONTHLY_CRED_HIST.InfoLabel.Visible = True
Forms!ENTRY_MONTHLY_CRED_HIST.InfoLabel.Caption = "Historical Credits cannot be edited. Contact the Analyst if you notice an error."

PauseFor 5
Forms!ENTRY_MONTHLY_CRED_HIST.InfoLabel.Visible = False

End Sub

Public Sub PauseFor(ByVal Period As Double)
Dim Start As Double
Start = Timer
While (Timer - Start) < Period
DoEvents
Wend
End Sub

I'd perfer to have the label on top of the subform itself to better get the user's attention. Is this possible? I've tried bringing the label to front and the subform to back. I've also tried anchoring the label, but it's always hidden behind the subform. Is there a solution or is this a limitation?
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
Why not use a message box instead? Or are you already but you're calling that a label? I can't see how a label can appear behind anything unless the form or report its on goes behind, and that can't happen on a main form or its subform.
 
Upvote 0
I was using a label so that the user didn't have to click ok to clear the message box. I could just flash a warning/explanation and then let it disappear after a few seconds.
 
Upvote 0
A message box has to be dismissed by the user. To have it disappear you'd need a form. To ensure it opens on top, set the popup property to yes.
You can set bubble help text for a control but most people find that lacking in performance. Is it not possible to disable this particular field (all instances of the field in a continuous form would be disabled regardless of what they hold)?
 
Upvote 0

Forum statistics

Threads
1,214,866
Messages
6,121,996
Members
449,060
Latest member
mtsheetz

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top