|
You will have to remove the element from it's parent. I dont think setting OuterHtml will have any effect.
|
|
|
|
|
HI
i am working on c# windows application.When i click the button a validation window has to be open ,i am getting this in minimised state
how to get it in normal state.I am new to .net development
any sugesstions please
|
|
|
|
|
go to the properties of the window and set the Window State property to Normal.
|
|
|
|
|
Hello everyone,
In my local computer, if I know the sub-web site name is "MyTestSite" under the Web Sites category of IIS manager, how could I retrieve the absolute physical file path for the sub-web site?
thanks in advance,
George
|
|
|
|
|
type 'inetmgr' in the run.then you will be able to see all the application under the defaultwebsite in iis.rightclick on "MyTestSite" press properties.Then you will see a textbox labeled as LocalPath.That is Physical path.If your site resiides in ~\inetpub\wwwroot folder then it'll show \MyTestSite.
Cheers!!
Brij
|
|
|
|
|
Thanks Brij,
My question is about how to get it in a programmig way.
regards,
George
|
|
|
|
|
Do some research on Mapserverpath.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Can not find any useful samples from both Google and MSDN. Could you post your preferred link or samples please?
regards,
George
|
|
|
|
|
He meant Server.MapPath()
|
|
|
|
|
Thanks leppie,
I have found it. My question is how to use Server object in a console C# program? I found all samples are in ASP.Net.
regards,
George
|
|
|
|
|
thank you
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
How can i call the button click event of a button by Enter key of keyboard
|
|
|
|
|
|
Hi,
On the key press event write the following code:
this.InvokeOnClick(button1, e);
|
|
|
|
|
hello,
I am trying to insert data into a database.My code gives no error.
But the values are not inserted into database.
Please help...can anyone send a sample code
|
|
|
|
|
Could u show ur code?
Is there any error in database connection?
|
|
|
|
|
Your question is not explaining anything about what you did. Have you put breakpoints and stepped into the code ?
|
|
|
|
|
No..Please tell how to go about
|
|
|
|
|
are you trying to insert data from textBox or other controls?
are you using Oracle or SQl ?...plz. give some details....
|
|
|
|
|
I am trying to insert from textbox.I am using SQL
|
|
|
|
|
use a breakpoint to see if the text box value is parsed properly in the query. also, check the single and double quotes. they need to be in a proper sequence for the value to be fetched.
|
|
|
|
|
using System.Data.SqlClient;
using System.Data.OleDb;
code for connecting to SQL database:-
try
{
SqlConnection mc = new SqlConnection(Persist Security Info=False;User ID=sa;Initial Catalog=DataBase_Name;Data Source= SQL_Server_Name");
SqlDataAdapter da =new SqlDataAdapter("Select * from Table_name", mc);
DataSet ds =new DataSet();
da.Fill(ds,"Table_name");
MessageBox.Show("Connection Successfull");
}
catch(Exception ex)
{MessageBox.Show(ex.Message);
}
code for inserting data from textBox:-
try{
SqlCommand insertCmd=new SqlCommand("insert into Table_Name(Column_Name)values(@Variable_name)",Connection_Name);
insertCmd.Parameters.Add("@Variable_Name",SqlDbType.Nchar,10);
insertCmd.Parameters["@Variable_Name"].Value=textBox1.Text;
insertCmd.ExecuteNonQuery();
MessageBox.Show("Records inserted successfully");
}
catch(Exception ex)
{MessageBox.Show(ex.Message);}
|
|
|
|
|
hello,
in .net it is possible to set the opacity of an window.form, but thats for the whole window, how can i make it, that i have only a part of the window transulent? for example only a rectangle from:
X=0
Y=0
W=this.Width
H=50
is something like that possible?
|
|
|
|
|
Hi,
You can use the form property "Transparencykey".
How to use?
1) Set the Transparencykey value to a color, for e.g. Red.
2) Add a panel control and set his color to Red.
3) Run the application.
Note: All controls that will have the same color as you specify in the Transparencykey will be
Transparent.
|
|
|
|
|
i have a C# windows application in which i have a button PRINT .On clicking the button, data from textboxes is taken and inserted into particular cells of an MS Excel sheet. I have a textbox BILL NO. and i want that every time i click the PRINT button the value in BILL NO.textbox should be incremented so that it can be inserted into a particular cell of MS Excel sheet.
for e.g. if i have entered 0 in the BILL NO. textbox,everytime i click the PRINT button the text in the textbox should be incremented to 1,2,3....and so on. i have tried a few options ...but whenever i run the application the count starts from 0......PLZ. HElp
|
|
|
|