|
i want to upload all files from one folder( in client side) to server at button click event of that page without browse option(without file uploader) . we will give path of the folder path (constant)
|
|
|
|
|
Ok, I can put it another way:
That's not possible.
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
Hi all,
Any one suggest me how to remove Zero in the first place. For eg : 0208 in this I want to remove the zero only in the first occurance, therfore the output should be like 208. how to achive this using reguler expression? Because i need a solution using reguler expression
Also the length should be only 4.
Thanks in advance
Know is Drop, Unknown is Ocean
|
|
|
|
|
Hi all,
Sorry for this post. I found the solution. Please tell me is this a correct solution
Regex regex = new Regex(@"\d{4}", RegexOptions.IgnorePatternWhitespace | RegexOptions.Singleline);
string result="";
if (regex.IsMatch("00585"))
{
regex = new Regex(@"^0*");
result= regex.Replace("000508050", @"");
}
OutPut: 508050
Know is Drop, Unknown is Ocean
|
|
|
|
|
hi just for suggestion.. you can actually check the regex syntax by using another software such as regexbuddy
|
|
|
|
|
i create multithread about 100 thread to read text file base
and load data is match regulare expresstion but sometime result about
5000 answer sometime result about 7000 not reliability how to program this?
|
|
|
|
|
This is due to data collision.. you could try ReaderWriterLock class, monitor lock , Synchronization Locks
|
|
|
|
|
Hi! I have a question, I have a WIN app, and I am loading an xml document within that form. Then I have another form, what I can reach with pressing a button on the first form. I have there few fields, what I need to fill in, and I want to gather the data from the XML document what is loaded in the previous form. Is that possible?? Thx
|
|
|
|
|
You should create a Static class with static variables in it, and then create a method to load data from xml file to variables available in this static class let call it MyLoad() function.
Call this MyLoad function from the first form and load xml file in this static class. Now you may access and share data from both of the forms using this static class.
You may directly access variables of this class without any object such as-
MyStaticClass.Variable1=”Some Value”;
I hope this helps .
-Ajay.
-------------------------
www.componentone.com
-------------------------
|
|
|
|
|
i have stored procedure from SQL have bit parameter returns 1 or 0,
the parameter works fine on SQL
on C# i have problems, as the following:
SqlCommand checkDone = new SqlCommand();
checkDone.Connection = con1;
checkDone.CommandType = CommandType.Text;
checkDone.CommandText = "checkCompatability";
SqlParameter complete = new SqlParameter("@award_num", SqlDbType.Int);
complete.Direction = ParameterDirection.Output;
complete.Value = int.Parse(comboAwardNum.Text);
SqlParameter comp = new SqlParameter("@compatability", SqlDbType.Bit);
comp.Direction = ParameterDirection.Output;
bool mybool=bool.Parse(comp.Value).ToString();//error here
lblresult.Text = comp.Value;
checkDone.Parameters.Add(complete);
checkDone.Parameters.Add(comp);
checkDone.Connection.Open();
checkDone.ExecuteScalar();
checkDone.Connection.Close();
how to return parameter value from SQL?
thanks
|
|
|
|
|
What is the error that is thrown?
Vasudevan Deepak Kumar
Personal Homepage Tech Gossips
All the world's a stage,
And all the men and women merely players.
They have their exits and their entrances;
And one man in his time plays many parts... --William Shakespeare
|
|
|
|
|
can not convert from object to bool
|
|
|
|
|
Well I guess you can make a check like:
bool myBool = comp.value==1?true:false
Muhammad Talha
|
|
|
|
|
Mr.Kode wrote: checkDone.CommandType = CommandType.Text;
This should be checkDone.CommandType = CommandType.StoredProcedure;
You're creating output parameters so they won't take input. You can make them InputOutput parameters to take values and then they can alter them.
Mr.Kode wrote: bool mybool=bool.Parse(comp.Value).ToString();//error here
This line of code has multiple errors. comp.Value is object and Parse takes a string parameter. comp.Value is object and has not been set. Another error in this line is that after you "parse" to bool , you're using ToString() and assigning it to bool
You retrieve values from the output parameters after the command has been executed. And it would be
bool mybool = (bool)comp.Value;
The same for the other SqlParameter.
Mr.Kode wrote: checkDone.ExecuteScalar();
Why ExecuteScalar? Use ExecuteNonQuery if you're not retrieving a value.
And this question should have been asked in the SQL / ADO / ADO.NET forum
Eslam Afifi
|
|
|
|
|
hi
i have a datagrid with a hyperlink column.and "checkboxes"
when i check the checkbox the record will be deleted.so in this context i want disable the "hyperlink" when the chechbox is checked.
how to write the code can any any one help me.
|
|
|
|
|
csp wrote: i want disable the "hyperlink" when the chechbox
You can actually replace the href with a javascript:void(0) programmatically. But that would irritate the user since if he would try to click and nothing will happen. How about alerting the user when the checkbox is clicked, the hyperlink would not work.
Vasudevan Deepak Kumar
Personal Homepage Tech Gossips
All the world's a stage,
And all the men and women merely players.
They have their exits and their entrances;
And one man in his time plays many parts... --William Shakespeare
|
|
|
|
|
when check box is checked the corresponding record gets deleted logically in database.so no other events(like edit)has to be generated.this hyperlink redirects to other web page.this should not happen when checkbox is checked.
i have done for edit command,but for hyperlink i don't know what to do.
|
|
|
|
|
thank u i got it.but not using css.
any ways thanks.
|
|
|
|
|
Hi All,
I wrote code for class assembly named FTPUtility.dll using C#. After that i just rename that FTPUtility.dll file and used it in my application as reference. but it gives the error message
"Could not load file or assembly 'FTPUtility, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified."
Anybody can tell me why this error occured.
Pravin
|
|
|
|
|
Is the error observed in Visual Studio Build Output window?
Vasudevan Deepak Kumar
Personal Homepage Tech Gossips
All the world's a stage,
And all the men and women merely players.
They have their exits and their entrances;
And one man in his time plays many parts... --William Shakespeare
|
|
|
|
|
no, error does not appear in Build output window. it occures at the runtime
Pravin
|
|
|
|
|
Are you renaming after adding as a reference and building? It will naturally fail then.
Why are you renaming the DLL?
Cheers,
Vikram.
The hands that help are holier than the lips that pray.
|
|
|
|
|
No, first i rename that dll file and after that i have added it as reference. It compiles fine. but shows FileNotFound exception at run time.
error message is as follows....
"Could not load file or assembly 'FTPUtility, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified."
Pravin
|
|
|
|
|
You need to remove the reference to FTPUtility and add it again
|
|
|
|
|