Change detail background colour on continuous form

marcuscoker

Registered User.
Local time
Today, 06:56
Joined
Sep 28, 2005
Messages
49
Hi

Was hoping that somebody would be able to help me with this. I have a continuous form showing all the records with a button that allows the user to click through and edit a particular record in the list. What I was hoping to do is change the colour of the detail background if a value of a particular record is 10.
I have used the following code on the onopen event

Dim mylength
mylength = Me.txtlength.Value & ""

If mylength = 10 Then
Me.Detail.BackColor = "0"
End If


This seems to see that the first record has a value of 10 and makes the whole detail black, whereas I just wanted the area between the two dividing lines to be black covering the record in question. If anybody can help with this that would be great.

Thanks

Marcus
 
Have look at OldSoftBoss' Post - you should be able to use this code to filter your selection and chnage the background colour......
 
Thanks for that
 
Hi

I gave that a try but it is not quite what I was trying to do. I just wanted to change the detail colour of the detail section on a continuous form if the value of a text boxx = 10. I used the conditional formatting and managed to change the colour of the textbox itself when the value was 10, but this didnt really help as the textbox in question will be visible=true

any ideas/help would be really appreciated

thanks

Marcus
 
Marcus:

You could add a large text box, and apply conditional formatting to it. The control source is whatever field has the value of 10. Use Format - "Send to Back" to make the large control the background of the form.
 

Users who are viewing this thread

Back
Top Bottom