Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default programatically color fonts and auto sorting

hi

I am currently doing a spreadsheet by excel.

I am thinking of 1 worksheet that holds all the data like a database.
Then in the other sheets are the sorted and processed sheets to show
data extracted.

Lets call my database "DATABASE" and first worksheet would be "Shipping
Schedule"

First problem:

for each row in Shipping Schedule worksheet, if under the REMARKS
column is a "shipped"
I would like to change the font of the whole row automatically to red
words.

Conditional formatting does not seem to work for me as it does not seem
to run for each row. I believe, I will need a loop to do this. Can
someone help me with this?

Problem 2:
when I open Shipping schedule, I like it to sort automatically by date
as well under columns call "Fty ETD", then "buyer Etd", then "price" in
order of priority.

this is because, our clerks will be typeing in data in the DATABASE
worksheet and when they click on Shipping Schedule worksheet, all the
info would be there and sorted automatically without doing it manually.

pls help. Thanks!

  #2   Report Post  
Posted to microsoft.public.excel.programming
jtp jtp is offline
external usenet poster
 
Posts: 1
Default programatically color fonts and auto sorting


I believe there is a way to setup conditional formatting to do this but
if you want the code for it, try this: (Assuming Column A has
non-blank cells and Column B is the Remarks column)

-Sub ConditionalFormatting()
Dim cell As Range

Set cell = Range("A1")

While cell < ""
If LCase(cell.Offset(0, 1).Value) = "shipped" Then
cell.EntireRow.Font.Color = vbRed
End If
Set cell = cell.Offset(1, 0)
Wend

End Sub-

Now for your filter, it would probably be easier for you to just record
a macro and set up the sort the way you want it since you kind of need
to know what the headings are for each column you want to sort by.
After recording it, place the code in the "Shipping Schedule" worksheet
object using this Subroutine:

-Sub Worksheet_Activate()

'The recorded macro

End Sub-

Hope this helps some,

Jason



hi

I am currently doing a spreadsheet by excel.

I am thinking of 1 worksheet that holds all the data like a database.
Then in the other sheets are the sorted and processed sheets to show
data extracted.

Lets call my database "DATABASE" and first worksheet would be
"Shipping
Schedule"

First problem:

for each row in Shipping Schedule worksheet, if under the REMARKS
column is a "shipped"
I would like to change the font of the whole row automatically to red
words.

Conditional formatting does not seem to work for me as it does not
seem
to run for each row. I believe, I will need a loop to do this. Can
someone help me with this?

Problem 2:
when I open Shipping schedule, I like it to sort automatically by date
as well under columns call "Fty ETD", then "buyer Etd", then "price"
in
order of priority.

this is because, our clerks will be typeing in data in the DATABASE
worksheet and when they click on Shipping Schedule worksheet, all the
info would be there and sorted automatically without doing it
manually.

pls help. Thanks!


--
jtp
------------------------------------------------------------------------
jtp's Profile: http://www.excelforum.com/member.php...o&userid=21132
View this thread: http://www.excelforum.com/showthread...hreadid=495882

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default programatically color fonts and auto sorting

hi Jason thanks a million let me try this out!! Merry Christmas ans
happy new year =)

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
Changing font color of protected cells programatically Nigel Excel Discussion (Misc queries) 6 September 13th 08 12:32 PM
Color changing of fonts by using the IF function sadat Excel Worksheet Functions 1 May 31st 07 08:55 AM
How can i color the fonts sanju Excel Worksheet Functions 2 November 11th 06 09:48 AM
How do I keep the color fonts in my cells when I use drop down? tanks Excel Worksheet Functions 1 February 9th 06 10:14 PM
Excel 2003 will not display color fonts or color fill cells DaveC Excel Worksheet Functions 1 April 11th 05 04:38 PM


All times are GMT +1. The time now is 07:23 AM.

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"