Login | |
|
 |
RE: using Windows CommonDialog - 8/2/2005 4:39:55 AM
|
|
 |
|
| |
mbouchard
Posts: 1863
Score: 14
Joined: 5/15/2003
From: USA
Status: offline
|
Not sure if it will work for what you want, but try GetBaseName Set fso = CreateObject("Scripting.FileSystemObject") GetTheBase = fso.GetBaseName(objDialog.FileName) msgbox GetTheBase
_____________________________
Mike For useful Scripting links see the Read Me First stickey! Always remember Search is your friend.
|
|
| |
|
|
|
 |
RE: using Windows CommonDialog - 8/2/2005 10:56:03 AM
|
|
 |
|
| |
Fredledingue
Posts: 337
Score: 0
Joined: 5/9/2005
From:
Status: offline
|
Try this... set fso = createobject("scripting.filesystemobject") set file = fso.getfile("C:\My Documents\test.txt") SimpleName = Replace(file.name, fso.GetExtensionName(file),"")
_____________________________
Fred
|
|
| |
|
|
|
 |
RE: using Windows CommonDialog - 8/4/2005 9:35:27 AM
|
|
 |
|
| |
Fredledingue
Posts: 337
Score: 0
Joined: 5/9/2005
From:
Status: offline
|
But I can't use this code because I get an "ActiveX" error. Any help?
_____________________________
Fred
|
|
| |
|
|
|
 |
RE: using Windows CommonDialog - 8/4/2005 11:04:54 AM
|
|
 |
|
| |
Fredledingue
Posts: 337
Score: 0
Joined: 5/9/2005
From:
Status: offline
|
hey, thanks ebvhs, The problem is that I'm on W98SE and many of the codes here don't work for me...and I don't know what I should download to ugrade my system for these functions and even if it's possble on W98. Here I can't CreateObject( "MSComDlg.CommonDialog" ), just the same error as always.
_____________________________
Fred
|
|
| |
|
|
|
 |
RE: using Windows CommonDialog - 8/4/2005 12:17:56 PM
|
|
 |
|
| |
Fredledingue
Posts: 337
Score: 0
Joined: 5/9/2005
From:
Status: offline
|
Maybe I must update Comdlg32.ocx , but I'm not sure and I don't know where to find the last update for this file. Those I found with Google were older than the one I have already.
_____________________________
Fred
|
|
| |
|
|
|
 |
RE: using Windows CommonDialog - 8/5/2005 3:45:46 AM
|
|
 |
|
| |
Fredledingue
Posts: 337
Score: 0
Joined: 5/9/2005
From:
Status: offline
|
thanks for your help, I registered the ocx and have WSH5.6 installed. but I think it's more complicated than that: I should have a license (as I'v read) or install .NET... But I'm still not sure I jhave the lastest Comdlg32.ocx. if you know where I can download it... ehvbs, I'm using in WSH, (wscript.exe) only...
_____________________________
Fred
|
|
| |
|
|
|
|
|