Home>

■ I want to achieve
I want to open a folder using vbscript.

■ Error message
If Japanese (Kanji, Hiragana), blanks, or symbols are used in the folder name, an error will be displayed when opening.

■ Corresponding source code
Dim FN'folder name
Dim objShell

FN = "Save C: \ work \ 01"
Set objShell = WScript.CreateObject ("Shell.Application")
objShell.Explore FN
Set objShell = Nothing

  • Answer # 1

    I'm guessing, isn't the character code of the source file set to UNICODE?
    Open the source file, select "Save As", and check the "Character code" displayed at the bottom.
    ANSIIf it is not, select it and save it by overwriting.

    By the way, no error has occurred in this environment (Windows 10).