Click here to Skip to main content
15,887,434 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionHow to send Email using VB 6.0 Pin
Saranya-from-Tamil-Nadu-India4-Jun-13 23:28
Saranya-from-Tamil-Nadu-India4-Jun-13 23:28 
AnswerRe: How to send Email using VB 6.0 Pin
Richard MacCutchan4-Jun-13 23:34
mveRichard MacCutchan4-Jun-13 23:34 
QuestionSmart Card and CredUIPromptForWindowsCredentials Pin
dfaulhaber2k14-Jun-13 11:28
dfaulhaber2k14-Jun-13 11:28 
QuestionFindFirstFileEx() and Unicode Pin
treddie4-Jun-13 10:03
treddie4-Jun-13 10:03 
AnswerRe: FindFirstFileEx() and Unicode Pin
Dave Kreskowiak4-Jun-13 10:39
mveDave Kreskowiak4-Jun-13 10:39 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie4-Jun-13 11:04
treddie4-Jun-13 11:04 
GeneralRe: FindFirstFileEx() and Unicode Pin
Dave Kreskowiak4-Jun-13 11:12
mveDave Kreskowiak4-Jun-13 11:12 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie4-Jun-13 11:32
treddie4-Jun-13 11:32 
Dave Kreskowiak wrote:
that's because it's the limit in Windows, not .NET. The current path limit is 248 characters and the filename limit is 260.


But there are easy ways to accidentally create pathnames much much longer than that. When I try the FileInfo class, I run into that barrier. FindFirstFileEx() allows me to get around that problem. I have that working fine. But the Unicode part of it is what is biting me.

Incidentally, I also found through tests that the TRUE limit for Windows, is 240 characters max. When you subtract the 8.3name from the 260 and get 248, you still have to remove another 3 for the root folder...That leaves you with 245, but then you cannot use another 5 characters. This may be a bug in Windows, but in some cases, if you try to go beyond 240, you can open/save a file OK, even move it or change its name, but you may not be able to right-click it without crashing Windows and forcing it to restart. Fortunately, you do not lose any of your running apps, but all the desktop windows you had open, get closed.

UPDATE: Error code is 2, file not found. Which repeats what the returned value (-1)of the function says. So no help from GetLastError, there. Frown | :(

modified 4-Jun-13 17:57pm.

GeneralRe: FindFirstFileEx() and Unicode Pin
treddie4-Jun-13 12:08
treddie4-Jun-13 12:08 
GeneralRe: FindFirstFileEx() and Unicode Pin
Garth J Lancaster4-Jun-13 12:41
professionalGarth J Lancaster4-Jun-13 12:41 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie4-Jun-13 16:25
treddie4-Jun-13 16:25 
GeneralRe: FindFirstFileEx() and Unicode Pin
Dave Kreskowiak4-Jun-13 12:54
mveDave Kreskowiak4-Jun-13 12:54 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie4-Jun-13 16:47
treddie4-Jun-13 16:47 
GeneralRe: FindFirstFileEx() and Unicode Pin
Dave Kreskowiak4-Jun-13 17:37
mveDave Kreskowiak4-Jun-13 17:37 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie4-Jun-13 19:17
treddie4-Jun-13 19:17 
GeneralRe: FindFirstFileEx() and Unicode Pin
Dave Kreskowiak4-Jun-13 12:44
mveDave Kreskowiak4-Jun-13 12:44 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie4-Jun-13 17:11
treddie4-Jun-13 17:11 
GeneralRe: FindFirstFileEx() and Unicode Pin
MicroVirus5-Jun-13 7:32
MicroVirus5-Jun-13 7:32 
GeneralRe: FindFirstFileEx() and Unicode Pin
Dave Kreskowiak5-Jun-13 9:46
mveDave Kreskowiak5-Jun-13 9:46 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie5-Jun-13 16:29
treddie5-Jun-13 16:29 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie6-Jun-13 8:15
treddie6-Jun-13 8:15 
GeneralRe: FindFirstFileEx() and Unicode Pin
Dave Kreskowiak6-Jun-13 10:10
mveDave Kreskowiak6-Jun-13 10:10 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie6-Jun-13 11:16
treddie6-Jun-13 11:16 
AnswerRe: FindFirstFileEx() and Unicode Pin
Alan N6-Jun-13 13:27
Alan N6-Jun-13 13:27 
GeneralRe: FindFirstFileEx() and Unicode Pin
treddie6-Jun-13 14:13
treddie6-Jun-13 14:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.