I am writing a program to input and output a simple array.
static void Main(string args)
int arr = new int;
Console.WriteLine("Enter nmber of elements");
int n = int.Parse(Console.ReadLine());
I followed the steps as given in Send Email with example in ASP.Net using C# and VB.Net. But I get an exception "System.Net.Mail.SmtpException: 'The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.7.0 Authentication Required. Learn more...
Hello, I want to learn to send emails in C#. I want to build a contact us form where the user can just simply type his email address and write his message. Upon hitting the send button the message should get delivered to my email address(gmail account).
I have searched on internet regarding...
I am currently iterating my list items one by one and sending them to Oracle Parameter, but instead of sending one by one, how can I send the entire list in one go ? Can I achieve same results as I am getting from below code?
foreach (var country in countryList)
I am developing an application where I have to perform some update operation on each machine in the database. Every machine has a unique Id. Then there is also an area code under which several machines come. Area codes are also unique. I am reading these ids from the database and storing them in...
Yes, I will integrate the connection string to the code as they will be distributing the application to end users. If I keep it in config file, then any end user might see all the connection info and then can access the database to make any kind of changes !!!
Actually, I have no control over the database and currently the customer doesn't have any webservice. My desktop application is updating the database. One option I thought that I could do is to store the connection string in the class file rather than in appconfig file but my appconfig file will...
I know that you have to right click on the solution and go to the bin folder from where you can copy the .exe, dlls and the config file and share it to end users. The issue is that I am storing my database connection code in the appconfig file which has database username and password also. So...
I want to learn both. I am first trying it with HttpWebRequest then I will try with HttpClient.
I serialized the object but now I am getting
You must provide a request body if you set ContentLength>0 or SendChunked==true.
Do this by calling...
Hello Finally i found a post api which sends and receives data in XML format.
My API has a request body -
I am confused as how I should I hit the api with this body from the code -...
I made the following changes in the header
Content-Type : application/xml
but it is still giving me unsupported media type error
Or is there any other API which I can get which uses a simple xml request body and returns response in plain xml ? The reason of me being persistently asking for this kind of api is that I have to create an application in future using this kind of api . There is an existing application from...
Thanks, it is working now. But I am extremely confused now. Actually, the API that I am referring to for learning( cannot post here due to confidentiality) is a SOAP API ( it has a WSDL) but I was able to run it in fiddler without the soap envelope. That API accepts request body in XML and also...