problem changing the forecolour

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

im trying to modify the forecolour of a single box in a data sheet but it
wont change. i have tried:
quantity.forcolour = rgb(255,0,0)
but nothing happens.
then i added:
me.repaint
and
DoCmd.RepaintObject
but still nothing.
any ideas, thanks
 
As far as I am aware I don't think you can with a datasheet. You can make it
a continuous form and change the formatting so it looks like a datasheet.
 
thanks thats a really good idea, ive tried doing it but im unsure of the
syntax.

Dim rs0 As New ADODB.Recordset

rs0.Open "SELECT Product.ProductWeight,
ProductOrder.ProductOrderUnitQuantity " & _
"FROM Product INNER JOIN ProductOrder ON Product.[ProductID] =
ProductOrder.[ProductID] " & _
"WHERE ProductOrder.OrderID=91", CurrentProject.Connection,
adOpenStatic, adLockOptimistic

Weight = DSum("[ProductWeight]*[ProductOrderUnitQuantity]", rs0)
rs0.Close

im sure the problem is with rs0 but i dont know how to fix it.
thanks for any help
 
I haven't a clue what that syntax is and why need it!

What do you mean by "forecolor" (daft question maybe)



--
www.ae911truth.org



andy stanford-jason said:
thanks thats a really good idea, ive tried doing it but im unsure of the
syntax.

Dim rs0 As New ADODB.Recordset

rs0.Open "SELECT Product.ProductWeight,
ProductOrder.ProductOrderUnitQuantity " & _
"FROM Product INNER JOIN ProductOrder ON Product.[ProductID] =
ProductOrder.[ProductID] " & _
"WHERE ProductOrder.OrderID=91", CurrentProject.Connection,
adOpenStatic, adLockOptimistic

Weight = DSum("[ProductWeight]*[ProductOrderUnitQuantity]", rs0)
rs0.Close

im sure the problem is with rs0 but i dont know how to fix it.
thanks for any help
scubadiver said:
As far as I am aware I don't think you can with a datasheet. You can make it
a continuous form and change the formatting so it looks like a datasheet.
 
Forecolor is the font color. There may be an exception or two in which it
is something other than font color, but I can't recall offhand. I believe
you are correct about formatting in datasheet view.
Andy, I can't figure out why you provided that code in response to the
suggestion to use Continuous form view. At least, that's the sequence I see
from here. Where is this code run, and what is it intended to do?

scubadiver said:
I haven't a clue what that syntax is and why need it!

What do you mean by "forecolor" (daft question maybe)



--
www.ae911truth.org



andy stanford-jason said:
thanks thats a really good idea, ive tried doing it but im unsure of the
syntax.

Dim rs0 As New ADODB.Recordset

rs0.Open "SELECT Product.ProductWeight,
ProductOrder.ProductOrderUnitQuantity " & _
"FROM Product INNER JOIN ProductOrder ON Product.[ProductID]
=
ProductOrder.[ProductID] " & _
"WHERE ProductOrder.OrderID=91", CurrentProject.Connection,
adOpenStatic, adLockOptimistic

Weight = DSum("[ProductWeight]*[ProductOrderUnitQuantity]", rs0)
rs0.Close

im sure the problem is with rs0 but i dont know how to fix it.
thanks for any help
scubadiver said:
As far as I am aware I don't think you can with a datasheet. You can
make it
a continuous form and change the formatting so it looks like a
datasheet.

--
www.ae911truth.org



:

im trying to modify the forecolour of a single box in a data sheet
but it
wont change. i have tried:
quantity.forcolour = rgb(255,0,0)
but nothing happens.
then i added:
me.repaint
and
DoCmd.RepaintObject
but still nothing.
any ideas, thanks
 
There is an Access menu item to change the font, which
allows you to change the font color, so at worst you could
automate that, but I am almost sure that most of what you
can do through the Access built in menus, you can also
do with DoCmd.

But note that the menu structure changes with major
version changes.

(david)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top