|
Amit Kumar G wrote: i fully agree with you. Why you need explicit call to GC. Can you share the reason. ?
There may be a time when memory is critical and you need to clear it out but you cant wait on the GC to do it for you. These are rare cases along with any other cases where you would explicitly invoke the GC. I believe if you build your code to where you actually need to invoke the GC manually then you need to rethink your design.
█▒▒▒▒▒██▒█▒██
█▒█████▒▒▒▒▒█
█▒██████▒█▒██
█▒█████▒▒▒▒▒█
█▒▒▒▒▒██▒█▒██
|
|
|
|
|
I am getting problem while running my pages on Mozilla. I am using master and content pages of VS 2005. My master page is very simple with three section i.e. Menus (left), header (company logo) and footer.
I am able to see correct formatting in IE but as soon as i run on mozilla, all formatting changed very badly. ..... ANY ONE KNOW WHY, IF YES how i can resolve the problem.
Point to be noted, my content section of content page is coming fine on mozila. Only header and menu section is (
Thanks for your help!!
Amit
|
|
|
|
|
this is a very common problem into various browser.u hav to go very deep into html to resolve tht problem.bcoz browser dosent follow a particular standard.so check ur all html tags are close and chek ur page into various browser.In the point of view of IE tht support too much html tags but mozilla and firefox dosent.so keep maintain a standard through css and html tags for ur page.
Deepak
Smile a Lots,Its Costs Nothing
|
|
|
|
|
I think u have used Design View which Generate Pixels. Please Go to ur HTML Code and Do code manualy. Do not touch Design. Remove Pixel's and Use % instead of Pixels.
for example there is a table which width is "width = 45px", Set this to "width = 45%".
Ur problem will be solved.
|
|
|
|
|
Hi all,
i am trying to learn .Net Techonolgy. please can anyone tell me how you fill a table with data from a database.?
i know we can use Data adapter to fill the data from the dataset. but i want to know this with sample example.
thanks in advance,
Rahi
If you look at what you do not have in life, you don't have anything,
If you look at what you have in life, you have everything... "
|
|
|
|
|
|
use System.Data.SqlClient;
SqlConnection conn = new SqlConnection("Data Source=....;Initial Catalog="databasename";User Id=sa;password=;");
SqlCommand cmd= new SqlCommand("Select * from customer", conn);
SqlDataAdapter adp=new SqlDataAdapter(cmd);
DataSet ds=new DataSet();
adp.fill(ds,"TableAliasName");
now ds contain data from table in database.
if u want display data in grid then
GridView1.DataSource=ds;
GridView1.DataBind();
anujsharma
|
|
|
|
|
I have 2 formview (FVRegDetails,FVPartyDetails)
FVregDetails in Insert Mode takes parameter SroOfficeNo,COnsiderationAmount,TypeOfDocument
After sucessfully Insertion In Database A RegId (Identity Column) created .
Based upon the RegId Value I need to Insert FVpartyDetails 2nd Formview which will take Parameters (RegId(which will come from database table),PartyName,PartyAddress)
How Can I get the Value of RegId in the 2nd Formview ...
Thanks
PKSAHOO
|
|
|
|
|
pksahoo wrote: How Can I get the Value of RegId in the 2nd Formview ...
You can define an insert parameter with the output direction in the first formview and use this one to capture the new generated id, you then can persist the value somewhere so that you can easily get the value to pass in to the insert parameter in the second formview.
|
|
|
|
|
Hi.
I need a quick tutorial about object data source.
Can anyone give me a link?
I'd searched, but I didn't find any good article.
Best wishes
|
|
|
|
|
|
anyone can help me for PHP/MYSQL questions????if yes mail me on uday.kiet@gmail.com....
|
|
|
|
|
Try asking at the DevShed Forums[^]. They have a very active PHP community.
|
|
|
|
|
Hi,
Can any body tell me how can I Increase my Cookies size.
I have a file approx 500kb and I want to store it in to the cookies for the time beeing but there is a restriction that by default Cookies size is 4kb, that's why I want to Increase my Cookies size.please provide me with a solution.
Regards
Kavi.
|
|
|
|
|
Kavi
I am not sure but i think you can not. You need to think for some workarounds.
Amit
|
|
|
|
|
plzz tell how file is uploaded using browser button on page. it means write code to read file,upload and browse button & write code to save and selected file to browser....
|
|
|
|
|
please put his code in html site and manage yourself where ever you want to save your file there is method for saveing file.
Cool
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="aaaaaa.aspx.vb" Inherits="civilesengineers.aaaaaa"%><br />
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><br />
<HTML><br />
<HEAD><br />
<title>aaaaaa</title><br />
<script runat="server" id="Script1"><br />
Private Function PickupFileNameWithExtasion(byval sttr as string) as String<br />
Dim st As String = Trim(sttr)<br />
Dim sr As String<br />
dim cs as String<br />
Dim f, k As Integer<br />
sr = StrReverse(st)<br />
f = InStr(sr, "\")<br />
k = f - 1<br />
cs = StrReverse(Mid(sr, 1, k))<br />
PickupFileNameWithExtasion = cs<br />
<br />
End Function<br />
<br />
<br />
Sub UploadBtn_Click(Sender as Object, e as EventArgs)<br />
dim strLocalPath as string<br />
dim strFileName as string<br />
dim i as integer=2<br />
Dim popUpScript As String<br />
if MyFile.PostedFile.FileName <> "" then<br />
strFileName = PickupFileNameWithExtasion(MyFile.PostedFile.FileName)<br />
<br />
MyFile.PostedFile.SaveAs(ConfigurationSettings.AppSettings("MyPath")& strFileName)<br />
<br />
<br />
Else <br />
End if<br />
End Sub<br />
</script><br />
<meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1"><br />
<meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1"><br />
<meta name="vs_defaultClientScript" content="JavaScript"><br />
<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5"><br />
</HEAD><br />
<body bgColor="inactivecaptiontext" MS_POSITIONING="GridLayout"><br />
<form id="Form1" action="aaaaaa.aspx" method="post" encType="multipart/form-data" runat="server"><br />
<h1 align="center">Upload Your File</h1><br />
<P align="center"> </P><br />
<P align="center">Selec<br />
<asp:LinkButton id="LinkButton1" style="Z-INDEX: 101; LEFT: 32px; POSITION: absolute; TOP: 208px"<br />
runat="server" Width="77px" Height="24px">New User</asp:LinkButton>t File <br />
To Upload to Server: <input id="MyFile" type="file" size="23" name="MyFile" runat="server"> <br />
<input id="Submit1" type="submit" value="Upload!" name="Submit1" runat="server" OnServerclick="UploadBtn_Click"><br />
<asp:LinkButton id="LinkButton2" style="Z-INDEX: 102; LEFT: 40px; POSITION: absolute; TOP: 176px"<br />
runat="server" Width="43px" Height="16px">Login</asp:LinkButton><br />
<asp:LinkButton id="LinkButton3" style="Z-INDEX: 103; LEFT: 32px; POSITION: absolute; TOP: 256px"<br />
runat="server" Width="87px" Height="24px">Emp Longin</asp:LinkButton><br />
<asp:LinkButton id="LinkButton4" style="Z-INDEX: 104; LEFT: 40px; POSITION: absolute; TOP: 288px"<br />
runat="server" Width="93px" Height="24px">NewEmployye</asp:LinkButton><br />
</P><br />
</form><br />
</body><br />
</HTML>
Pavan Pareta
|
|
|
|
|
manish srivastava wrote: it means write code to read file,upload and browse button & write code to save and selected file to browser....
It seems you want CP to do all what you need, then what else would you do? Just copy/paste like Mark said in the other post? Oh boy, you are loosing your fun of writing code and being a programmer shouldn't appear in your mind.
|
|
|
|
|
Sorry, this is a double post, I forgot to make it ignore HTML tags.
This is probably a more involved question, but if you can atleast give me the bullet points. I want be able to have a web user control that gets used something like this
<cc:MyControl id="MyControl1" runat="server">
<Fields>
<Field dbname="name" header="Full Name">
<Field dbname="Address1" header="Address 1">
...
</Fields>
<EmailRecipients>
<Recipient address="someone@somewhere.com">
<Recipient address="someelse@somewhere.com">
...
</EmailRecipients>
</cc:MyControl>
I then want to be able in the code behind have access the Fields and the EmailRecipients. I also want Intelisense to work. You see this behavior with controls like the GridView control.
Thanks,
Matt
|
|
|
|
|
This is probably a more involved question, but if you can at least give me the bullet points. I want be able to have a web user control that gets used something like this
<cc:MyControl id="MyControl1" runat="server">
<Fields>
<Field dbname="name" header="Full Name">
<Field dbname="Address1" header="Address 1">
...
</Fields>
<EmailRecipients>
<Recipient address="someone@somewhere.com">
<Recipient address="someelse@somewhere.com">
...
</EmailRecipients>
</cc:MyControl>
I then want to be able in the code behind have access the Fields and the EmailRecipients. I also want Intelisense to work. You see this behavior with controls like the GridView control.
Thanks,
Matt
|
|
|
|
|
In the web user control, you can simply define the collection properties for Fields and EmailRecipients like:
private List<Field> _fields = new List<Field>();
[PersistenceMode(PersistenceMode.InnerProperty)]
public List<Field> Fields
{
get
{
return _fields;
}
}
The source code of Field class should be defined in the App_Code or a seperate project.
|
|
|
|
|
I set up a simple test project for this. Adding the public List property to the control does make intelisense recognize MyFields, but it doesn't think anything should be inside the MyFields tags (Validation (ASP.Net): Text is not allowed between the opening and closing tags for element MyFields'.
What else do I need to do?
Web User Control Class
public partial class MyControl : System.Web.UI.UserControl
{
private List<MyField> _MyFields = new List<MyField>();
[PersistenceMode(PersistenceMode.InnerProperty)]
public List<MyField> MyFields
{
get
{
return _MyFields;
}
set
{
_MyFields = value;
}
}
protected void Page_Load(object sender, EventArgs e)
{
}
}
MyField class, located in the App_Code folder
public class MyField
{
string _MyProperty;
public string MyProperty
{
get
{
return _MyProperty;
}
set
{
_MyProperty = value;
}
}
public MyField()
{
}
}
|
|
|
|
|
In addition to the fact that you have to register the tagname and tagprefix for the web user control, you also register the namespace and tagprefix for the MyField so that the ASP.NET parser can recognize the tag. The registration markup should be something like:
<%@ Register Src="MyControl.ascx" TagName="MyControl" TagPrefix="uc1" %>
<%@ Register TagPrefix="uc1" Namespace="ASP" %> Assuming the MyField class is not wrapped up in any namespace in the App_Code, and the default namespace ASP is used. If you define it in your namespace, you simply replace the ASP with your own one.
|
|
|
|
|
That got me a step closer. uc1:MyField now shows up in intelisense. However the build fails saying that Unknown server tag 'uc1:MyField'. I am not using any custom namespaces
This is my markup
<uc1:MyControll ID="MyControll1" runat="server">
<MyFields>
<uc1:MyField MyProperty="This" />
<uc1:MyField MyProperty="That" />
<uc1:MyField MyProperty="You" />
</MyFields>
</uc1:MyControll>
This is my register tags
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<%@ Register Src="MyControll.ascx" TagName="MyControll" TagPrefix="uc1" %>
<%@ Register TagPrefix="uc1" Namespace="ASP"%>
Thoughts?
|
|
|
|
|
You now simply define the MyField in a namespace and replace the ASP with that value. My mistake here is that the default namespace of the MyField class will be empty, not ASP like the dynamic of the web pages, and the Namespace attribute of the Regsiter directive does not allow an empty value, sorry about this. Also, I'm not sure if you know this fact or not, but when you switch to the Design view you will see the the designer reports the error on the web user control. The only way to work around this error is to use a custom web control.
|
|
|
|