Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Solution: dsofile.dll - Permission Denied

129 views
Skip to first unread message

jeolmeun

unread,
Feb 20, 2006, 12:36:20 AM2/20/06
to
Have you been trying to set SummaryInformation for files on Windows XP
with NTFS using dsofile.dll? Getting Error Number -2147217142 or
Err.Number = 70 messages when setting a SummaryProperties property?

I have been getting the error when the file does not have any Summary
fields set in the first place. If I go into the file's property Summary
tab and set a comment in the Comments and then try to set a
SummaryProperties property, it worked without error.

The problem seems to come from the dsofile.dll in the
CDsoSummaryProperties::GetPropertyFromList which is called from
CDsoSummaryProperties::WriteProperty method. When there are no
properties (or pitem) in the file's (ADS) SummaryInformation,
dsofile.dll doesn't seem to make a new item.

Solution: Email me for a debug build of the dsofile.dll file or get the
package which has the source from
http://support.microsoft.com/?id=224351 and change the
CDsoSummaryProperties::GetPropertyFromList to look something like
below.

Use at your own risk. (No warranties, no obligations, no liability, and
that other legal stuff.) I haven't tested it thoroughly since it has
been doing what I've been trying to do.

summprops.cpp - about line 733

////////////////////////////////////////////////////////////////////////
// GetPropertyFromList -- Enumerates a list and finds item with the
// matching id. It can also add a new item (if flag set).
//
STDMETHODIMP_(CDsoDocProperty*)
CDsoSummaryProperties::GetPropertyFromList(CDsoDocProperty* plist,
PROPID id, BOOL fAppendNew)
{
CDsoDocProperty* pitem = plist;
CDsoDocProperty* plast = pitem;

ODS("CDsoSummaryProperties::FindPropertyInList\n");

// Loop the list until you find the item...
while (pitem)
{
if (pitem->GetID() == id)
break;

plast = pitem;
pitem = pitem->GetNextProperty();
}

// If no match is found, we can add a new item to end of the list...
if ((pitem == NULL)
// && (plast)
&& (fAppendNew))
{
// Create the item...
pitem = new CDsoDocProperty();
if (pitem)
{
VARIANT var; var.vt = VT_EMPTY;
if (FAILED(pitem->InitProperty(NULL, id, &var, TRUE, plast
== NULL ? NULL : (plast->AppendLink(pitem)) )))
{ // If we fail, try to reverse the append and kill the new
object...
if (plast == NULL)
{
}
else
{
plast->AppendLink((pitem->GetNextProperty()));
}
pitem->Release();
pitem = NULL;
}
}
}

return pitem;
}

R. MacDonald

unread,
Feb 20, 2006, 3:39:07 AM2/20/06
to
Thanks very much for the post. I've had this same problem on the "back
burner" for some time, but hadn't yet got around to searching for the
solution. I'm glad you found it - and posted it.

Cheers,
Randy

snorter88

unread,
May 2, 2006, 8:55:30 PM5/2/06
to

..... And another question you may be able to help with. Using
DSOfile.dll to insert a custom property into say, test.txt. The
property appears to insert OK, I can see it using the VB7 demo app and
in the Properties tab. I open, change and close test.txt from the
desktop ... and no more custom property. Looks like Notepad or the
Windows OS has politely removed it. What gives ?

--
snorter88
------------------------------------------------------------------------
Posted via http://www.codecomments.com
------------------------------------------------------------------------

J French

unread,
May 3, 2006, 4:38:02 AM5/3/06
to
On Tue, 2 May 2006 19:55:30 -0500, snorter88
<snorter8...@mail.codecomments.com> wrote:

>
>..... And another question you may be able to help with. Using
>DSOfile.dll to insert a custom property into say, test.txt. The
>property appears to insert OK, I can see it using the VB7 demo app and
>in the Properties tab. I open, change and close test.txt from the
>desktop ... and no more custom property. Looks like Notepad or the
>Windows OS has politely removed it. What gives ?

Almost everybody in this newsgroup is using VB6 or lower.

While you may get a stray answer to VB.NET (including VB2003
and VB2005 which has dropped .NET from its name) questions here,
you should ask them in newsgroups devoted exclusively to
.NET programming.

You risk getting confusing and/or misleading replies.

Look for newsgroups with either the word "dotnet" or "vsnet" in
their name.

For the microsoft news server, try these newsgroups...

news://msnews.microsoft.com/microsoft.public.dotnet.general
news://msnews.microsoft.com/microsoft.public.dotnet.languages.vb
news://msnews.microsoft.com/microsoft.public.vsnet.general
news://msnews.microsoft.com/microsoft.public.vstudio.general
news://msnews.microsoft.com/microsoft.public.vstudio.setup
news://msnews.microsoft.public.dotnet.languages.vb.upgrade
news://msnews.microsoft.public.dotnet.languages.vb.controls
news://msnews.microsoft.public.dotnet.languages.vb.data

There are some others, but these should get you started.

snorter88

unread,
May 2, 2006, 11:01:19 PM5/2/06
to

.... found out that this is due to the implementation of EXIF

Emeric

unread,
May 5, 2006, 7:22:58 AM5/5/06
to

jeolmeun wrote:
> *

> I have been getting the error when the file does not have any
> Summary
> fields set in the first place. If I go into the file's property
> Summary
> tab and set a comment in the Comments and then try to set a
> SummaryProperties property, it worked without error.
>
> The problem seems to come from the dsofile.dll in the
> CDsoSummaryProperties::GetPropertyFromList which is called from
> CDsoSummaryProperties::WriteProperty method. When there are no
> properties (or pitem) in the file's (ADS) SummaryInformation,
> dsofile.dll doesn't seem to make a new item.
>
> *

Thank you very much for the source code correction !!!

I could't update the "title" and "category" fields if they were not
manually set before. Now it works perfectly, even with PDF files.

--
Emeric

kcrichar

unread,
Feb 15, 2007, 12:05:16 PM2/15/07
to

kcrichar1 wrote:
> *Did you ever get a copy of dsofile.dll with the patch incorporated?
> If so could you forward me a copy?
>
> kroy.c.r...@lmco.com
>
> thanks. *

You can get it here: 'dsofile.dll'
(http://briefcase.yahoo.com/bc/kcrichar/lst?.dir=/My+Shares)

--
kcrichar

kip.ki...@gmail.com

unread,
Jul 26, 2013, 4:08:36 AM7/26/13
to
Hi. - Please send debug build of dsofile.dll. - Kingston.

ObiWan

unread,
Jul 26, 2013, 5:01:01 AM7/26/13
to
:: On Fri, 26 Jul 2013 01:08:36 -0700 (PDT)
:: (microsoft.public.vb.general.discussion)
:: <7084be88-b2b2-4c5b...@googlegroups.com>
:: kip.ki...@gmail.com wrote:

> Hi. - Please send debug build of dsofile.dll. - Kingston.
>
> On Monday, February 20, 2006 11:06:20 AM UTC+5:30, jeolmeun wrote:

You are answering to a message dating back to 2006, please check the
posting date before replying to discussions

Jeff Johnson

unread,
Jul 26, 2013, 2:35:29 PM7/26/13
to
"ObiWan" <alb.20.t...@spamgourmet.com> wrote in message
news:20130726110...@deathstar.mil...

>> Hi. - Please send debug build of dsofile.dll. - Kingston.
>>
>> On Monday, February 20, 2006 11:06:20 AM UTC+5:30, jeolmeun wrote:
>
> You are answering to a message dating back to 2006, please check the
> posting date before replying to discussions

And how the hell did this C++ stuff make it to a VB newsgroup?!


0 new messages