Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Data check
Hi, I would check data table. There are 150 columns about 3600 rows. I
need to check if data field is missing value. If yes, so error message must be generated. Doesn't anybody know to help me with macro? Thanks Pavel |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Data check
Sub CheckData
Dim X as double Dim Y as double Dim ErrorData(50000,2) as variant Dim Fnd as double for X=1 to 3600 for Y=1 to 150 if cells(x,y).value=empty then Fnd=Fnd+1 ErrorData(Fnd,1)=X ErrorData(Fnd,2)=Y end if Next Next if Fnd0 then Dim MyEntries As String Workbooks.Add Template:="Workbook" MyEntries = ActiveWorkbook.Name Cells(1,1).value="Bad Row" Cells(1,2).value="Bad Col" for X=1 to Fnd cells(x+1,1)=ErrorData(X,1) cells(x+1,2)=ErrorData(x,2) Next End if 'then add code for printing or whatever.... End sub " wrote: Hi, I would check data table. There are 150 columns about 3600 rows. I need to check if data field is missing value. If yes, so error message must be generated. Doesn't anybody know to help me with macro? Thanks Pavel |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Data check
hi Pavel,
missing value means a blank cell? then try this macro: Sub GetBlankCells() On Error Resume Next Set rng = Range(ActiveSheet.UsedRange.Address). _ SpecialCells(xlCellTypeBlanks) If Err.Number 0 Then MsgBox "no blanks" Else MsgBox "blanks in " & rng.Address End If End Sub bye stefan On 20 Mai, 14:08, wrote: Hi, I would check data table. There are 150 columns about 3600 rows. I need to check if data field is missing value. If yes, so error message must be generated. Doesn't anybody know to help me with macro? Thanks Pavel |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How can I check/verify data in my Data Source for Pivot table? | Excel Worksheet Functions | |||
Data check | Excel Programming | |||
How can I check if data in an external data range is changed afte. | Excel Worksheet Functions | |||
How can I check if data in external data range is changed after re | Excel Discussion (Misc queries) | |||
data check | Excel Programming |