More than 6 conditional Formats....VBA Coding Advise please

If I have a range of cells A1:M20
Column K has a validation list with 6 Options....Yes, No, W, X, Y, Z

The conditional formatting is limited to 3 conditions.

Can anyone provide code that would permit the colour of the cells in each 
row in the range A1 to M20 when the appropriate option is selected from the 
relevant cell in column K.

I.E. I want Row range A1:M1 cells to change to say Yellow when "Yes" 
selected from the list in K1 ......or say red if  "No" ( and other colours 
for W,X Y,Z)

An example of the coding would be appreciated , if it's possible?
Thanks

0
Dermot (50)
1/6/2006 1:06:02 AM
excel.newusers 15348 articles. 2 followers. Follow

8 Replies
629 Views

Similar Articles

[PageSpeed] 9

Take a look at this link

http://www.excelforum.com/showthread.php?t=497871


-- 
keithl816
------------------------------------------------------------------------
keithl816's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=21287
View this thread: http://www.excelforum.com/showthread.php?threadid=498558

0
1/6/2006 3:03:09 AM
Hi Dermot

If i understand your question correctly then the following code should do 
what you want (you'll have to edit the colours as required).
--------------------
Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo Err_Handler

    If Not Intersect(Target, Range("K1:K20")) Is Nothing Then
        Application.EnableEvents = False
        i = Target.Row
        Select Case Target.Value
            Case "Yes"
                Range("A" & i & ":M" & i).Interior.ColorIndex = 6
            Case "No"
                Range("A" & i & ":M" & i).Interior.ColorIndex = 12
            Case "W"
                Range("A" & i & ":M" & i).Interior.ColorIndex = 18
            Case "X"
                Range("A" & i & ":M" & i).Interior.ColorIndex = 22
            Case "Y"
                Range("A" & i & ":M" & i).Interior.ColorIndex = 26
            Case "Z"
                Range("A" & i & ":M" & i).Interior.ColorIndex = 30
            Case Else
                Range("A" & i & ":M" & i).Interior.ColorIndex = xlNone
        End Select
    End If

Err_Handler:
    Application.EnableEvents = True
End Sub

--
note, this needs to go on the sheet module of where your range is (right 
mouse click on the appropriate sheet tab and choose view / code ... copy & 
paste the code in there).

hope this helps.

-- 
Cheers
JulieD


julied_ng  at hctsReMoVeThIs dot net dot au


"Dermot" wrote:

> If I have a range of cells A1:M20
> Column K has a validation list with 6 Options....Yes, No, W, X, Y, Z
> 
> The conditional formatting is limited to 3 conditions.
> 
> Can anyone provide code that would permit the colour of the cells in each 
> row in the range A1 to M20 when the appropriate option is selected from the 
> relevant cell in column K.
> 
> I.E. I want Row range A1:M1 cells to change to say Yellow when "Yes" 
> selected from the list in K1 ......or say red if  "No" ( and other colours 
> for W,X Y,Z)
> 
> An example of the coding would be appreciated , if it's possible?
> Thanks
> 
0
julied (23)
1/6/2006 3:09:02 AM
Hi Julie,
This is great.
I had found a case select code else where, but wasn't too sure how to edit 
to the "Yes" etc conditions that I would like to use.
I am reading through the Susann Novalis VBA book which is great, but this 
code is more advanced than the level I am at.
Can you  suggest any other VBA learning sources for Excel?
Thanks again
Dermot

"JulieD" wrote:

> Hi Dermot
> 
> If i understand your question correctly then the following code should do 
> what you want (you'll have to edit the colours as required).
> --------------------
> Private Sub Worksheet_Change(ByVal Target As Range)
> On Error GoTo Err_Handler
> 
>     If Not Intersect(Target, Range("K1:K20")) Is Nothing Then
>         Application.EnableEvents = False
>         i = Target.Row
>         Select Case Target.Value
>             Case "Yes"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 6
>             Case "No"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 12
>             Case "W"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 18
>             Case "X"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 22
>             Case "Y"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 26
>             Case "Z"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 30
>             Case Else
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = xlNone
>         End Select
>     End If
> 
> Err_Handler:
>     Application.EnableEvents = True
> End Sub
> 
> --
> note, this needs to go on the sheet module of where your range is (right 
> mouse click on the appropriate sheet tab and choose view / code ... copy & 
> paste the code in there).
> 
> hope this helps.
> 
> -- 
> Cheers
> JulieD
> 
> 
> julied_ng  at hctsReMoVeThIs dot net dot au
> 
> 
> "Dermot" wrote:
> 
> > If I have a range of cells A1:M20
> > Column K has a validation list with 6 Options....Yes, No, W, X, Y, Z
> > 
> > The conditional formatting is limited to 3 conditions.
> > 
> > Can anyone provide code that would permit the colour of the cells in each 
> > row in the range A1 to M20 when the appropriate option is selected from the 
> > relevant cell in column K.
> > 
> > I.E. I want Row range A1:M1 cells to change to say Yellow when "Yes" 
> > selected from the list in K1 ......or say red if  "No" ( and other colours 
> > for W,X Y,Z)
> > 
> > An example of the coding would be appreciated , if it's possible?
> > Thanks
> > 
0
Dermot (50)
1/6/2006 5:51:02 PM
Thanks for the link Keith.
Interesting stuff
Thanks

"keithl816" wrote:

> 
> Take a look at this link
> 
> http://www.excelforum.com/showthread.php?t=497871
> 
> 
> -- 
> keithl816
> ------------------------------------------------------------------------
> keithl816's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=21287
> View this thread: http://www.excelforum.com/showthread.php?threadid=498558
> 
> 
0
Dermot (50)
1/6/2006 6:16:04 PM
Hi Julie,
What line of code would I add to remove the colour formatting to it's 
original blank appearance with no text within a row.......assumming I 
included an option in the validation list  "Undo"?
Thanks
Dermot

"JulieD" wrote:

> Hi Dermot
> 
> If i understand your question correctly then the following code should do 
> what you want (you'll have to edit the colours as required).
> --------------------
> Private Sub Worksheet_Change(ByVal Target As Range)
> On Error GoTo Err_Handler
> 
>     If Not Intersect(Target, Range("K1:K20")) Is Nothing Then
>         Application.EnableEvents = False
>         i = Target.Row
>         Select Case Target.Value
>             Case "Yes"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 6
>             Case "No"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 12
>             Case "W"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 18
>             Case "X"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 22
>             Case "Y"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 26
>             Case "Z"
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = 30
>             Case Else
>                 Range("A" & i & ":M" & i).Interior.ColorIndex = xlNone
>         End Select
>     End If
> 
> Err_Handler:
>     Application.EnableEvents = True
> End Sub
> 
> --
> note, this needs to go on the sheet module of where your range is (right 
> mouse click on the appropriate sheet tab and choose view / code ... copy & 
> paste the code in there).
> 
> hope this helps.
> 
> -- 
> Cheers
> JulieD
> 
> 
> julied_ng  at hctsReMoVeThIs dot net dot au
> 
> 
> "Dermot" wrote:
> 
> > If I have a range of cells A1:M20
> > Column K has a validation list with 6 Options....Yes, No, W, X, Y, Z
> > 
> > The conditional formatting is limited to 3 conditions.
> > 
> > Can anyone provide code that would permit the colour of the cells in each 
> > row in the range A1 to M20 when the appropriate option is selected from the 
> > relevant cell in column K.
> > 
> > I.E. I want Row range A1:M1 cells to change to say Yellow when "Yes" 
> > selected from the list in K1 ......or say red if  "No" ( and other colours 
> > for W,X Y,Z)
> > 
> > An example of the coding would be appreciated , if it's possible?
> > Thanks
> > 
0
Dermot (50)
1/8/2006 9:20:02 PM
foramt menu-conditional formatting-delete-option 1-ok



"Dermot" <Dermot@discussions.microsoft.com> wrote in message
news:42241FC8-A573-4228-9EFC-89D310FC5E07@microsoft.com...
> Hi Julie,
> What line of code would I add to remove the colour formatting to it's
> original blank appearance with no text within a row.......assumming I
> included an option in the validation list  "Undo"?
> Thanks
> Dermot
>
> "JulieD" wrote:
>
> > Hi Dermot
> >
> > If i understand your question correctly then the following code should
do
> > what you want (you'll have to edit the colours as required).
> > --------------------
> > Private Sub Worksheet_Change(ByVal Target As Range)
> > On Error GoTo Err_Handler
> >
> >     If Not Intersect(Target, Range("K1:K20")) Is Nothing Then
> >         Application.EnableEvents = False
> >         i = Target.Row
> >         Select Case Target.Value
> >             Case "Yes"
> >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 6
> >             Case "No"
> >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 12
> >             Case "W"
> >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 18
> >             Case "X"
> >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 22
> >             Case "Y"
> >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 26
> >             Case "Z"
> >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 30
> >             Case Else
> >                 Range("A" & i & ":M" & i).Interior.ColorIndex = xlNone
> >         End Select
> >     End If
> >
> > Err_Handler:
> >     Application.EnableEvents = True
> > End Sub
> >
> > --
> > note, this needs to go on the sheet module of where your range is (right
> > mouse click on the appropriate sheet tab and choose view / code ... copy
&
> > paste the code in there).
> >
> > hope this helps.
> >
> > --
> > Cheers
> > JulieD
> >
> >
> > julied_ng  at hctsReMoVeThIs dot net dot au
> >
> >
> > "Dermot" wrote:
> >
> > > If I have a range of cells A1:M20
> > > Column K has a validation list with 6 Options....Yes, No, W, X, Y, Z
> > >
> > > The conditional formatting is limited to 3 conditions.
> > >
> > > Can anyone provide code that would permit the colour of the cells in
each
> > > row in the range A1 to M20 when the appropriate option is selected
from the
> > > relevant cell in column K.
> > >
> > > I.E. I want Row range A1:M1 cells to change to say Yellow when "Yes"
> > > selected from the list in K1 ......or say red if  "No" ( and other
colours
> > > for W,X Y,Z)
> > >
> > > An example of the coding would be appreciated , if it's possible?
> > > Thanks
> > >


0
R
1/9/2006 2:46:58 AM
Thanks for the reply R.VENKATARAMAN
Please advise....
Wouldn't this just delete conditional formating condition 1?
I am looking to include an option in the validation list to clear the 
formatting carried out by the code......I don't want to pemanently remove any 
formatting.
Thanks

"" wrote:

> foramt menu-conditional formatting-delete-option 1-ok
> 
> 
> 
> "Dermot" <Dermot@discussions.microsoft.com> wrote in message
> news:42241FC8-A573-4228-9EFC-89D310FC5E07@microsoft.com...
> > Hi Julie,
> > What line of code would I add to remove the colour formatting to it's
> > original blank appearance with no text within a row.......assumming I
> > included an option in the validation list  "Undo"?
> > Thanks
> > Dermot
> >
> > "JulieD" wrote:
> >
> > > Hi Dermot
> > >
> > > If i understand your question correctly then the following code should
> do
> > > what you want (you'll have to edit the colours as required).
> > > --------------------
> > > Private Sub Worksheet_Change(ByVal Target As Range)
> > > On Error GoTo Err_Handler
> > >
> > >     If Not Intersect(Target, Range("K1:K20")) Is Nothing Then
> > >         Application.EnableEvents = False
> > >         i = Target.Row
> > >         Select Case Target.Value
> > >             Case "Yes"
> > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 6
> > >             Case "No"
> > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 12
> > >             Case "W"
> > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 18
> > >             Case "X"
> > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 22
> > >             Case "Y"
> > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 26
> > >             Case "Z"
> > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 30
> > >             Case Else
> > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = xlNone
> > >         End Select
> > >     End If
> > >
> > > Err_Handler:
> > >     Application.EnableEvents = True
> > > End Sub
> > >
> > > --
> > > note, this needs to go on the sheet module of where your range is (right
> > > mouse click on the appropriate sheet tab and choose view / code ... copy
> &
> > > paste the code in there).
> > >
> > > hope this helps.
> > >
> > > --
> > > Cheers
> > > JulieD
> > >
> > >
> > > julied_ng  at hctsReMoVeThIs dot net dot au
> > >
> > >
> > > "Dermot" wrote:
> > >
> > > > If I have a range of cells A1:M20
> > > > Column K has a validation list with 6 Options....Yes, No, W, X, Y, Z
> > > >
> > > > The conditional formatting is limited to 3 conditions.
> > > >
> > > > Can anyone provide code that would permit the colour of the cells in
> each
> > > > row in the range A1 to M20 when the appropriate option is selected
> from the
> > > > relevant cell in column K.
> > > >
> > > > I.E. I want Row range A1:M1 cells to change to say Yellow when "Yes"
> > > > selected from the list in K1 ......or say red if  "No" ( and other
> colours
> > > > for W,X Y,Z)
> > > >
> > > > An example of the coding would be appreciated , if it's possible?
> > > > Thanks
> > > >
> 
> 
> 
0
Dermot (50)
1/9/2006 9:30:01 AM
iam avaguely thinking
you can have two command buttons
one will have the code

Selection.FormatConditions.Delete
    Selection.FormatConditions.Add Type:=xlCellValue, Operator:=xlGreater, _
        Formula1:="5"
    Selection.FormatConditions(1).Font.ColorIndex = 46

anohter button will have the code

Selection.FormatConditions.Delete

try somethin like that .  insted of command buttons you can even have two
option button

"Dermot" <Dermot@discussions.microsoft.com> wrote in message
news:C9B51E82-8E34-4D2F-A62E-06FC0FE0AF57@microsoft.com...
> Thanks for the reply R.VENKATARAMAN
> Please advise....
> Wouldn't this just delete conditional formating condition 1?
> I am looking to include an option in the validation list to clear the
> formatting carried out by the code......I don't want to pemanently remove
any
> formatting.
> Thanks
>
> "" wrote:
>
> > foramt menu-conditional formatting-delete-option 1-ok
> >
> >
> >
> > "Dermot" <Dermot@discussions.microsoft.com> wrote in message
> > news:42241FC8-A573-4228-9EFC-89D310FC5E07@microsoft.com...
> > > Hi Julie,
> > > What line of code would I add to remove the colour formatting to it's
> > > original blank appearance with no text within a row.......assumming I
> > > included an option in the validation list  "Undo"?
> > > Thanks
> > > Dermot
> > >
> > > "JulieD" wrote:
> > >
> > > > Hi Dermot
> > > >
> > > > If i understand your question correctly then the following code
should
> > do
> > > > what you want (you'll have to edit the colours as required).
> > > > --------------------
> > > > Private Sub Worksheet_Change(ByVal Target As Range)
> > > > On Error GoTo Err_Handler
> > > >
> > > >     If Not Intersect(Target, Range("K1:K20")) Is Nothing Then
> > > >         Application.EnableEvents = False
> > > >         i = Target.Row
> > > >         Select Case Target.Value
> > > >             Case "Yes"
> > > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 6
> > > >             Case "No"
> > > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 12
> > > >             Case "W"
> > > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 18
> > > >             Case "X"
> > > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 22
> > > >             Case "Y"
> > > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 26
> > > >             Case "Z"
> > > >                 Range("A" & i & ":M" & i).Interior.ColorIndex = 30
> > > >             Case Else
> > > >                 Range("A" & i & ":M" & i).Interior.ColorIndex =
xlNone
> > > >         End Select
> > > >     End If
> > > >
> > > > Err_Handler:
> > > >     Application.EnableEvents = True
> > > > End Sub
> > > >
> > > > --
> > > > note, this needs to go on the sheet module of where your range is
(right
> > > > mouse click on the appropriate sheet tab and choose view / code ...
copy
> > &
> > > > paste the code in there).
> > > >
> > > > hope this helps.
> > > >
> > > > --
> > > > Cheers
> > > > JulieD
> > > >
> > > >
> > > > julied_ng  at hctsReMoVeThIs dot net dot au
> > > >
> > > >
> > > > "Dermot" wrote:
> > > >
> > > > > If I have a range of cells A1:M20
> > > > > Column K has a validation list with 6 Options....Yes, No, W, X, Y,
Z
> > > > >
> > > > > The conditional formatting is limited to 3 conditions.
> > > > >
> > > > > Can anyone provide code that would permit the colour of the cells
in
> > each
> > > > > row in the range A1 to M20 when the appropriate option is selected
> > from the
> > > > > relevant cell in column K.
> > > > >
> > > > > I.E. I want Row range A1:M1 cells to change to say Yellow when
"Yes"
> > > > > selected from the list in K1 ......or say red if  "No" ( and other
> > colours
> > > > > for W,X Y,Z)
> > > > >
> > > > > An example of the coding would be appreciated , if it's possible?
> > > > > Thanks
> > > > >
> >
> >
> >


0
R
1/9/2006 12:38:36 PM
Reply:

Similar Artilces:

VC++ 6.0 class wizard
Hi everybody, I have a rather strange problem with VC++ 6.0. In my workspace I have 4 projects. (main exe, zip compression library, 2 language dlls). The language dlls were added yesterday. Before this everything worked normal. Now I want to add new classes to my main project, but if I select the class wizard, only one of the language dll projects is shown in the "project" combo box. What happened to my workspace an what can I do to solve this problem? Thanks, Chris Delete the .clw and .ncb files and then try recreate the classes. -- Vipin Aravind MVP "the.chris"...

How do I split one cell of 6 numbers into two cells of 3 and 3?
I have a column of data that has six numbers in each cell, however I need to split this into two columns, where the first column is the first three digits and the second column is the last three. There is no separator (space, comma or dash) between the numbers. Any suggestions? Use Text To Columns. Select your column of data, then: <Data> <TextToColumns> Click "Fixed Width", then <Next>, Click in the data to display the "break line", and drag it to separate the numbers as desired. Then <Finish> -- HTH, RD =================================...

Number formatting in chart
The secondary axis in my chart is dollar value. It is showing in thousands, which is what I want, but the data labels I would like it to show 177 only, for example, instead of 177,883. It would be understood that the labels are in thousands. Is this possible? Connie Okay, I guess I didn't make myself very clear. I will try to take a different approach. How do I customize the format of numbers in a column so that it rounds 177,883 to 178? Connie "Connie Martin" wrote: > The secondary axis in my chart is dollar value. It is showing in thousands, > which is ...

Intelligent Message Filter #6
Does the IMF support russian language? Hi Sergei, Unfortunately, no. The following languages are available for the IMF: Chinese (Simpl. and Trad.) English French German Italian Japanese Korean Spanish See http://www.microsoft.com/downloads/details.aspx?FamilyId=C1B08F7B-8CAF-4147-B074-8C9C8F277071&displaylang=en for more information. -- Scott Schnoll Microsoft This posting is provided "AS IS" with no warranties, and confers no rights. Please do not send email directly to this alias. This alias is for newsgroup purposes only. "Sergei" <serega@nsx.ru> w...

custom formatting cells in excel
I have a cell with general formatting which contain the value 1 3/4#. Is it possible to format another cell to display only 1 3/4 in numeric format? Thanks. You could use: =--SUBSTITUTE(A1,"#","") Then format that cell the way you want. "cklongacre@pa.net" wrote: > > I have a cell with general formatting which contain the value 1 3/4#. > Is it possible to format another cell to display only 1 3/4 in numeric > format? Thanks. -- Dave Peterson ...

How to 'convert' photos saved in .doc format?
Version: 2008 Operating System: Mac OS X 10.6 (Snow Leopard) Processor: Intel My first post here - please be patient. I'm helping a friend who has just converted from her PC to a shiny new iMac and I've struck a problem that I don't know how to resolve. On her PC she saved many (hundreds) of photos in .doc format (don't ask)! She thought that was how to do it. She's adamant that she needs to keep all these images. <br><br>I've never faced the problem before and don't seem to be able to find any way of converting the .doc formatted pictures to e....

Outlook express 6 not default email client for Internet Explorer 6?
There is no option in Internet Explorer 6 in the programs tab under internet options to support outlook express 6 it only gives the standard Microsoft Outlook and in the newsgroups section it gives an option to support outlook express.....need help want to send links directly with outlook express using the mail icon in internet explorer 6. ...

New History Item, Mail Message sends all messages as Rich Text Format
We are using Business Contact Manager 2007 with Outlook 2007. We are not using Exchange server as a backend, just plain old pop3/smtp mail servers. Problem we are having is when we open up an account, Click on New History Item, Mail Message, and if we send an attachment with that, the person that receives the message gets it in Rich Text format. If we right click on the Email address itself and click on Send Mail. The message will be sent out fine. Right click on the message and looking at the properties of the email address has the internet format listed as "Let Outlook decide the ...

How do I have Bar Codes appear in Excel?
I am creating an inventory spreadsheet for my workplace. I wanted to list the products as well as list their respective UPC/Bar codes. I am not sure how make them appear as the actual bar codes. Max See this, Max: http://www.officearticles.com/misc/fonts_and_barcodes_in_microsoft_office.htm ************ Anne Troy www.OfficeArticles.com "Max" <Max@discussions.microsoft.com> wrote in message news:70974265-E468-4D8A-9946-53EF8ACA1329@microsoft.com... >I am creating an inventory spreadsheet for my workplace. I wanted to list > the products as well as list their respe...

Writing Text File with code UTF-8
Hello Does somebody know how to write a Text File with code UTF-8 from Dexterity? I know that are 3 functions to write text files: TextFile_Writeline() TextFile_WriteDOS() TextFile_WriteText() But there is not therein a parameter to achieve text file be written with code UTF-8. I=92ll appreciate your guide. Best regards. ------=_NextPart_0001_A41C49B3 Content-Type: text/plain Content-Transfer-Encoding: 7bit Dexterity does not support double byte or unicode. You might need to use COM or win32 dll calls to get the OS to write the file for you. The difference between WriteLine and WriteDOS i...

Adobe 6.0 Standard
Suddenly Adobe 6.0 was not saving Word, Excel, PPT in PDF. I re-installed it. Word and PPT are OK but I am unable to save Excel in PDF. Word and PPT have Adobe icons but Excel does not. Most grateful, Paul Make sure the PDFMAKER.XLA file is in your XLStart folder. For instance, the XLStart folder in Office XP is "C:\Program Files\Microsoft Office\Office10\XLStart". Paul Banerjee wrote: > Suddenly Adobe 6.0 was not saving Word, Excel, PPT in PDF. I re-installed it. > Word and PPT are OK but I am unable to save Excel in PDF. Word and PPT have > Adobe icons but Ex...

SMTP #6
There was a SMTP communication problem with the recipient's email server that domain isn't in my list of allowed rcpthosts (#5.7.1)> ...

Formatting Pages
I would like to print the data on a sheet in the landscape view, but the page numbering in the top right corner with the number rotated like the portrait view. This is so I can bind my data tables in a book with the numbers in the top right corners like a normal book. Thank you. Carolyn Permission granted <g> View>Header and Footer>Custom header>Upper right>*click the # icon a space, then the ### icon. This will cause Page n of n Pages to appear on the preview and hard copy. -- Greeting from the Gulf Coast! http://myweb.cableone.net/twodays "Carolyn" <cda...

conversion from managed to unmanaged code
Hi All, I am trying to port our code from unmanaged to managed code. The way we do is to wrap unmanaged objects into new managed classes. I am having a problem converting managed pointers to unmanaged ones... e.g func (ICrap * x) // x is managed { Crap __pin * y = x; // Crap is a unmanaged abstract clas and conversion does not work. } Can someone pls help me out.. Thanks Ashhish Take a look at the #pragma managed/unmanaged preprocessor directives. http://msdn.microsoft.com/library/en-us/vclang/html/vcerrManagedUnmanaged.as p -- Cheers Check Abdoul [ VC++ MVP ] -------...

Outlook & IMAP format
Will Outlook in the forseeable future support this format for E mail. Outlook Express supports this but Outlook doesn't and it is the superior product ...

How can I show U.S. country code (+1) in my contacts?
I've moved to Italy, and would like to have the U.S. country code show in my Outlook contacts (as the code for other countries currently does). I've changed my default location in the Windows 7 control panel, but this hasn't had the desired result. Any option settings I'm missing? Which location did you set, and to what? Did you enable the option to automatically add country code to your Contacts? -- Russ Valentine "Matt D." <Matt D.@discussions.microsoft.com> wrote in message news:709C5A1B-F303-498B-846E-AF0DD7B968F8@microsoft.com... > I&#...

C# callback from native code
Hello, There's an example in .Net docs where C# delegate is called by native code ( EnumWindows - http://msdn.microsoft.com/en-us/library/d186xcf0(v=VS.71).aspx ). The doc states: >>>PASTE>>>>>>> 4.Ensure that the garbage collector does not reclaim the delegate before the callback function completes its work. When you pass a delegate as a parameter, or pass a delegate contained as a field in a structure, it remains uncollected for the duration of the call. So, as is the case in the following enumeration example, the callback function comp...

Text box set to memo vs. Lines Coded on a report
I have a report which looks like a legal pad with lines. 24 actual spaces. The number of lines can not change. I have duplicated a form from Excel to eliminate using it altogether. So it looks just like the Excel Report. I coded the lines into the report. I am using a text box with data type set to memo. I have several issues. 1. If the data entered into the textbox from my form fits in to the text box on one line, then there is no problem. I can just move the page footer to more or less the right position to allow it to fit inside the coded lines. (It is not exact, but close...

Pivot Table - Grouped Dates
Hi All, I have a grouped pivot by date. Works fine except for the format of the date doesn't allow sorting in the way that I need. The data has the dates in the format: 4/17/2006 14:21 After grouping in the pivot on that field by day (to remove the time portion) I get: 10-Apr Sorting the pivot gives: 10-Apr 10-Mar 11-Apr 12-Apr 13-Apr 13-Mar 14-Apr 14-Mar 15-Apr 15-Mar 16-Mar 17-Apr Rather than by year/month/day. I tried changing the field format in the pivot and it doesn't do anything at all to how the format in the pivot looks? I need the pivot data to sort as actual day...

Please HLEP: whats wrong with my code!? Adding textbox as runtime
Hi All, I want to add textboxes at runtime based on what user inputs in a textbo. For eg: I have a textbox "Total Students" , so Once I input a number in that textbox, I want to have that many textboxes on the form during run time. If I input 4 I want four textboxes to be displayed on the form. Here is my code that I have so far. Private Sub TextBox1_AfterUpdate() Dim cCntrl As Control, Dim i as integer i = 1 For i = 1 To 10 If Me.TextBox1.Value = i Then With Frame14 Set cCntrl = Me.Controls.Add("Forms.TextBox.1", &quo...

Conditional formatting #131
Hi I’m working with a spreadsheet control, and I realize that lot’s of the vbscript programming is like excel programming. Well spreadsheet control does not support conditional formatting, so to go around this problem I tried a couple of codes but I had no look. What I’m trying to do is change the font color of a cell if the result of a formula is less then 0. thanks. Manually select cell A1 and pull-down Format > Conditional Formatting and select: Cell is less than 0 and apply your format. The Macro Recodred can capture this: Sub Macro1() Range("A1").Select...

Blank e-mails in outlook express 6
I have a friend using outlook express 6 with ie8 using win xp home edition sp2. ISP is bell sympatico high speed internet using bell sympatico security suite for anti virus, firewall, spam, etc. Some of the incoming e-mails will show where they came from, but the actual message is blank. Any suggestions? You can pass this along, but if the machine is fully patched, this probably won't help. See this about possible fixes for messages appearing blank: www.oehelp.com/OETips.aspx#10 -- Bruce Hagen MS-MVP [Mail] Imperial Beach, CA &q...

HTML Source Code Question
In Publisher 98 or 2000 is there a way to view the HTML source code and then copy it into another document? Not within Publisher. It is not an html editor. Open the html files in Notepad or any text/html editor. -- David Bartosik - Microsoft MVP Visit www.davidbartosik.com for Publisher and Web Design Tips and How-to's. "Harvey" <hcohenREMOVE@eznet.THISnet> wrote in message news:0a3e62040b4377a8c82d327373486794@news.teranews.com... > In Publisher 98 or 2000 is there a way to view the HTML source code and then > copy it into another document? > > Harvey...

Stopping a formula once a condition has been met.
Cell A1 of my worksheet contains the following formula: ='[WTA Work History Overall.xlsx]Retirement Summary'!Retirement_Payment Cell A2 contains a date. Is there any way that the formula in cell A1 can be constructed so that once the date exceeds the date in cell A2 that the formula stops updating the value in cell A1 and just shows the value that was in place prior to exceeding the date in A2? A formula can only return a value so with something like the following: =IF(DATEVALUE("29/11/2009")>A1,"A1 expired",A1 If the date in A1 was before to...

Rounding up numbers in hh:mm:ss format
I have a columnn of numbers stored in the hh:mm:ss (custom) format. I need to round up all cells that have ss>0 an add 1 to mm; in other words all cells with seconds should be rounded up to the next minute. How can I do that? Cheers, Thorbjorn Hi try =ROUNDUP(A1*24*60,0)/(24*60) -- Regards Frank Kabel Frankfurt, Germany Thorbjorn Sundboe wrote: > I have a columnn of numbers stored in the hh:mm:ss (custom) format. I > need to round up all cells that have ss>0 an add 1 to mm; in other > words all cells with seconds should be rounded up to the next minute. > How can I do ...