Search


Monday, November 2, 2009

vb.net

ADO error message

I found these messages on the internet and really help me to figure out whats the cause of the error.

'Case -2147483647 '~ Not implemented
'Case -2147483646 '~ Ran out of memory
'Case -2147483645 '~ One or more arguments are invalid
'Case -2147483644 '~ No such interface supported
'Case -2147483643 '~ Invalid pointer
'Case -2147483642 '~ Invalid handle
'Case -2147483641 '~ Operation aborted
'Case -2147483640 '~ Unspecified error
'Case -2147483639 '~ General access denied error
'Case -2147483638 '~ The data necessary to complete this operation is not yet available.
'Case -2147467263 '~ Not implemented
'Case -2147467262 '~ No such interface supported
'Case -2147467261 '~ Invalid pointer
'Case -2147467260 '~ Operation aborted
'Case -2147467259 '~ Unspecified error
'Case -2147467258 '~ Thread local storage failure
'Case -2147467257 '~ Get shared memory allocator failure
'Case -2147467256 '~ Get memory allocator failure
'Case -2147467255 '~ Unable to initialize class cache
'Case -2147467254 '~ Unable to initialize RPC services
'Case -2147467253 '~ Cannot set thread local storage channel control
'Case -2147467252 '~ Could not allocate thread local storage channel control
'Case -2147467251 '~ The user supplied memory allocator is unacceptable
'Case -2147467250 '~ The OLE service mutex already exists
'Case -2147467249 '~ The OLE service file mapping already exists
'Case -2147467248 '~ Unable to map view of file for OLE service
'Case -2147467247 '~ Failure attempting to launch OLE service
'Case -2147467246 '~ There was an attempt to call CoInitialize a second time while single threaded
'Case -2147467245 '~ A Remote activation was necessary but was not allowed
'Case -2147467244 '~ A Remote activation was necessary but the server name provided was invalid
'Case -2147467243 '~ The class is configured to run as a security id different from the caller
'Case -2147467242 '~ Use of Ole1 services requiring DDE windows is disabled
'Case -2147467241 '~ A RunAs specification must be \ or simply 0x80004018 -2147467240 The server process could not be started. The pathname may be incorrect.
'Case -2147467239 '~ The server process could not be started as the configured identity. The pathname may be incorrect or unavailable.
'Case -2147467238 '~ The server process could not be started because the configured identity is incorrect. Check the username and password.
'Case -2147467237 '~ The client is not allowed to launch this server.
'Case -2147467236 '~ The service providing this server could not be started.
'Case -2147467235 '~ This computer was unable to communicate with the computer providing the server.
'Case -2147467234 '~ The server did not respond after being launched.
'Case -2147467233 '~ The registration information for this server is inconsistent or incomplete.
'Case -2147467232 '~ The registration information for this interface is inconsistent or incomplete.
'Case -2147467231 '~ The operation attempted is not supported.
'Case -2147418113 '~ Catastrophic failure
'Case -2147024891 '~ General access denied error
'Case -2147024890 '~ Invalid handle
'Case -2147024882 '~ Ran out of memory
'Case -2147024809 '~ One or more arguments are invalid
'Case -2147217920 '~ Invalid accessor
'Case -2147217919 '~ Creating another row would have exceeded the total number of active rows supported by the rowset
'Case -2147217918 '~ Unable to write with a read-only accessor
'Case -2147217917 '~ Given values violate the database schema
'Case -2147217916 '~ Invalid row handle
'Case -2147217915 '~ An object was open
'Case -2147217914 '~ Invalid chapter
'Case -2147217913 '~ A literal value in the command could not be converted to the correct type due to a reason other than data overflow
'Case -2147217912 '~ Invalid binding info
'Case -2147217911 '~ Permission denied
'Case -2147217910 '~ Specified column does not contain bookmarks or chapters
'Case -2147217909 '~ Some cost limits were rejected
'Case -2147217908 '~ No command has been set for the command object
'Case -2147217907 '~ Unable to find a query plan within the given cost limit
'Case -2147217906 '~ Invalid bookmark
'Case -2147217905 '~ Invalid lock mode
'Case -2147217904 '~ No value given for one or more required parameters
'Case -2147217903 '~ Invalid column ID
'Case -2147217902 '~ Invalid ratio
'Case -2147217901 '~ Invalid value
'Case -2147217900 '~ The command contained one or more errors
'Case -2147217899 '~ The executing command cannot be canceled
'Case -2147217898 '~ The provider does not support the specified dialect
'Case -2147217897 '~ A data source with the specified name already exists
'Case -2147217896 '~ The rowset was built over a live data feed and cannot be restarted
'Case -2147217895 '~ No key matching the described characteristics could be found within the current range
'Case -2147217894 '~ Ownership of this tree has been given to the provider
'Case -2147217893 '~ The provider is unable to determine identity for newly inserted rows
'Case -2147217892 '~ No nonzero weights specified for any goals supported, so goal was rejected; current goal was not changed
'Case -2147217891 '~ Requested conversion is not supported
'Case -2147217890 '~ lRowsOffset would position you past either end of the rowset, regardless of the cRows value specified; cRowsObtained is 0
'Case -2147217889 '~ Information was requested for a query, and the query was not set
'Case -2147217888 '~ Provider called a method from IRowsetNotify in the consumer and NT
'Case -2147217887 '~ Errors occurred
'Case -2147217886 '~ A non-NULL controlling IUnknown was specified and the object being created does not support aggregation
'Case -2147217885 '~ A given HROW referred to a hard- or soft- deleted row
'Case -2147217884 '~ The rowset does not support fetching backwards
'Case -2147217883 '~ All HROWs must be released before new ones can be obtained
'Case -2147217882 '~ One of the specified storage flags was not supported
'Case -2147217881 '~ The comparison operator was invalid
'Case -2147217880 '~ The specified status flag was neither DBCOLUMNSTATUS_OK nor DBCOLUMNSTATUS_ISNULL
'Case -2147217879 '~ The rowset cannot scroll backwards
'Case -2147217878 '~ Invalid region handle
'Case -2147217877 '~ The specified set of rows was not contiguous to or overlapping the rows in the specified watch region
'Case -2147217876 '~ A transition from ALL* to MOVE* or EXTEND* was specified
'Case -2147217875 '~ The specified region is not a proper subregion of the region identified by the given watch region handle
'Case -2147217874 '~ The provider does not support multi-statement commands
'Case -2147217873 '~ A specified value violated the integrity constraints for a column or table
'Case -2147217872 '~ The given type name was unrecognized
'Case -2147217871 '~ Execution aborted because a resource limit has been reached; no results have been returned
'Case -2147217870 '~ Cannot clone a command object whose command tree contains a rowset or rowsets
'Case -2147217869 '~ Cannot represent the current tree as text
'Case -2147217868 '~ The specified index already exists
'Case -2147217867 '~ The specified index does not exist
'Case -2147217866 '~ The specified index was in use
'Case -2147217865 '~ The specified table does not exist
'Case -2147217864 '~ The rowset was using optimistic concurrency and the value of a column has been changed since it was last read
'Case -2147217863 '~ Errors were detected during the copy
'Case -2147217862 '~ A specified precision was invalid
'Case -2147217861 '~ A specified scale was invalid
'Case -2147217860 '~ Invalid table ID
'Case -2147217859 '~ A specified type was invalid
'Case -2147217858 '~ A column ID was occurred more than once in the specification
'Case -2147217857 '~ The specified table already exists
'Case -2147217856 '~ The specified table was in use
'Case -2147217855 '~ The specified locale ID was not supported
'Case -2147217854 '~ The specified record number is invalid
'Case -2147217853 '~ Although the bookmark was validly formed, no row could be found to match it
'Case -2147217852 '~ The value of a property was invalid
'Case -2147217851 '~ The rowset was not chaptered
'Case -2147217850 '~ Invalid accessor
'Case -2147217849 '~ Invalid storage flags
'Case -2147217848 '~ By-ref accessors are not supported by this provider
'Case -2147217847 '~ Null accessors are not supported by this provider
'Case -2147217846 '~ The command was not prepared
'Case -2147217845 '~ The specified accessor was not a parameter accessor
'Case -2147217844 '~ The given accessor was write-only
'Case -2147217843 '~ Authentication failed
'Case -2147217842 '~ The change was canceled during notification; no columns are changed
'Case -2147217841 '~ The rowset was single-chaptered and the chapter was not released
'Case -2147217840 '~ Invalid source handle
'Case -2147217839 '~ The provider cannot derive parameter info and SetParameterInfo has not been called
'Case -2147217838 '~ The data source object is already initialized
'Case -2147217837 '~ The provider does not support this method
'Case -2147217836 '~ The number of rows with pending changes has exceeded the set limit
'Case -2147217835 '~ The specified column did not exist
'Case -2147217834 '~ There are pending changes on a row with a reference count of zero
'Case -2147217833 '~ A literal value in the command overflowed the range of the type of the associated column
'Case -2147217832 '~ The supplied HRESULT was invalid
'Case -2147217831 '~ The supplied LookupID was invalid
'Case -2147217830 '~ The supplied DynamicErrorID was invalid
'Case -2147217829 '~ Unable to get visible data for a newly-inserted row that has not yet been updated
'Case -2147217828 '~ Invalid conversion flag
'Case -2147217827 '~ The given parameter name was unrecognized
'Case -2147217826 '~ Multiple storage objects can not be open simultaneously
'Case -2147217825 '~ The requested filter could not be opened
'Case -2147217824 '~ The requested order could not be opened
'Case -2147217823 '~ Bad tuple
'Case -2147217822 '~ Bad coordinate
'Case -2147217821 '~ The given axis was not valid for this Dataset
'Case -2147217820 '~ One or more of the given cell ordinals was invalid
'Case -2147217819 '~ The supplied columnID was invalid
'Case -2147217817 '~ The supplied command does not have a DBID
'Case -2147217816 '~ The supplied DBID already exists
'Case -2147217815 '~ The maximum number of Sessions supported by the provider has already been created. The consumer must release one or more currently held Sessions before obtaining a new Session object
'Case -2147217806 '~ The index ID is invalid
'Case -2147217805 '~ The initialization string does not conform to specification
'Case -2147217804 '~ The OLE DB root enumerator did not return any providers that matched an of the SOURCES_TYPEs requested
'Case -2147217803 '~ The initialization string specifies a provider which does not match the currently active provider.
'Case -2147217802 '~ The specified DBID is invalid
'Case -2147217814 '~ Invalid trustee value
'Case -2147217813 '~ The trustee is not for the current data source
'Case -2147217812 '~ The trustee does not support memberships/ collections
'Case -2147217811 '~ The object is invalid or unknown to the provider
'Case -2147217810 '~ No owner exists for the object
'Case -2147217809 '~ The access entry list supplied is invalid
'Case -2147217808 '~ The trustee supplied as owner is invalid or unknown to the provider
'Case -2147217807 '~ The permission supplied in the access entry list is invalid
'Case -2147217801 '~ The ConstraintType was invalid or not supported by the provider.
'Case -2147217800 '~ The ConstraintType was not CONSTRAINTTYPE_FOREIGNKEY and cForeignKeyColumns was not zero
'Case -2147217799 '~ The Deferrability was invalid or the value was not supported by the provider
'Case -2147217792 '~ The MatchType was invalid or the value was not supported by the provider
'Case -2147217782 '~ The UpdateRule or DeleteRule was invalid or the value was not supported by the provider
'Case -2147217781 '~ The pConstraintID did not exist in the data source
'Case -2147217780 '~ The dwFlags was invalid
'Case -2147217779 '~ The rguidColumnType pointed to a GUID that does not match the object type of this column or this column was not set
'Case -2147217778 '~ The requested URL was out-of-scope
'Case -2147217776 '~ The provider could not drop the object
'Case -2147217775 '~ There is no source row
'Case -2147217774 '~ The OLE DB object represented by this URL is locked by one or more other processes
'Case -2147217773 '~ The client requested an object type that is only valid for a collection
'Case -2147217772 '~ The caller requested write access to a read-only object
'Case -2147217771 '~ The provider could not connect to the server for this object
'Case -2147217770 '~ The provider could not connect to the server for this object
'Case -2147217769 '~ The attempt to bind to the object timed out
'Case -2147217768 '~ The provider was unable to create an object at this URL because an object named by this URL already exists
'Case -2147217767 '~ The provider could not drop the object
'Case -2147217766 '~ The provider was unable to create an object at this URL because the server was out of physical storage

Monday, March 23, 2009

Dataset to Datarow in c#

dsStyle as my Dataset
row for my Datarow.

Dataset dsStyle = // already assigned some records then i want it to get those data display to the page. also if you want to put it on the option box you can do that also.


results.Append("All Style");
foreach (DataRow row in dsStyle.Tables[0].Rows)
{
results.Append("" + DB.RowField(row, "CATEGORYCODE").ToString() + "");
}

Wednesday, March 18, 2009

How to remove the last Letter or char in c#

//I have here a sample text

string m_Value = "Testing 1| Testing 2 | Testing 3 |";

//and then i want to remove the last char " |"


string m_NewValue = m_Value.Substring(0, m_Values.Length - 2);

the output will be:

"Testing 1| Testing 2 | Testing 3"


Hope this help..

How to get the Current IP in c#

string m_currentIP = HttpContext.Current.Request.UserHostAddress;

Hope this help.. :)

Wednesday, March 11, 2009

Redirection url onclick event using javascript

You'll just need to have an event onclick and pleace the function redirectURL.


function redirectUrl()
{
window.location = "http://ehamak.blogspot.com";
}


Hope this help..:)

How to get the available fonts style on the server in vb.net

Get all available fonts on the server.


Private Sub LoadFonts()
Dim installed_fonts As New InstalledFontCollection
Dim font_families() As FontFamily = installed_fonts.Families()

' Display the font families.
For Each font_family As FontFamily In font_families
' font_family.Name & ", "
ddlFontName.Items.Add(font_family.Name)
Next font_family
End Sub

Hope this help you.