• Api Documentation
  • Source Code
Search Results for

    Show / Hide Table of Contents
    • SharpDialogs
      • SharpDialogFilter
      • SharpDialogHelpers
      • SharpFileOpenDialog
      • SharpFileSaveDialog
      • SharpFolderBrowserDialog
      • SharpInputBox
      • SharpProgressDialog
    • SharpDialogs.Wpf
      • SharpFileOpenDialogWpf
      • SharpFileSaveDialogWpf
      • SharpFolderBrowserDialogWpf
      • SharpProgressDialogWpf
    • SharpWpfAboutBox
      • SharpAboutBox
      • SharpAppProperties

    Class SharpDialogHelpers

    Helper methods for the dialogs.

    Inheritance
    object
    SharpDialogHelpers
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: SharpDialogs
    Assembly: SharpDialogs.dll
    Syntax
    public static class SharpDialogHelpers

    Methods

    | Edit this page View Source

    CompactPath(string, int)

    Truncates a path to fit within a certain number of characters by replacing path components with ellipses.

    Declaration
    public static string CompactPath(string path, int length)
    Parameters
    Type Name Description
    string path

    The path to be altered.

    int length

    The maximum number of characters to be contained in the new string.

    Returns
    Type Description
    string

    Returns the new string.

    Exceptions
    Type Condition
    ArgumentOutOfRangeException
    | Edit this page View Source

    GetByteSizeString(long)

    Converts a numeric value into a string that represents the number expressed as a size value in bytes, kilobytes, megabytes, or gigabytes, depending on the size.

    Declaration
    public static string GetByteSizeString(long filesize)
    Parameters
    Type Name Description
    long filesize

    The numeric value to be converted.

    Returns
    Type Description
    string

    Returns the converted string.

    Exceptions
    Type Condition
    ArgumentOutOfRangeException
    • Edit this page
    • View Source
    In this article
    Back to top Copyright Jérémy Ansel (c) 2025