使用VBA我们可以检查所有工作表中的字体测试(Arial) [英] Using VBA Can we check the Font Testing in all the sheets (Arial)

查看:306
本文介绍了使用VBA我们可以检查所有工作表中的字体测试(Arial)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

团队,



使用VBA我们可以检查所有工作表中的字体测试。



我们假设字体类型为 Arial

$
我需要创建一个包含两个表格的文件。



1)第一张



a)序列号号

b)文件路径(用于检查格式的Excel文件)



2)第二张



如果字体不是Arial。 我们必须跟踪文件名(我们应该从First Sheet Path Column获取),Cell Number(例如:C3),Cell Value。



这是可能的?
$


谢谢!



Kiran

Team,

Using VBA Can we check the Font Testing in all the sheets.

Let us Assume the Font Type is Arial.

I Need to create a File with Two Sheets.

1) First Sheet

a) Serial No
b) Path of the Files ( Excel Files to check the Format)

2) Second Sheet

If the Font is not Arial.  We have to track the File Name (that we should get it from First Sheet Path Column) , Cell Number (ex: C3), Cell Value.

Is that Possible?

Thanks!

Kiran

推荐答案

团队,



使用VBA我们可以检查所有工作表中的字体测试。



我们假设字体类型为 Arial



我需要创建一个包含两个表格的文件。



1)第一张



a)序列号号

b)文件路径(用于检查格式的Excel文件)



2)第二张



如果字体不是Arial。 我们必须跟踪文件名(我们应该从First Sheet Path Column获取),Cell Number(例如:C3),Cell Value。



这是可能的?



谢谢!



Kiran

Team,

Using VBA Can we check the Font Testing in all the sheets.

Let us Assume the Font Type is Arial.

I Need to create a File with Two Sheets.

1) First Sheet

a) Serial No
b) Path of the Files ( Excel Files to check the Format)

2) Second Sheet

If the Font is not Arial.  We have to track the File Name (that we should get it from First Sheet Path Column) , Cell Number (ex: C3), Cell Value.

Is that Possible?

Thanks!

Kiran

这对你有用

Sub CheckFont()
    Dim sh As Worksheet
    Dim i As Long, j As Long
    For Each sh In ThisWorkbook.Worksheets
        For i = 1 To sh.Range("A1").End(xlDown).Row
            For j = 1 To sh.Range("A1").End(xlToRight).Column
                If Not sh.Cells(i, j).Font.Name = "Arial" Then
                    Debug.Print ThisWorkbook.Name
                End If
            Next j
        Next i
    Next sh
End Sub


这篇关于使用VBA我们可以检查所有工作表中的字体测试(Arial)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆