|
try this
select distinct convert(char(10),clockin_date,101) from dbo.Stud_ClockIn
and do reply
|
|
|
|
|
|
Its working fine.. What exactly are you using?
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hello friends,
Hello i need ur help.i am a beginner in asp.net(c#) in my work i need to resize the image in the given height and width with out spoiling it's clarity or quality. Can anybody help me to find a solution.waiting 4 ur reply.
alex.
|
|
|
|
|
You may like to have a look at this article:
http://aspnet.4guysfromrolla.com/articles/012203-1.2.aspx
Best Regards,
Apurva Kaushal
|
|
|
|
|
Do not provide height and width of the image. It will appear in its original size iteself.
|
|
|
|
|
Hi,
I want to automatically generate a unique code based on a text field, eg if i type in carrots i want to generate CAR001. Anyone can help, will it work the same in ASP as with normal windows based forms?
|
|
|
|
|
How do you mean in normal windows based forms? You'll need to hold some record somewhere of the already used codes and write a bit of logic to create your code...
|
|
|
|
|
im using ASP.Net 2.0, pretty new to it so not quite sure. im not using the sqldatasource controls. im binding a gridview with a dataset. so id have to first check the dataset? im not to sure. but i want to know if theres an example to generate the ID i was talking about.
|
|
|
|
|
hai
i heard something about digital data board. will anybody able to give any explanation about this.
actually in one of my project i want to dosomething like this. i would like to display the clients monitor in another client browser. its something like remote desktop in XP. anybody knew anything about this.? pls reply. it will be a great help for me. thanks in advance.
|
|
|
|
|
Hi,
how we can generate wizard steps automatically base on variable
for example
when page load check the value of the variable and then crate wizard steps equal to the value of variable and then set the property of each step.
Thanks a ot
|
|
|
|
|
Here is a simple example of programmatically creating wizard steps. The trick is to create the steps in the PreInit event of the page.
<%@ Page Language="C#" %>
<script runat="server">
void Page_PreInit(object o, EventArgs e)
{
string[] data = new string[3] {"What is your name? "
,"What is your quest? "
,"What is your favorite color? "
};
for (int i=0; i<data.Length; i++)
{
WizardStep theStep = new WizardStep();
theStep.ID = "Step" + i.ToString();
theStep.Title = "Step " + i.ToString();
theStep.StepType = WizardStepType.Auto;
Label label1 = new Label();
label1.Text = "<br />" + data[i] + "<br />";
theStep.Controls.Add(label1);
TextBox tb1 = new TextBox();
tb1.ID = "txt" + i.ToString();
theStep.Controls.Add(tb1);
wiz1.WizardSteps.Add(theStep);
}
wiz1.ActiveStepIndex=0;
}
</script>
<html>
<head></head>
<body>
<form runat="server">
<h3>Programmatically Adding Steps to Wizard</h3>
<hr />
<asp:Wizard id="wiz1" runat="server"
DisplaySideBar="true"
HeaderText="Wiz1"
BorderWidth="1" BorderColor="#CCCCCC" BorderStyle="Solid"
StepNextButtonText=" Next >> "
StepPreviousButtonText=" << Previous "
FinishCompleteButtonText=" Done! "
CellPadding="4"
>
<HeaderStyle BackColor="#999999"
ForeColor="#FFFFFF"
HorizontalAlign="center"
Font-Size="12" Font-Bold="True"
/>
<SideBarStyle BackColor="#EFEFEF"
/>
</asp:Wizard>
<hr />
</form>
</body>
</html>
|
|
|
|
|
Hi,
Pls let me know, is there any projects to develop in asp.net , c#
how and where i need to check in codeproject
Regards
muralidhar
Muralidhar
|
|
|
|
|
Hello
I got exception System.nullReferenceException in NUnit, when i use database initialization code.
I am using ASP.Net 2.0 with C#.
There is no error in Code. The same code in VS 2003 has been successfully test by NUNIT.
Plz help me.
|
|
|
|
|
hi,
i m developing a web application using asp.net c#, How to stop saveing my web page on client side.
For example as in yahoomail, when you go back in history of web browser only the login page is there.
please sent me code or online help referance
thanks in advance
please help me
shaleen
|
|
|
|
|
Do you want the history to be cleared or something else?
Best Regards,
Apurva Kaushal
|
|
|
|
|
hi
yes,I want to cleared the history page of my web application and only the login page can be avalable in the history and no other page is save in the browser history
shaleen
|
|
|
|
|
To see the history object in javascript you can have a look at these link:
http://www.irt.org/script/history.htm
and also you can have a look to :
Response.Cache.SetCacheability
through this also you can prevent the page from being cached.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Sir,
Can i programically set the focus on the textbox.Can i write the code in code behind file in vb.net.
PLease Help.
|
|
|
|
|
Yes you can you can use javascript to set the focus and yes that javascript you can write in code behind also. Do you want to do it at load of the page or some other time?
Best Regards,
Apurva Kaushal
|
|
|
|
|
Sir,
At page load .Can u help me by sending some code.
Please help.
|
|
|
|
|
this is the codebehind part:
string str = "<script language='javascript'>";<br />
str += "function Focu(){";<br />
str += "document.getElementById('TextBox3').focus();}<";<br />
str += "/";<br />
str += "script>";<br />
if(!IsStartupScriptRegistered("Test"))<br />
{<br />
Page.RegisterStartupScript("Test",str);<br />
}
And this "Focu" function you have to call in the onload event of the body tag.
Best Regards,
Apurva Kaushal
|
|
|
|
|
In code behind file include this code.
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
setfocus(textboxid,me)
End sub
Private Sub setFocus(ByVal ctrl As Control, ByVal page As Page)
Dim s As String = "<SCRIPT language='javascript'>document.getElementById('" + ctrl.ID + "').focus() </SCRIPT>"
page.RegisterStartupScript("focus", s)
End Sub
Regards,
Raghu
|
|
|
|
|
Hi,
I have a gridview with Edit.After updating gridview again i binddata().
protected void GridView1_RowUpdating(Object sender, GridViewUpdateEventArgs e)
{
int qty;
int p;
int c;
qty = Convert.ToInt32(((TextBox)GridView1.Rows[e.RowIndex].FindControl("TextBox1")).Text);
Label t = (Label)GridView1.Rows[e.RowIndex].FindControl("Label4");
c = Convert.ToInt32(t.Text);
//c = Convert.ToInt32(((TextBox)GridView1.Rows[e.RowIndex].FindControl("TextBox4")).Text);
p = Convert.ToInt32(((Label)GridView1.Rows[e.RowIndex].FindControl("Label5")).Text);
shopcart.updatecartitems(c, p, qty);
binddata();
For BindData() code is
void binddata()
{
int i = Convert.ToInt32(Session["cartid"]);
DataSet ds = shopcart.getitemsfromcart(i);
GridView1.DataSource = ds;
GridView1.DataBind();
}
after updating even iam binding new data to gridview the row is still displaying textbox(with empty)In database the row is updated.but gridview binding not displaying updated data.Gridview displaying textbox with empty.
After editing any command is there like endedit.
Please help me.
Thanks in advance
|
|
|
|
|
I had this problem once before and the way I handled it was to refresh the page after updating the row using Response.Redirect() then add the data binding code in the PageLoad event handler.
Mohamed El Gohary
|
|
|
|