Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Cells().value is null but I can see data

I am extracting data from a Excel sheet. It looks like a special form.

When I retrieve

Cells(row,col).value

I can get the Captions on the sheet but not the data in other cells.

I can see the data - I can see which cell it is in - How do I get hol
of it ?

I found this in one of the modules - is this how the data is hidden?

Public Declare Function FindFirstFile Lib "kernel32" Alia
"FindFirstFileA" _
(ByVal lpFileName As String, lpFindFileData As WIN32_FIND_DATA) A
Long

Public Type WIN32_FIND_DATA
dwFileAttributes As Long
ftCreationTime As FILETIME
ftLastAccessTime As FILETIME
ftLastWriteTime As FILETIME
nFileSizeHigh As Long
nFileSizeLow As Long
dwReserved0 As Long
dwReserved1 As Long
cFileName As String * 260
cAlternate As String * 14
End Type

Private Sub ShowFileInfo()
' This subroutine demonstrates the technique
Dim hFile As Long
Dim WFD As WIN32_FIND_DATA
Dim FullName As String
Dim Created As String
Dim LastWrite As String

' FullName is the path and filename
' Substitute any valid file and path
FullName = ActiveWorkbook.FullName
hFile = FindFirstFile(FullName, WFD)

If hFile 0 Then
Created = FileDate(WFD.ftCreationTime)
MsgBox "File Created: " & Created, vbInformation, FullName
Else
MsgBox "File not found.", vbCritical, FullName
End If
End Su

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Cells().value is null but I can see data

That code gets information about a file.

It is unclear what a caption on the sheet is versus data in cells.

--
Regards,
Tom Ogilvy


JohnEnnever wrote in message
...
I am extracting data from a Excel sheet. It looks like a special form.

When I retrieve

Cells(row,col).value

I can get the Captions on the sheet but not the data in other cells.

I can see the data - I can see which cell it is in - How do I get hold
of it ?

I found this in one of the modules - is this how the data is hidden?

Public Declare Function FindFirstFile Lib "kernel32" Alias
"FindFirstFileA" _
(ByVal lpFileName As String, lpFindFileData As WIN32_FIND_DATA) As
Long

Public Type WIN32_FIND_DATA
dwFileAttributes As Long
ftCreationTime As FILETIME
ftLastAccessTime As FILETIME
ftLastWriteTime As FILETIME
nFileSizeHigh As Long
nFileSizeLow As Long
dwReserved0 As Long
dwReserved1 As Long
cFileName As String * 260
cAlternate As String * 14
End Type

Private Sub ShowFileInfo()
' This subroutine demonstrates the technique
Dim hFile As Long
Dim WFD As WIN32_FIND_DATA
Dim FullName As String
Dim Created As String
Dim LastWrite As String

' FullName is the path and filename
' Substitute any valid file and path
FullName = ActiveWorkbook.FullName
hFile = FindFirstFile(FullName, WFD)

If hFile 0 Then
Created = FileDate(WFD.ftCreationTime)
MsgBox "File Created: " & Created, vbInformation, FullName
Else
MsgBox "File not found.", vbCritical, FullName
End If
End Sub


---
Message posted from http://www.ExcelForum.com/



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
Using NULL in shading cells Lenny Excel Worksheet Functions 2 April 9th 09 06:16 PM
Failed to save table attributes of (null) into (null). Luca Brasi Excel Discussion (Misc queries) 2 February 4th 09 04:30 PM
Generating blank or null cells that the Histogram Data Analysis tool will ignore [email protected] Excel Worksheet Functions 2 June 12th 07 09:13 PM
NULL Cells UnderCoverGuy Excel Worksheet Functions 4 October 31st 06 07:33 PM
How do I skip over null cells? Excel Dummy Excel Discussion (Misc queries) 4 January 3rd 06 01:13 PM


All times are GMT +1. The time now is 06:07 PM.

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"