|
hi
i want to get current month in three letter format .Like my string value return 'Oct'
Jintal Patel
|
|
|
|
|
u can use..select cast(Datename(month,getdate(),varchar(3)) from tablename..it will work.
Rajendran
|
|
|
|
|
Try this it help u
select cast(Datename(month,getdate()) as varchar(3))
|
|
|
|
|
str = Format(Date.Today, ("MMM"))
Regards - J O H N -
|
|
|
|
|
This will get the current month for you. The important bit is the ToString("MMM") which formats the month. Create a label control and name it Label1 then add this code:
Label1.Text = DateTime.Today.ToString("MMM");
Enjoy.
|
|
|
|
|
This sounds like the answer of an Eagles/Clapton fan. High 5 for you sir.;)
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
hi
this gives me the some other language text...
Jintal Patel
|
|
|
|
|
System.DateTime.Now.ToString("MMM");
i think it will work.
and u can apply it to any other DateTime object
regards
|
|
|
|
|
Hi,
I have a serious problem while using required field validator..
in my page i have one dropdown and one textbox for the textbox i used requiredfiled validator .when loading the page first time i can see the validation control and everything works properly..but in the second time i can't see the validation control even if the the validation is failed ie, textbox is empty.....how can i show that validator to the clients..pls anybody give me a help..
regards
alex.
|
|
|
|
|
Alex,
if you dont bother can you please show a portion of the code. Validations are always fired when a postback happens.
Many thanks,
Balamurugan
|
|
|
|
|
yes ok..but the problem is that validation is taken place in the background..but can't see the message
|
|
|
|
|
can you tell me what is Display property of validator control?
bEst Regard
pAthan
please don't forget to vote on the post that helped you.
|
|
|
|
|
I mean error message can't see..if the validation fails ..
|
|
|
|
|
my code like
<asp:textbox runat="server" textmode="MultiLine" maxlength="4000" id="txtComments"
="" width="450px">
<asp:requiredfieldvalidator id="RequiredFieldValidator1" controltovalidate="txtComments"
="" runat="server" errormessage="*">*
|
|
|
|
|
Your Code Like Following?
<asp:DropDownList ID="test" runat ="server" >
</asp:DropDownList>
<asp:TextBox ID="Test1" runat ="server" >
</asp:TextBox>
<asp:RequiredFieldValidator ID="Validator1" runat ="Server" ControlToValidate ="Test1" SetFocusOnError ="true" Display ="None"
ErrorMessage ="Enter the value" ValidationGroup ="Testing"></asp:RequiredFieldValidator>
<asp:Button ID="btn" runat ="server" Text ="Enter" />
<asp:ValidationSummary ID="valide" runat ="server" ShowMessageBox ="True" ShowSummary ="false" ValidationGroup ="Testing" />
|
|
|
|
|
<asp:textbox runat="server" textmode="MultiLine" maxlength="4000" id="txtComments"
="" width="450px">
<asp:requiredfieldvalidator id="RequiredFieldValidator1" controltovalidate="txtComments"
="" runat="server" errormessage="*">*
|
|
|
|
|
<asp:textbox runat="server" textmode="MultiLine" maxlength="4000" id="txtComments"
="" width="450px">
<asp:requiredfieldvalidator id="RequiredFieldValidator1" controltovalidate="txtComments"
="" runat="server" errormessage="*">*
|
|
|
|
|
Response.Redirect("abc.aspx?ID=" + ((TextBox)row
.FindControl("TextBox1")).Text);
the abve code which u have given is not working...
the receiving(the page has to be redirect to this page) page i have given the command like..
lbl1.Text= Request.QueryString["txt1"];
In the redirection page i have given in html page by binding textbox and redirecting to the new page, its redirecting but not values are redirecting in the new page.
Can u pls fix my issue...
krishna
|
|
|
|
|
For example we can take a site like online shopping.....
FROM a b c d....z
If we click a all the products starting form a is displaying its working, after that if we click any product name than it should display a details of that particular product in details in a different page or in a same page....this is the logic....
krishna
|
|
|
|
|
hi,
have U tried the following code..U check the txt1 is control id or not.Plz try..not sure
lbl1.Text= Request.QueryString["txt1"].ToString();
-- modified at 8:07 Tuesday 30th October, 2007
Rajendran
|
|
|
|
|
krishnavaradharajan wrote: Response.Redirect("abc.aspx?ID=" + ((TextBox)row
.FindControl("TextBox1")).Text);
krishnavaradharajan wrote: lbl1.Text= Request.QueryString["txt1"];
You've called the parameter you're passing on the querystring "ID", not "txt1". You should have
<br />
lbl1.Text= Request.QueryString["ID"];
|
|
|
|
|
Can we upload a file to the application server using webclient?
If yes can plz give me the sample code.
|
|
|
|
|
System.Net
WebClient Client = new WebClient();
Client.UploadFile("http://www.Temp.com/Members/index.aspx",
"c:\wesiteFiles\newfile.aspx");
byte [] image;
//code to initialise image so it contains all the binary data for some jpg file
client.UploadData("http://www.Temp.com/Members/images/logocc.jpg", image);
|
|
|
|
|
hi frns
asp:HyperLink ID="HyperLink1" runat="server" ToolTip="Download" NavigateUrl='~\Feedback\'
/asp:HyperLink
i removed triangle bracket bcoz if i keep them the code i mentioned above is becomming invisible
i want one of my column in gridview with hyperlink value so i used the above snippet in my code, the actual functionality i want is when i click on the hyperlink button i want that particular file to be opened, so in the navigate url attribute i used "'~\Feedback\ + <%#Eval(QAFilename)%> +'" upto feedback path it is fixed i want to add the filename dynamically but it is not working can anybody suggest me
regards
sunil
|
|
|
|
|
i.e in runtime when u bind grid.
Devjit Das.
|
|
|
|