|
I get same error when i tried to made some changes in .css file via application.
Right click on file click on properties.Go security tab in dialog box
and add ASPNET and give full rights to it.If it not works then try same thing for EVERYONE.Hope it works as its work for me.
|
|
|
|
|
Thanx
That was te problem
|
|
|
|
|
how to convert string type to double type in ASP.NET
PLZ help me
Senthil kumar
|
|
|
|
|
You can use,
Double.Parse(string)
Regards,
Jay
|
|
|
|
|
hello
u can use Convert Class to convert from type to another easily
and u will find wat u want
rasha
|
|
|
|
|
Hi ,
u can convert string to double like this.
string s = "10";
double a =Convert.ToDouble(s);
i think this will help u .
bye
|
|
|
|
|
public void aa(object sender,System.EventArgs e)
{
DropDownList dl=(DropDownList)sender;
ss=dl.SelectedValue.ToString();----->this is working fine
TextBox tb=(TextBox)DataGrid1.FindControl("TextBox1");
tb.Text=ss;------->this is giving error
}
Object reference not set to an instance of an object.
Pradeep Reddy
|
|
|
|
|
This error is coming because its unable to find control "TextBox1". Recheck it again and give the proper ID of the textbox to find it.
Regards,
Amit Kumar
HDISM, PGDCA, MCP, MCAD, MCSD
amit_chikara2002@hotmail.com
|
|
|
|
|
TextBox tb1,tb2;
DropDownList dl1,dl2;
dl1=(DropDownList)sender;
string ss=dl1.SelectedValue.ToString();
tb1=(TextBox)DataGrid1.Items[0](i was missing this).FindControl("TextBox3");
tb1.Text=ss;
thank u i got the solution
Pradeep Reddy
|
|
|
|
|
Hi All!
I wonder whether at all it is possible to assign different tooltips for each value in a dropdownlist.I need this as I'm using a dropdown list which may contain 128 characters,when it does it looks ugly.So I want to limit the character dispalyed in dropdownlist and dispay all characters in the tooltip instead when it is selected.
Thanks for you time.
|
|
|
|
|
|
I developed an application that connects to a MySQL database using a web service coded in c#. The prototype of the web service was developed with VS2003. The prototype worked great.
I completed the web service functionality after upgrading to VS2005. My remote host does not support .NET 2. How can I build the web service as a .NET 1.0 web service from VS2005?
|
|
|
|
|
This is not possible as of now. Sorry.
|
|
|
|
|
[Reference ERROR: Object does not contain the definition for method /property]
Avoid naming conflict in ASP.NET [2.0]
I found this while developing three tire ASP.NETbase web application.
Suppose you have a class library in the same solution as your web app. Name the class library as ReferMe and rename the class in it as Getit [see the following code]
using System;
using System.Collections.Generic;
using System.Text;
namespace ReferMe
{
public class Getit
{
public string Name()
{
return "this is a test";
}
}
}
Build this class project [class library].
Now add its refrence in your web project [using add reference /project]. Import this library in default.aspx.cs code behind file [see the following code]
using ReferMe;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
Getit g = new Getit();
Response.Write(g.Name());
}
}
This code will work and default.aspx will show "this is test” in browser.
Now add another page to the same web project as Getit.aspx. and change the code behind file [see the following code]
public partial class Getit : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
Response.Write("Done");
}
}
Now if you try to run the default.aspx [view it in browser] – following error message will pop up
in default.aspx.cs : Getit does not contain the definition for Name [i.e. g.Name() will not work]. If you comment out following lines in default.aspx.cs i.e. code behind for the default.aspx
using ReferMe;
Response.Write(g.Name());
Default.aspx will build successfully. [Please note that code line Getit g = new Getit(); is not an error]This is weird but true.
What is happening is that the public partial class Getit defination [in Getit.aspx.cs] is conflicting with ReferMe.Getit class in ReferMe class library. This error can be resolved by either changing Getit.aspx to Getit1.aspx or ReferMe.Getit to ReferMe.Getit1
So be careful in naming your webpage and classes in your class library projects.
-- modified at 19:57 Monday 11th September, 2006
|
|
|
|
|
Hello,
I need to be able to remove the header and footer from IE programatically. I KNOW THAT YOU CAN REMOVE THEM BY GOING INTO PAGE SETUP.
I have an invoice and i do not want the header and footer on the page. Also, is there an easy way to control the margins as well?
Thanks
Steve-o H.
There are 10 kinds of people in this world... Those who understand binary and those who dont.
|
|
|
|
|
I have a Menu control (asp.net custom control) coded in c# which I use in different c# projects. Because this group started coding all new projects in c# and in my case there are old projects in vb.net.
I would like to use same Menu control in vb.net project too. I guess it should be possible but I don't know how to do. Thanks for any help.
Ashok Ojha
|
|
|
|
|
I have the need to output text to a file in which when its printed on a pre-printed form, the values in the outputted text file will match up with the boxes on the form. Like an automated typewriter of sorts. I'm doing this so far with the System.IO namespace. The issue i'm having is the space between carrage returns. I'm using a char[] and creating 5000 ' ' char in it and ever 80 chars i'm putting a '\n' char. Then using that to insert at a specific point in that char[] so when it prints its on the specified line and distance from L to R. But on a carrage return, there is a default gap, that gap is throwing off some of the lines. Does anyone know how to correct this, or have a better way of achieving this?
Think of it as a Doctor form that is preprinted blank... and I need to access data from a database and write it to a text file in such a way that when the text file is printed on this preprinted template... the outcome is matched up like you did it on a type writer. Make sense?
Thanks in Advance,
Scott
|
|
|
|
|
Hi everyone,
I am working with a gridview (actually a radgrid from telerik) control, and am having some trouble.
I would like to use a dropdown box instead of a simple textbox for some of the columns when in edit/insert mode. The thing is that I would like to make the substitution of controls in code, not using template field.
Basically, I was wondering if I could catch an event (and what event), and change the control before it was rendered, the somehow retrieve the combobox selection and update the column value with it.
The reason I need to do it this way is because the control is supposed to be generalized for any dataset (using stored procs), so I can't 'hardcode' the template.
When putting a row in edit mode, I will need to check each column to determine what control (textbox, dropdown, ...) to use. This info will be provided by the dataset.
Thanks in advanced, and please ask for clarification if you need it.
-----------------
Genaro
|
|
|
|
|
Hi Genaro,
Just wanted to check if somebody was able to help you or in case you cracked your problem yourself !
|
|
|
|
|
i need something like a vb6 tab control in asp.net, what control in asp.net can i use
t.aransiola
|
|
|
|
|
|
Hi,
I DataGrid if Paging is allowed then,if table that is binded to DataGrid has 300 rows,and each page dispalys 10 rows.In default paging,for the first page DataGrid get the 300 records and displays the firts 10 records.for the seocond page Datagrid gets 300 records and display 11 th 20 th records.This affects on Performance.So for the datagrid we implement Custom Paging.In the New version VS2005 there is GridView.For the GridView if paging is allowed
My Question is:GRIDVIEW ALSO FETCH THE RECORDS SIMILS TO DATAGRID.
And one more question is For the DATALIST AND REPEATER controls,There is no Built in paging facility so I USED ThePAGEDDATASOURCE class to implement paging for the above 2 controls.For DATAGRID Custom paging Can we use the PAGEDDATASOURCE,or we have to write stored procedure to fetch required number of records?
Thanks in advance.
|
|
|
|
|
hi,
i ve a code which will insert a pic using execCmd to a div and saves that content to the DB as Html code.
but when an image is inserted, it is not saved to the server and the local path is saved into the DB along with the HTML code. so when i run this web application in another machine, images will not show up...
is there a way to save the image to server and save the server path to the src of the img tag inside HTML code and save the HTML code to DB.
Thanks in advance...
|
|
|
|
|
Sir,
I have a datagrid and when i go to delete the row in the grid i want to make it confirm that Are u sure u want to delete that record having id=10
Id is that column in the datagrid.
Can I send this message even with the id number.I mean when i delete the record and the row contains id 10 then it should display the message .Are u sure u want to delete the row having id =10.
Sir I want to write the code in code behind file.
Please help.
|
|
|
|
|
Yes, you can. You simply add the id value when emitting the confirm client side script in the server side code. See the sample code from here[^].
|
|
|
|