|
Hello,
anybody tried develop OCR algorithms used with retrieving window information from external WIN32 applications?
Need some help related to documentation, basics and algorithms.
Thank you.
|
|
|
|
|
Hello, I was wondering if there is a way to create a folder in C#. I know its possible to create a file, but is there a way to create and delete a folder. Also, is there a way to lock temporary created items so that they can't be modified? (doing all of this in C#)
|
|
|
|
|
1. System.IO.Directory.CreateDirectory
2. When you open a file use FileStream and use the FileShare.None fileShare parameter.
I can imagine the sinking feeling one would have after ordering my book,
only to find a laughably ridiculous theory with demented logic once the book arrives - Mark McCutcheon
|
|
|
|
|
Hello everyone
I have read many articles about making connection to Mysql.
Many articles contain the following code, but it doesn't work when I put it into my program.
string connectionString = @"Driver={MySQL};SERVER=localhost;DATABASE=NorthwindMySQL;";
OdbcConnection conn= new OdbcConnection(connectionString);
This looks naive. Because it doesn't define the location of the database. In the database provider there is not MySql item. Could anybody tell me a good way to make a connection from C# to MySql please? And also if I make an application in .net framework with MySql as the source database, does the client needs to install mysql when I deploy the application to his computer??
Thanks in advance
Asura
|
|
|
|
|
take a look here if you did not yet,
http://dev.mysql.com/tech-resources/articles/dotnet/#ODBC.NET
I did odbc connections to mysql from VB years ago, it should work
in C# as well because ODBC is still a standart.
ODBC driver sends requests to server and not directly
to underying database file, for db server database name is unique so it knows
where it is located.
If server is not running you should
get a connetion error(server name is one of the parameters in connect string).
if you need to distribute db with an application you might want to
use file type db like Access/Excel perhups or depending on your program logic give
user remote access to your server.
|
|
|
|
|
My application will be installed in a target computer with windows 98. The application doesn't need to communicate with another computer. Do I need to install mysql and the related things into the target machine and also when the application is running, does it require the mysql running??
Thank you very much for answering my question!!!
Asura
|
|
|
|
|
yes you do need to include mysql setup in your distribution
if you are using ODBC, because odbc needs mysql server name
in connect string
and yes, evrytime your application needs to access database mysql
should be running.
|
|
|
|
|
VERY URGENT
--------------------
hi
all
I want to make a HttpWebRequest where i can put "Proxy-Connection: Keep Alive" in the Header of the Reuqest. How i can do this in C# Please Tell in Detail with Code Sample.
I have tried but coulnd fouind the Header Property , whe i add through Header.Add it gives an Err as not an appropriate property.
Thanks in Advance
Best Regards
Tariq Rahim
|
|
|
|
|
|
Is it possible to read out of a database by utulizing the SQL statement? What I mean is if I go read out of the database, can I have the reader store all those values in to an array in a few line of code? Ill give a code snippit if this is confusing.
|
|
|
|
|
To store the values from a datareader into an array is only effective if you know how many records there are in the result. If you don't know the number of recods, use some kind of list instead.
list = new ArrayList();
while (reader.Read()) {
id = reader.GetInt32(0);
name = reader.GetString(1);
list.Add(new User(id, name));
}
---
b { font-weight: normal; }
|
|
|
|
|
i have use the imagebutton for animation,but i want to disable button
m mohamad rafi
|
|
|
|
|
Set the Enabled property to false.
---
b { font-weight: normal; }
|
|
|
|
|
how to disable the C# imagebox
m mohamad rafi
|
|
|
|
|
What do you mean by the "C# imagebox"?
---
b { font-weight: normal; }
|
|
|
|
|
|
How can i Find String in DataTable or DataSet.
|
|
|
|
|
hi there,
u can play with 'Find' method of DataTable object.
it'll returen DataRowcollection that contains collection of rows that match with ur search criteria
<< >>
|
|
|
|
|
But with 'Find' method of DataTable object we can not find Partlly String it find full matching of string.
|
|
|
|
|
Hi all,
I just want to share this with you. There's people who loves writing software in notepad, i'm one of them. Programming with notepad can get you a big headache but in my opinion is more flexible in terms of custom components (custom editor, custom compiler, custom resource creator) and is very handy at compile time, using batch files (.bat) is the most common option for compilation when notepad is used instead an IDE.
C# programmers are going to love this notepad replacement. So i posted this message in the .Net Framework and here.
I just found an incredible Opensource text editor for us: Notepad++
http://notepad-plus.sourceforge.net/uk/about.php[^]
You can download an executable with installer and a zipped version for people who likes "clean" apps.
It's not a resource hungry app, it's a notepad with syntax highlighting (many languages) and format encoding, and no additional features such as code completion, and others. It's a real tool for real brainy programmers.
Enjoy
|
|
|
|
|
trying to understand
StateObject param in BeginRecieve.
any info about it would be greatly appreciated.
It popups in MS documentation as if
it is something obvious and needs no
explanation.
it appears that StateObject is mapped to
OVERLAPPED structure in win32 api, it is possible
to relate offsethigh and offsetlow to stateobject's fields but
what happens to StateObject once it gets inside
BeginRecieve and what changes happen to it ?
also why in MS sample StateObject has Socket type
field.
TIA
|
|
|
|
|
It's just a convenient place holder for something that you want to pass to the callback function. Whatever is passed in the state object can be retrieved inside the callback using the IAsyncResult.AsyncState property. For example
void Start()
{
string test = "Senthil rocks";
s2.BeginReceive(so2.buffer, 0, StateObject.BUFFER_SIZE,0,
new AsyncCallback(Async_Send_Receive.Read_Callback), test);
}
void Async_Send_Receive.Read_Callback(IAsyncResult result)
{
string s = (string)result.AsyncState;
}
You'll usually pass something more useful, such as the socket object on which you will call EndReceive.
Regards
Senthil
_____________________________
My Blog | My Articles | WinMacro
|
|
|
|
|
thank you,
could you also clear this for me:
I am doing a single submit class to send tons of GET/POST
requests where I wrap all socket related functions.
So if I have a class level Socket object(public or private) why
do I still need to pass socket parameter around when the same
object can be accessed in any function.
Is it because sticking to local variables is considered to be
a better programming practice or I must pass local object when
it comes to callbacks functions ?
TIA
|
|
|
|
|
If your socket object is a class level member variable, then yes, there's no need to pass it as in the state parameter.
Having it as a local variable gives a very minor advantage, the GC will be able to collect the socket object quicker, as there will be no outstanding references once the callback completes. Having it as a member variable means that the reference will be valid till the parent class is alive.
Not worth making it as a local variable just for that though.
Regards
Senthil
_____________________________
My Blog | My Articles | WinMacro
|
|
|
|
|
I'm looking for assistance with writing the following calculation in C#
n!
n_P_k = --------
(n - k)!
and/or
n!
n_C_k = ----------
k!(n - k)!
any ideas would be helpful!
-- modified at 21:03 Friday 9th September, 2005
|
|
|
|