omegalove
asked on
c#
uxSendMessage.DefaultRecip ient = QueryHelper.GetString("req uestid", string.Empty);
how can I rewrite this?
how can I rewrite this?
What are you trying to accomplish?
ASKER
QueryHelper.GetString("req uestid", string.Empty);
to remove thie queryhelper
to remove thie queryhelper
#region Assembly CMS.GlobalHelper.dll, v2.0.50727
// C:\inetpub\wwwroot\KenticoCMS\Bin\CMS.GlobalHelper.dll
#endregion
using System;
namespace CMS.GlobalHelper
{
// Summary:
// QueryString helper methods
public static class QueryHelper
{
// Summary:
// Returns true if query parameter is present in the query string
//
// Parameters:
// name:
// Query parameter
public static bool Contains(string name);
//
// Summary:
// Returns the boolean representation of a query parameter or default value
// if parameter is not boolean.
//
// Parameters:
// name:
// Query parameter
//
// defaultValue:
// Default value
public static bool GetBoolean(string name, bool defaultValue);
//
// Summary:
// Returns the double representation of a query parameter or default value if
// parameter is not an integer number.
//
// Parameters:
// name:
// Query parameter
//
// defaultValue:
// Default value
public static double GetDouble(string name, double defaultValue);
//
// Summary:
// Returns the GUID representation of a query parameter or default value if
// parameter is not GUID.
//
// Parameters:
// name:
// Query parameter
//
// defaultValue:
// Default value
public static Guid GetGuid(string name, Guid defaultValue);
//
// Summary:
// Generates hash for given QueryString
//
// Parameters:
// input:
// Query string starting with '?' or complete url
//
// Returns:
// SHA256 hash of query string
public static string GetHash(string input);
//
// Summary:
// Generates hash for given QueryString
//
// Parameters:
// input:
// Query string starting with '?' or complete url
//
// isQueryString:
// Indicates if input is query string or url
//
// Returns:
// SHA256 hash of query string
public static string GetHash(string input, bool isQueryString);
//
// Summary:
// Returns the integer representation of a query parameter or default value
// if parameter is not an integer number.
//
// Parameters:
// name:
// Query parameter
//
// defaultValue:
// Default value
public static int GetInteger(string name, int defaultValue);
//
// Summary:
// Returns query string parameter or default value if query string is not defined.
//
// Parameters:
// name:
// Query parameter
//
// defaultValue:
// Default value
public static string GetString(string name, string defaultValue);
//
// Summary:
// Returns HTML encoded query string parameter or default value if query string
// is not defined.
//
// Parameters:
// name:
// Query parameter
//
// defaultValue:
// Default value
public static string GetText(string name, string defaultValue);
//
// Summary:
// Validates given QueryString against hash
//
// Parameters:
// name:
// Name of hash parameter in query string
//
// Returns:
// True if querystring is valid.
public static bool ValidateHash(string name);
//
// Summary:
// Validates given QueryString against hash
//
// Parameters:
// name:
// Name of hash parameter in query string
//
// excludedParameters:
// Parameters to exclude from hash validation. Multiple names separated by ';'.
//
// Returns:
// True if querystring is valid.
public static bool ValidateHash(string name, string excludedParameters);
//
// Summary:
// Validates given value against hash
//
// Parameters:
// value:
// Value to validate
//
// hash:
// Hash value
//
// Returns:
// True if hash is valid.
public static bool ValidateHashString(string value, string hash);
}
}
If I read it right, you are trying to get a Query String called "requestid". This is how you would do it if that is the case:
uxSendMessage.DefaultRecip ient = Request.QueryString["reque stid"].ToS tring();
uxSendMessage.DefaultRecip
ASKER
but is this doing for empty string?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I don't understand what the problem is with the question.
Can one of you gentleman split the points between you two.
Can one of you gentleman split the points between you two.
ASKER
ok thanks.