LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default DSO and Custom Properties

I assign a custom property to a file (a.xls); the property name is "Balance"
and its value is 123.45

In another file the following code does retrieve the 123.45:

Sub surface()
Dim FileName As String
Dim DSO As DSOFile.OleDocumentProperties
Set DSO = New DSOFile.OleDocumentProperties
FileName = "C:\a.xls"
DSO.Open sfilename:=FileName
MsgBox (DSO.CustomProperties.Count)
MsgBox (DSO.CustomProperties.Item("Balance").Value)
DSO.Close
End Sub

I would like to get the value without knowing the name; both:
MsgBox (DSO.CustomProperties.Item(1).Value)
and
MsgBox (DSO.CustomProperties.Item(1).Name)

fail. How can i get the name of the first custom property??

--
Gary''s Student - gsnu200723
 
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
Custom File Properties Ade Hodgetts Excel Discussion (Misc queries) 2 April 2nd 08 10:34 PM
Custom properties for worksheets Thelonious Monk Excel Programming 3 September 11th 06 03:00 AM
Custom File Properties jujuwillis Excel Discussion (Misc queries) 1 August 1st 05 04:18 PM
Worksheet Custom Properties Rich_z Excel Programming 6 June 29th 05 04:49 PM
Custom Properties DavidW[_2_] Excel Programming 9 July 1st 04 03:31 PM


All times are GMT +1. The time now is 03:41 AM.

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"