|
I am Using this simple code
if (chkA.Checked == true)
gType = "A,";
if (chkC.Checked == true)
gType += "C,";
if (chkH.Checked == true)
gType += "H,";
// gType = gType.Substring(0, gType.Length - 1);
Thank & Regards
Vijay s
|
|
|
|
|
Thanks for reply,I got the solution.
Thank & Regards
Vijay s
|
|
|
|
|
|
probably AutoPostBack="true"
|
|
|
|
|
Problem is my side.I only assigned "false" to that checkbox for some other reason in page load event.I dint notice that.thank you
Thank & Regards
Vijay s
|
|
|
|
|
You know you can use Page_Init(Object sender, EventArgs e) event?
In that even you can set default values. The Init is only executed at first load of the page.
|
|
|
|
|
iam having a login page where password is to be checked .it has to be checked whether caps lock is on or not when the page is loaded for the first time.
|
|
|
|
|
Javascript example: http://jdstiles.com/java/checkforcaps.html
this took me 5 seconds to find, could you not do that?
|
|
|
|
|
thnks for u help..
that i saw mr and also implemented but iwatn to work like xp login ie for the first time when page is loaded and caps lock is already pressed on...then message to get.
this took me 5 seconds to find, could you not do that? sir after doing this only i got dought and asked the question ...
|
|
|
|
|
so if the page loads, and caps lock is on then you want the message to appear as soon as the page loads rather then when they click to log in?
|
|
|
|
|
I'm not sure if you can do that without them beginning to type
|
|
|
|
|
string filename = "";
try
{
if (((FileUpload)EmployeeDetailsView.FindControl("FUploadCVInsert")).HasFile)
{
filename = System.IO.Path.GetFileName(((FileUpload)EmployeeDetailsView.FindControl("FUploadCVInsert")).PostedFile.FileName);
((FileUpload)EmployeeDetailsView.FindControl("FUploadCVInsert")).SaveAs(Request.PhysicalApplicationPath + "/Download CV");
}
else
{
filename = ((HiddenField)EmployeeDetailsView.FindControl("HiddenField1")).Value.ToString();
}
}
catch (Exception ex)
{ throw ex; return; }
--------------------------------
iam using this code to save customers cv to specifiy folder on server but i have error 'access deined' instead i give this folder all plivigers for read and write
help me plz
md_refay
|
|
|
|
|
Can you post your file location address that you are posting to?
Sometimes you can release access to a folder which is in another restricted folder, therefore unable to upload file
Try a different folder which is nearer the root and see if that works too
|
|
|
|
|
not an answer to your question but a bit of advice; rather than continuously evaluate the FindControl and casting it to FileUpload do it once at the beginning and use that throughout. It is not only more efficient, but makes your code much more readable!
string filename = "";<br />
FileUpload fileUpload = (FileUpload)EmployeeDetailsView.FindControl("FUploadCVInsert");<br />
try<br />
{<br />
if (fileUpload .HasFile)<br />
{<br />
filename = System.IO.Path.GetFileName(fileUpload.PostedFile.FileName);<br />
fileUpload.SaveAs(Request.PhysicalApplicationPath + "/Download CV");<br />
}<br />
else<br />
{<br />
filename = ((HiddenField)EmployeeDetailsView.FindControl("HiddenField1")).Value.ToString();<br />
}<br />
}<br />
catch (Exception ex)<br />
{ throw ex; return; }
|
|
|
|
|
Dear All
I have not idea if this posting is sagacious or facitious.I have to delete the old entries of my table according to date automatically, how can I achive this(from asp.net and sqlserver)?
Any logic/Idea/links/comments and suggestions are highly accepted.
|
|
|
|
|
Hi,
1. You can use Sql Server's Job functionality for performing any operation to Database as per time interval.
2. Windows Service.
Naresh Patel
|
|
|
|
|
Dear Naresh
I cannot use Windows service because it is an web application.
|
|
|
|
|
My project using backend as Mysql 5.0 and i use DSN to create the connection string . my question is how use Remote Mysql DSN as connection string object in Web.Config File for Hosting.
Thnx,
Prabu
|
|
|
|
|
my error,
The specified display mode is currently disabled on this page. Make sure personalization is enabled for the current user.
Parameter name: value
i am using webpartmanager . my code WebPartManager1.DisplayMode = WebPartManager.EditDisplayMode;
so if u know the answer reply to me....
|
|
|
|
|
can you put up the entire code?
This could be an issue with users logging in
|
|
|
|
|
 thank you..
c# coding:
using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
string s;
s = Convert.ToString(Session["Adminname"]);
if (s.ToString() != "")
{
WebPartManager1.DisplayMode = WebPartManager.EditDisplayMode;
//WebPartManager1.DisplayMode = WebPartManager.EditDisplayMode;
WebPartZone1.HeaderText = " ";
WebPartZone2.HeaderText = " ";
}
}
protected void Page_Prerender(object sender, EventArgs e)
{
if (WebPartManager1.SelectedWebPart != null)
{
Hidden1.Value = WebPartManager1.SelectedWebPart.ID;
}
}
}
design:
]]>
]]>
]]>
<title>Untitled Page
function MoveEditorPart()
{
if(document.getElementById('EditorZone1')!= null)
{
var control = document.getElementById('Hidden1').value;
var oTr = document.getElementById('WebPart_'+control).insertRow(1);
var oTd = oTr.insertCell();
oTd.appendChild(document.getElementById('EditorZone1'));
}
}
<asp:webpartmanager id="WebPartManager1" runat="server">
<asp:webpartzone width="440px" id="WebPartZone1" runat="server" bordercolor="#FF8080">
BorderStyle="NotSet" BorderWidth="" Font-Names="Verdana" Padding="6" PartChromeType="TitleAndBorder"
WebPartVerbRenderMode="TitleBar" ShowTitleIcons="False" EmptyZoneText="">
<partchromestyle backcolor="#F7F6F3" bordercolor="#FF8080" font-names="Verdana" forecolor="White">
BorderWidth="1px" />
<closeverb visible="False">
<minimizeverb visible="true">
<menulabelhoverstyle forecolor="#E2DED6">
<emptyzonetextstyle font-size="0.8em">
<menulabelstyle forecolor="White">
<menuverbhoverstyle backcolor="#F7F6F3" bordercolor="#CCCCCC" borderstyle="Solid">
BorderWidth="1px" ForeColor="#333333" />
<headerstyle font-size="0.7em" forecolor="#CCCCCC" horizontalalign="Center">
<zonetemplate>
<uc1:welcomeusercontrol id="WelcomeUserControl1" runat="server">
<menuverbstyle bordercolor="#5D7B9D" borderstyle="Solid" borderwidth="1px" forecolor="White">
<partstyle font-size="0.8em" forecolor="#333333">
<titlebarverbstyle font-size="0.6em" font-underline="False" forecolor="White">
<menupopupstyle backcolor="#5D7B9D" bordercolor="#CCCCCC" borderwidth="1px" font-names="Verdana">
Font-Size="0.6em" />
<parttitlestyle backcolor="#5D7B9D" font-bold="True" font-size="0.8em" forecolor="White">
| <asp:webpartzone width="440px" id="WebPartZone2" runat="server" bordercolor="#FF8080">
BorderStyle="NotSet" BorderWidth="" Font-Names="Verdana" Padding="6" PartChromeType="TitleAndBorder"
WebPartVerbRenderMode="TitleBar" ShowTitleIcons="False" EmptyZoneText="">
<partchromestyle backcolor="#F7F6F3" bordercolor="#FF8080" font-names="Verdana" forecolor="White">
BorderWidth="1px" />
<closeverb visible="False">
<minimizeverb visible="true">
<menulabelhoverstyle forecolor="#E2DED6">
<emptyzonetextstyle font-size="0.8em">
<menulabelstyle forecolor="White">
<menuverbhoverstyle backcolor="#F7F6F3" bordercolor="#CCCCCC" borderstyle="Solid">
BorderWidth="1px" ForeColor="#333333" />
<headerstyle font-size="0.7em" forecolor="#CCCCCC" horizontalalign="Center">
<zonetemplate>
<uc2:webusercontrol id="WebUserControl1" runat="server">
<menuverbstyle bordercolor="#5D7B9D" borderstyle="Solid" borderwidth="1px" forecolor="White">
<partstyle font-size="0.8em" forecolor="#333333">
<titlebarverbstyle font-size="0.6em" font-underline="False" forecolor="White">
<menupopupstyle backcolor="#5D7B9D" bordercolor="#CCCCCC" borderwidth="1px" font-names="Verdana">
Font-Size="0.6em" />
<parttitlestyle backcolor="#5D7B9D" font-bold="True" font-size="0.8em" forecolor="White">
|
<asp:editorzone id="EditorZone1" runat="server" backcolor="#FFFBD6" bordercolor="#CCCCCC">
BorderWidth="1px" Font-Names="Verdana" Padding="6" ForeColor="Black" Font-Size="10pt">
<headerstyle backcolor="#FFCC66" font-bold="True" font-size="0.8em" forecolor="#333333">
<labelstyle font-size="0.8em" forecolor="#333333">
<headerverbstyle font-bold="False" font-size="0.8em" font-underline="False" forecolor="#333333">
<partchromestyle bordercolor="#FFCC66" borderstyle="Solid" borderwidth="1px">
<partstyle bordercolor="#FFFBD6" borderwidth="5px">
<footerstyle backcolor="#FFCC66" horizontalalign="Right">
<edituistyle font-names="Verdana" font-size="0.8em" forecolor="#333333">
<instructiontextstyle font-size="0.8em" forecolor="#333333">
<errorstyle font-size="0.8em">
<verbstyle font-names="Verdana" font-size="0.8em" forecolor="#333333">
<emptyzonetextstyle font-size="0.8em" forecolor="#333333">
<parttitlestyle font-bold="True" font-size="0.8em" forecolor="#333333">
i am using webusercontrol if i write webconfig code error on this page.so help me...
|
|
|
|
|
sorry I havent got much experience of any of these tags before.
try these places as they have people who have had the same error
http://forums.asp.net/p/1043371/1457747.aspx
http://geekswithblogs.net/chrishan/archive/2005/07/20/47799.aspx
http://www.oreillynet.com/cs/user/view/cs_msg/72000
|
|
|
|
|
i used wizard control in aspx page in visualstudio2005 c# that has defualt next and previuse button , i want disable it . can i?
|
|
|
|
|
Do you mean youve created two buttons and want to disbale them? if so asp:button enable=false
or do you mean the button is set as the default control on the page?
if so change the default button in the form tag
|
|
|
|
|
secend part is my mean. i think i should use javascript and i can not acsses the button. wizard control is a control in visualstudio2005 web form, it hase button i want disable it.
|
|
|
|