Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 99
Default How MerketCelle worked in VBA Formatting Cell

I have found a file in XLS Format.
It has code in VBA to format the cells based on the value of the
cells.
However, I couldn't find how the term MerketCelle worked in the cell.
So, I couldn't format the cells in some different ways then that was
done.
There are no references to the term in the file.
Also, in my notice, there is no such term in VB Library.
Help me.
Thanks in Advance.

Following is the code in the module of the file.

Option Explicit

Sub Auto_Open()
ThisWorkbook.Worksheets(1).OnEntry = "formatrange"
End Sub

Sub Auto_Close()
ThisWorkbook.Worksheets(1).OnEntry = ""
End Sub

Sub formatrange()
Dim c As Range
Application.ScreenUpdating = False
For Each c In Range("myrange")
If IsNumeric(c.Value) Then
If c.Value < 10 Then
' c.Style = "Bold"
' format cell
c.Style = "Normal"
ElseIf c.Value 0 Then
' normal formatting
' c.Style = "Merket"
c.Style = "MerketCelle"
Else
c.Style = "Normal"
End If
End If
Next c
End Sub
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,298
Default How MerketCelle worked in VBA Formatting Cell

whoever created the workbook added a new Style - look in FORMAT / STYLES
- with this name.


"Subodh" wrote:

I have found a file in XLS Format.
It has code in VBA to format the cells based on the value of the
cells.
However, I couldn't find how the term MerketCelle worked in the cell.
So, I couldn't format the cells in some different ways then that was
done.
There are no references to the term in the file.
Also, in my notice, there is no such term in VB Library.
Help me.
Thanks in Advance.

Following is the code in the module of the file.

Option Explicit

Sub Auto_Open()
ThisWorkbook.Worksheets(1).OnEntry = "formatrange"
End Sub

Sub Auto_Close()
ThisWorkbook.Worksheets(1).OnEntry = ""
End Sub

Sub formatrange()
Dim c As Range
Application.ScreenUpdating = False
For Each c In Range("myrange")
If IsNumeric(c.Value) Then
If c.Value < 10 Then
' c.Style = "Bold"
' format cell
c.Style = "Normal"
ElseIf c.Value 0 Then
' normal formatting
' c.Style = "Merket"
c.Style = "MerketCelle"
Else
c.Style = "Normal"
End If
End If
Next c
End Sub

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
Find formatting in text in cell, insert tags around formatting. CarlC Excel Programming 2 February 27th 08 09:26 PM
expanding custom formatting without removing existing cell formatting? Keith Excel Worksheet Functions 3 December 27th 06 01:54 PM
Can Excel turn % hrs worked/week put in a cell into a real number BaffledFloridaExcelUser Excel Worksheet Functions 1 August 2nd 05 11:21 PM
SUM cell shows only #####, worked before though. HELP??? KimChiDahl Excel Worksheet Functions 2 November 19th 04 09:21 PM


All times are GMT +1. The time now is 11:35 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"