-
- How to get connectionstrings
by Sam2
- 7 Replies
- Last post
by timvw
- I'm trying to get a connectionstring from my config file.
After adding a reference to the System.Configuration namespace to my code I tried to run this code which I copied from here: http://msdn2.microsoft.com/en-us/library/system.configuration.connectionstringsettings(vs.80).aspx
tatic void ShowConnectionStrings()
{
// Get the application configuration file.
System.Configurat
-
- Nevermind, found the answer, here it is if anyone's interested.
by Chuck S.
- 2 Replies
- Last post
by Chuck S.
- I am trying to use a CodeDom graph to inherit a class from a base class that has virtual events. I am trying to override those events in the derived class so that they can be called.
When I set the MemberAttributes property of the CodeMemberEvent class to "MemberAttributes.Public | MemberAttributes.Override" the resulting declaration in the code only shows as public, instead of pu
-
- Try refreshing the table adapter
by MichaelMouer
- 14 Replies
- Last post
by gogliogi
- It is my
understanding that when using a TableAdapter and selecting the proper
options, Insert, Delete and Update statements are generated. The
Update statement should work just using the following: myTableAdapter.Update(changes); Where changes is the DataSet containing the modified data. This logic works great for one of the tables in the DB but not for another. Learning this new stuff is Conf
-
- datagrid on pocketPC
by Roastie
- 2 Replies
- Last post
by Roastie
- i have a web service i have a dataset in the web service. i am trying to access the dataset and change it from a pocketPC application through the web service. my problem is that when i access them and view them it is fine but when i try and edit them i get an error saying that the table is read only and i should change it to read/ write / how do i do this i had it working when i used a numericupd
-
- Date Format Problem
by Murali Salem
- 1 Replies
- Last post
by RtMahi
- Hi,
I am having a web application (Asp.net2.0), where I give date values in the format dd/mm/yy, My operating system WinXP is changed to UK settings also I've created a sql server (2005) user with 'british english' settings.
My problem is when I am running the application using VS 2005 IDE it runs fine. But when I am creating a websetup project and run it through IE, the date format is chang
-
- Batch SqlDataAdapter.Update problem
by Marco Mendonça
- 4 Replies
- Last post
by Marco Mendonca
- Hi, I'm using EnterpriseLibrary 2.0 and have the following situation: SqlDataAdapter adapter = (SqlDataAdapter)db.GetDataAdapter(); insertCommand.UpdatedRowSource = UpdateRowSource.None; adapter.InsertCommand = (SqlCommand)insertCommand; adapter.UpdateBatchSize = 0; insertCommand.Transaction = transaction; return adapter.Update(data, tabl
-
- Not able to read from serial port
by Dharmesh
- 14 Replies
- Last post
by Dharmesh
- Hi,
I am trying to read from the 93C46 chip connected to COM1 port.
To read from the 93C46 chip i am using Ports Namespace.
I've created the object of SerialPort class.
But when i try to read from the COM1 port I get timeout error.
I've set the Readtimeout to -1 and 10, but didn't get any success.
Please help me.
Dharmesh
-
- Reading DBase IV table error from ADO.net odbc driver !!! help please
by tangy
- 7 Replies
- Last post
by tangy
- I connect a dbase IV table with odbc driver connection on Server explorer.
then use dataset schema (Drag and drop to designer on VS) to generate the dataset and adapters code.
it works on some tables.
but some tables failed with this error msg:
****************************************************************
Exceptions in transfer notes. details:ERROR [07009] [Microsoft][ODBC dB
-
- Serial port
by Doron70
- 4 Replies
- Last post
by Doron70
- Hi,
My device communicated with PC under RS232.
There is any possibility to know that the cable between PC-device is disconnected.
Thanks,
-
- Problems in Marshal.PtrToStructure
by sureshsundar007
- 5 Replies
- Last post
by Sudhansu Tiwari
- Hi all, I'm having problems when using Marshal.PtrToStructure and passing a structure type to it with structure array as one of its members. The exception i'm getting is ' can not marshal field ComnPara of type DeviceDialog.CgfFileStruct This type cannot be marshaled as a structure filed. ' This is my structure [StructLayout(LayoutKind.Sequential)] public struct CfgFileStruct {  
-
- Response code in an exception (System.Net.WebException)
by qt1h00
- 3 Replies
- Last post
by Mariya Atanasova - MSFT
- Hello,
I'm doing HttpebRequest (in c#) and when i get error in the request such as 404 the exception returns:
"The remote server returned an error: (404) Not Found."
I want to get the response number (in this case 404).
How can i do it it can be diffrent response code ofcourse not just 404.
Thanks.
-
- Exceptions thrown to the system
by Damian L
- 5 Replies
- Last post
by Damian L
- Hello,
I've noticed time ago that if my callback method for a socket BeginReceive operation throws an exception the application ends (or the unhandled exception handler is called). I thought this was the common behavior for exceptions thrown to "nowhere". However today I found using MSMQ that if my handler for the BeginReceive throws an exception nothing happends (the application
-
- I still don't get GetType()
by BhuttCrackSpackle
- 2 Replies
- Last post
by nobugz
- Why does this work
If MyInstance Is GetType( SomeFrameworkType ) Then
And this does not
If MyInstance Is SomeFrameworkType Then
Which displays the error 'SomeFrameworkType' is a type and cannot be used in an expression.
Well duh... so is GetType(SomeFrameworkType)
What the hale is going on round here Can someone explain.
Thanks
A mystified pr
-
- How to Update/Insert/Delete depend on xml condition
by ruhanir
- 1 Replies
- Last post
by Chris Lovett
- Hi guyz, I'm facing a new challenge .. I have an xml file as you can see below.. (this is not the real file but similar) < xml version="1.0" encoding="UTF-16" > <products> <product id="1">
<name>Snikers</name>
<productcode>010100011</productcode>
<update>update</update> </product> <p
-
- SchemaImporterExtension - machine.config
by RtMahi
- 11 Replies
- Last post
by RtMahi
- Hi!
I created the derived class like shown in the sample. Now I can't get the debugger to step into my class.
My machine.config looks like this (in contrast to what the sample is assuming I guess):
< configuration >
< configSections >
< sectionGroup name = " system.xml.serialization " type = " System.Xml.Serialization.Configuration.SerializationSec
-
- Question regarding percision from C float to C# float
by JEBO
- 5 Replies
- Last post
by Deepika Jain85
- I am trying to convert a library we use for measurement that was written in C. Most of the functions that this library calls for calculations are from math.h and are the following: exp, abs, pow, and sqrt. Floats are being used everywhere in the C code and I noticed that in .NET that all of the Math. functions are either Double or Decimal. I read in another post while searching for help that decim
-
- How to use recordset in WebServices
by hellomcv
- 0 Replies
- Last post
by hellomcv
- Hi,
I want to expose a method returning a RecordSet in a WebService.
Any pointer on how to do this
Also I would like to know how a DataSet can be converted to RecordSet.
The WebService will be accessed from VB code from an excel sheet.
I'm using ASP.NET2.0, SQLServer2000, c#.
-
- Reading App.config file
by nivas sr
- 2 Replies
- Last post
by Salvatore Di Fazio
- Hi i am facing problem in reading custom App.config file can any one tell me how to read the custom App.config file, if possible sample code. Thanks in advance Regards Nivas
-
- how to know the hard disk activity
by creaturita
- 1 Replies
- Last post
by SalvaPatuel - MS
- Is ther a way to know when the hard disk is running when the led is on
Thanks
-
- .Net 2.0 with Windows 2003 Server
by A_Kumar
- 2 Replies
- Last post
by A_Kumar
- my application was working fine on .Net 2.0 and windows 2000 server
now I copied the same app to windows 2003 64 bit server and created the dsn
it was throwing exceptions so I changed Microsoft.Data.Odbc refernce to System.Data.Odbc
Now it is not able to find the dsn and gives below exception
System.Data.Odbc.OdbcException: ERROR [IM002] [Microsoft][ODBC Driver Manager] Data so
-
- How to execute a program remotely?
by Ayumi-M
- 6 Replies
- Last post
by Ayumi-M
- Hi everybody: It's make me crazy. I have to do a feature that can execute a program remotely. In the other words, I want to "Use my PC" and run a program on another PC. Is there any way to do this It's OK if there is no managed code to do this. Thanks a lot!
-
- PDF Encoding using StreamWrite and StreamReader
by thysie
- 4 Replies
- Last post
by Umer Khan
- Hi All,
I'm looking for the correct Encoding (or method) to read and write PDF files.
When I use something like the code below, the generated PDF (Destination.PDF) is not the same as the Source.PDF used.
StreamReader objSR = new StreamReader ( @"c:\temp\Source.pdf" , Encoding .ASCII);
StreamWriter objSW = new StreamWriter ( @"c:\temp\Destination.PDF" , fa
-
- Sending Data between two Ports in C#
by Srinivas GV
- 5 Replies
- Last post
by bola shokry
- Hi,
I am working on TCP Communication between a client and server. My Requirement is "I have a port in the client system. I have another port in the server system. First I need to send the data to the client system port. Then that data needs to be automatically send to the port on the server system."
I can access the port on the server system directly from my code in the
-
- Multiple tables Search in ASP.net 2.0
by Ramy Mahdy
- 1 Replies
- Last post
by VMazur
- hello everyone,
i have a Database for a DataCenter, the database including many tabels with Relations
and i should to control (Add, edit, Delete) this Database from Asp.net 2.0 web Application.
i want to make a search in a cusotmers table in the DB.
The customers tables including many rows like (CustID, CustFirstName, CustSecondName, ...)
in the ASP.net 2.0 search form i have some t
-
- Communication within services
by Geert van Horrik
- 4 Replies
- Last post
by Geert van Horrik
- I have written a windows service with some functionality. I have also added a web service to this windows service using the soap.tcp protocol (so the web service is hosted outside IIS).
I would like to know how you communicate between the services. My windows service has a queue which is handled by the windows service every x minutes. Users should be able to add new items to the queue by us