Author Topic: Does Any One Know?  (Read 2436 times)

0 Members and 1 Guest are viewing this topic.

Offline Perozai R!nd

  • Baloch
  • Creative Baask
  • ***
  • Posts: 2685
  • Karma: 75
    • Baask - The Home Of Balochi Language & Literature
Does Any One Know?
« on: December 14, 2006, 09:13:48 PM »


You Won't Belive This Dear Baaskians!!!!!!!!



An Indian discovered that nobody can create a FOLDER anywhere on the computer which can be named as "CON".

This is something pretty cool...and unbelievable. .. At Microsoft the whole Team, including Bill Gates, couldn't answer why this happened!

So, inform about this to all your friends. TRY IT NOW , IT WILL NOT CREATE " CON " FOLDER

Try To rename the New Folder as CON Or con It will not Accept ...

Dont Forget To Try.So Try It Right Now In Your Computer.
:? :?


Offline Digital Walk

  • Global Moderator
  • *****
  • Posts: 195
  • Karma: 24
  • www.kechsoft.co.nr
    • Kechsoft
Re: Does Any One Know?
« Reply #1 on: December 14, 2006, 11:17:15 PM »
actually this (CON) including , PRN, AUX, COM1 up to COM9, LPT1 up to LPT9 and NUL, are reserved words thats why they cannot be used in file or folder names.
there is nothing to be astonished and worried about.  :mrgreen:
Now give THEM a try!!

AND
Microsoft has already mentioned it in its MSDN website:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/fs/naming_a_file.asp

OR  SIMPLY.. check this:
Quote
Naming a File

Although each file system can have specific rules about the formation of individual components in a directory or file name, all file systems follow the same general conventions: a base file name and an optional extension, separated by a period.

For example, the MS-DOS FAT file system supports 8 characters for the base file name and 3 characters for the extension. This is known as an 8.3 file name. The FAT file system and the NTFS file system are not limited to 8.3 file names, because they support a long file name.
Naming Conventions

The following rules enable applications to create and process valid names for files and directories regardless of the file system:

    * Use a period (.) to separate the base file name from the extension in a directory name or file name.
    * Use a backslash (\) to separate components in paths, which divides the file name from the path to it, or one directory from one another in a path. You cannot use a backslash in file or directory names. However, they can be required as part of volume names, for example, "C:\". UNC names must have the following format: \\<server>\<share>.
    * Use any character in the current code page for a name, including Unicode characters, except characters in the range of 0 (zero) through 31, or any character that the file system does not allow. A name can contain characters in the extended character set (128–255). However, it cannot contain the following reserved characters:

      < > : " / \ |
    * Use a period (.) as a directory component in a path to represent the current directory.
    * Use two consecutive periods (..) as a directory component in a path to represent the parent of the current directory.
    * Do not use the following reserved device names for the name of a file: CON, PRN, AUX, NUL, COM1, COM2, COM3, COM4, COM5, COM6, COM7, COM8, COM9, LPT1, LPT2, LPT3, LPT4, LPT5, LPT6, LPT7, LPT8, and LPT9. Also avoid these names followed by an extension, for example, NUL.tx7.

          Windows NT:  CLOCK$ is also a reserved device name.


    * Do not assume case sensitivity. Consider names such as OSCAR, Oscar, and oscar to be the same.
    * Do not end a file or directory name with a trailing space or a period. Although the underlying file system may support such names, the operating system does not.

Maximum Path Length

In the Windows API, the maximum length for a path is MAX_PATH, which is defined as 260 characters. A path is structured in the following order: drive letter, colon, backslash, components separated by backslashes, and a null-terminating character, for example, the maximum path on the D drive is D:\<256 chars>NUL.

The Unicode versions of several functions permit a maximum path length of approximately 32,000 characters composed of components up to 255 characters in length. To specify that kind of path, use the "\\?\" prefix.

    Note  The maximum path of 32,000 characters is approximate, because the "\\?\" prefix can be expanded to a longer string, and the expansion applies to the total length.

For example, "\\?\D:\<path>". To specify such a UNC path, use the "\\?\UNC\" prefix. For example, "\\?\UNC\<server>\<share>". These prefixes are not used as part of the path itself. They indicate that the path should be passed to the system with minimal modification, which means that you cannot use forward slashes to represent path separators, or a period to represent the current directory. Also, you cannot use the "\\?\" prefix with a relative path. Relative paths are limited to MAX_PATH characters.

When using the API to create a directory, the specified path cannot be so long that you cannot not append an 8.3 file name.

The shell and the file system may have different requirements. It is possible to create a path with the API that the shell UI cannot handle.

Relative Paths

For functions that manipulate files, the file names can be relative to the current directory. A file name is relative to the current directory if it does not begin with one of the following:

    * A disk designator, which is either a drive letter followed by a colon, or a server name and share name (\\servername\sharename).
    * A directory name separator, such as a backslash, for example, \subdir).

If the file name begins with a disk designator and a backslash (\), it is a full path (for example, c:\tmp). If a file name begins with only a disk designator, it is a relative path to the current directory on the drive with the specified letter (for example, c:tmp.txt refers to a file in the current directory on the C drive).

Short and Long File Names

Typically, Windows stores the long file names on disk as special directory entries, which can be disabled for performance reasons. When you create a long file name, Windows also creates the short MS-DOS (8.3) form of the name. On many file systems, a short file name contains a tilde (~) character. However, not all file systems follow this convention. Therefore, do not make this assumption.

To get MS-DOS file names, long file names, or the full path of a file you can do the following:

    * To get an MS-DOS file name that has a long file name, use the GetShortPathName function.
    * To get the long file name that has a short name, use the GetLongPathName function.
    * To get the full path of a file, use the GetFullPathName function.

Windows stores the long file names on disk in Unicode, which means that the original long file name is always preserved, even if it contains extended characters, and regardless of the code page that is active during a disk read or write operation. The case of the file name is preserved, but the file system is not case-sensitive.

The valid character set for long file names is the Unicode file system character set minus the colon (':') that the NTFS file system uses to open alternate file streams, which means that you can copy files between the NTFS file system and FAT file system partitions without losing any file name information.


Thank you.

Offline Perozai R!nd

  • Baloch
  • Creative Baask
  • ***
  • Posts: 2685
  • Karma: 75
    • Baask - The Home Of Balochi Language & Literature
Re: Does Any One Know?
« Reply #2 on: December 15, 2006, 06:53:54 PM »
Thankx JQ For Ur Valuable Informations...


Offline Digital Walk

  • Global Moderator
  • *****
  • Posts: 195
  • Karma: 24
  • www.kechsoft.co.nr
    • Kechsoft
Re: Does Any One Know?
« Reply #3 on: December 16, 2006, 01:12:59 AM »
You are always welcome brother!!

Offline KHALIL BALOCH

  • ALBALOSHI
  • Baask's Asset
  • ***
  • Posts: 360
  • Karma: 12
  • ALBALOSHI
    • WORLD FORUM
Re: Does Any One Know?
« Reply #4 on: December 16, 2006, 03:19:08 AM »
first of all i would like to thanks Fahad who share a valuable knowledge about compute and also thaks to MR JQ(Junaid Qadir )who give his comment and increase our knowledge.
''LIVE TO LEARN, LEARN TO LIVE, THEN TEACH OTHERS.''

Offline Muhammad Asim Baloch

  • Administrator
  • *****
  • Posts: 81
  • Karma: 14
    • Asim Baloch
Re: Does Any One Know?
« Reply #5 on: March 28, 2008, 08:21:43 PM »
Some More Microsoft crazy facts
[/b]

MAGIC #1:
Nobody can create a FOLDER anywhere on the computer which can be named as CON;.
This is something pretty cool...and unbelievable. ..
At Microsoft the whole Team, couldn't answer why this happened!
TRY IT NOW, IT WILL NOT CREATE ;CON; FOLDER

MAGIC #2:
This is something pretty cool and neat...and unbelievable. ..
At Microsoft the whole Team, including Bill Gates, couldn't answer why this happened!
Try it out yourself...
Open Microsoft Word and type
=rand (200, 99)
and then press ENTER

MAGIC #3
For those of you using Windows, do the following:
1. Open an empty notepad file
2. Type "Bush hid the facts"; (without the quotes)
3. Save it as whatever you want.
4. Close it, and re-open it.
is it just a really weird bug?
You can try the same thing above with another sentence ;this app can break

Explanation for Magic #1:
In windows the folder name and the special system variables share the same interface, so when you create a folder with a system variable name it will consider that folder already exist!!
these special system variables are available irrespective of path

You cannot create a folder with these names also:
CON, NUL, COM1, COM2, COM3, LPT1, LPT2, LPT3,COM1 to COM9 and LPT1 to LPT9....
CON means console, COM1 means serial port 1, LPT1 means parallel port 1

Offline Digital Walk

  • Global Moderator
  • *****
  • Posts: 195
  • Karma: 24
  • www.kechsoft.co.nr
    • Kechsoft
Re: Does Any One Know?
« Reply #6 on: March 31, 2008, 10:15:36 PM »
You guys are always welcome.