For those new to message boards please try to follow a few simple rules when posting your question.
Choose the correct forum for your message. Posting a VB.NET question in the C++ forum will end in tears.
Be specific! Don't ask "can someone send me the code to create an application that does 'X'. Pinpoint exactly what it is you need help with.
Keep the subject line brief, but descriptive. eg "File Serialization problem"
Keep the question as brief as possible. If you have to include code, include the smallest snippet of code you can.
Be careful when including code that you haven't made a typo. Typing mistakes can become the focal point instead of the actual question you asked.
Do not remove or empty a message if others have replied. Keep the thread intact and available for others to search and read. If your problem was answered then edit your message and add "[Solved]" to the subject line of the original post, and cast an approval vote to the one or several answers that really helped you.
If you are posting source code with your question, place it inside <pre></pre> tags. We advise you also check the "Encode "<" (and other HTML) characters when pasting" checkbox before pasting anything inside the PRE block, and make sure "Use HTML in this post" check box is checked.
Be courteous and DON'T SHOUT. Everyone here helps because they enjoy helping others, not because it's their job.
Please do not post links to your question into an unrelated forum such as the lounge. It will be deleted. Likewise, do not post the same question in more than one forum.
Do not be abusive, offensive, inappropriate or harass anyone on the boards. Doing so will get you kicked off and banned. Play nice.
If you have a school or university assignment, assume that your teacher or lecturer is also reading these forums.
No advertising or soliciting.
We reserve the right to move your posts to a more appropriate forum or to delete anything deemed inappropriate or illegal.
We're experiencing cors issues with signalR resources and I can't imagine that I'm the only one that has had to solve this problem. The "default", documented configuration settings for enabling cors with signalR are
but CorsOptions.AllowAll configures wildcard Access-Control-Allow-Origin and you cannot specify a wildcard value AND use withCredentials. So I'm investigating what it would take to create a custom Microsoft.Owin.Cors.CorsMiddleware or create a different CorsOptions setting.
Does anyone have an example that replaces
app.UseCors("CorsOptions with a CorsPolicy that doesn't specify wildcard origins")
so...when the heck did nested object initializers become good form???
(Note that this seems to be the only way to interact with the Origins collection. Once the CorsOptions object is constructed, there is no direct access to the properties on the PolicyResolver)
CorsOptions cors = new CorsOptions
PolicyProvider = new CorsPolicyProvider
PolicyResolver = context =>
var policy = new CorsPolicy
AllowAnyOrigin = false,
AllowAnyHeader = true,
AllowAnyMethod = true,
SupportsCredentials = true
string ConStr = @"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + file + ";Extended Properties=\"Text;HDR=Yes;FMT=Delimited\"";
OleDbConnection myConnection = new OleDbConnection(ConStr);
// Create a database command on the connection using query
string query = @"select * from [test.csv]";
OleDbCommand myCommand = new OleDbCommand(query, myConnection);
// Open the connection and create the reader
OleDbDataReader myReader = myCommand.ExecuteReader(CommandBehavior.CloseConnection);
DataTable tb = new DataTable();
using (OleDbDataAdapter ad = new OleDbDataAdapter(query, myConnection))
chart1.Series["Test"].Points.DataBindXY(myReader, "Date", myReader,"Value");
chart1.Series["Test"].ChartType = SeriesChartType.Spline;
The problem is that he can't find the second column (Exception). But if I change the "Value" in
I have one web service which hosted so many place, Now I want to test that web serivce in my unit test program. currently I am doing, entry of IP address in host file each time before testing. Now I want this should programatically change IP address throgh code.
Means, only change IP address of server and call web service.
Please tell solution, how i can change IP addrss of web service runtime?
This is not a good question - we cannot work out from that little what you are trying to do.
Remember that we can't see your screen, access your HDD, or read your mind.
Frankly, I can't work out what the heck you are trying to do, much less what help you are looking for!
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
You can't change the IP address of the service itself through code. That is a network configuration change.
However, it sounds like you want to change the IP you are connecting to, and not the IP of the actual webservice. Just create a config file and use System.File namespace to read it in and parse it however you want.
There are only 10 types of people in the world, those who understand binary and those who don't.
Hello. I have got this multithreaded video player desktop application. Now this is my first experience with multithreaded apps so I don't know a lot of things. One thing that I can tell is that this application is running with 32-34 threads (using Resource Monitor) and CPU jumps from 2%-6% to 58%-62%. Starting
- from analyzing the code that takes this much CPU
- to remedy this problem
What could I do to reduce this CPU usage ? Should I be modifying the code (to make it efficient) or are there any other things that I could try
This world is going to explode due to international politics, SOON.
I'm working with the Magnetic Swipe Reader of MagTek (PN-21065140). Couldn't get a proper CSharp Sample or demo application.
I hope this runs in a Keyboard Emulator so it reads the data if any Textbox , Notepad , wordpad and so are opened.
I need a proper way of working with this swipe. That is to fire an event to detect if card is swiped. To get the card data and Track Number.
If someone could give me ideas, Samples to work with it would be great.
Thanks in advance.
i want to blink 2 and 3rd row(not particular row because i have many rows in my database) because column enddate has todays date. likewise i want to blink each row if only column enddate is todaysdate.