Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Wed Nov 20, 2019 10:45 am
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: WFS: GetVolumeName: Only up to 12 characters?
PostPosted: Thu Feb 23, 2012 9:46 am 
Offline
User avatar

Joined: Fri Sep 30, 2005 8:25 am
Posts: 97
Hi all!

I just tried to get the name of a Volume which works fine using the Windows Functionality Suite 2.6.
I use FileProcessing.GetVolumeName, which uses declares for GetVolumeInformationW or GetVolumeInformationA.

Unfortunately there are volumes with names longer than 12 characters and I get only the first 12 chars of that name.

Any clues how to solve this problem?

TIA,

GreatOm

_________________
Some things need no explanation. Elephants, for instance. (Peter Atkins)


Top
 Profile  
Reply with quote  
 Post subject: Re: WFS: GetVolumeName: Only up to 12 characters?
PostPosted: Thu Feb 23, 2012 1:00 pm 
Offline
User avatar

Joined: Mon Apr 02, 2007 2:08 am
Posts: 1225
Location: San Francisco, CA, USA
That's very odd; the GetVolumeInformation function should handle volume labels up to 259 characters long. I tested the WFS implementation just now and it worked for me, even after changing the volume label to a very long one. What version of Windows are you testing on and have you made any changes to the FileProcessing.GetVolumeName function? How are you handling the returned string?

_________________
Boredom Software


Top
 Profile  
Reply with quote  
 Post subject: Re: WFS: GetVolumeName: Only up to 12 characters?
PostPosted: Fri Feb 24, 2012 2:51 am 
Offline
User avatar

Joined: Fri Sep 30, 2005 8:25 am
Posts: 97
charonn0 wrote:
What version of Windows are you testing on


Hm... I did test against a not Windows based SMB server. So I think this issue may be server related. In Explorer I see the full volume name though...


charonn0 wrote:
and have you made any changes to the FileProcessing.GetVolumeName function?


Nope.

Thanks for your reply. No I have a clue where to investigate.

GreatOm

_________________
Some things need no explanation. Elephants, for instance. (Peter Atkins)


Top
 Profile  
Reply with quote  
 Post subject: Re: WFS: GetVolumeName: Only up to 12 characters?
PostPosted: Fri Feb 24, 2012 3:24 am 
Offline
User avatar

Joined: Fri Sep 30, 2005 8:25 am
Posts: 97
Funny...

Now I did a test against a Windows 7 based share and I get no volume name at all...
I id connect a network drive and In Explorer on my Windows 2008r2 client I see the Volume
"ICC-Profiles (\\MACHINENAME) (V:)"

I verified aslo that the code is the same as in WFS: FileProcessing.GetVolumeName and the Name is just empty.

Another thing:
I added this debug statement
#if DebugBuild
System.Log System.LogLevelError,"Drive: "+ volumeF.Name + ", Name: " + volNameStr
#endif


and it gives me following error in the Event Viewer:
Quote:
The description for Event ID 1000 from source Microsoft-Windows-User Profiles General cannot be found. Either the component that raises this event is not installed on your local computer or the installation is corrupted. You can install or repair the component on the local computer.

If the event originated on another computer, the display information had to be saved with the event.

The following information was included with the event:

Drive: V:, Name:

the message resource is present but the message is not found in the string/message table


Very strange. I try some more debugging.

GreatOm

_________________
Some things need no explanation. Elephants, for instance. (Peter Atkins)


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group