|
Hi friend,
i used this code to display the menuitem by horizontally. But it displays only vertically. Could you help me to display horizontally please.
Example Here "Open" and "New" display only by vertically. But i need to display by HORIZONTALLY.
Please my guys help me.
<asp:Menu ID="Menu1" runat="server" Orientation="Horizontal">
<Items>
<asp:MenuItem Text="File" Value="File">
<asp:MenuItem Text="Open" Value="Open"></asp:MenuItem>
<asp:MenuItem Text="New" Value="New"></asp:MenuItem>
</asp:MenuItem>
<asp:MenuItem Text="edit" Value="edit">
<asp:MenuItem Text="Copy" Value="Copy"></asp:MenuItem>
</asp:MenuItem>
</Items>
</asp:Menu>
|
|
|
|
|
Hi Friends
I am using Ajax in C#.NET.
I have recently noticed that. I cannot fire Messagebox(Javascript-JS) if inside Update Panel.
I am using Update Panel on my GridView.
Only click of Delete Button i am firing one JS asking "Are You Sure"
My Code
LinkButton l = (LinkButton)e.Row.FindControl("lbtnDelete");
l.Attributes.Add("onclick", "javascript:return " +
"confirm('Are You Sure You want to Delete ? ')");
The Above Code works perfectly. But then i make a DataBase Check if that Record is used anywhere else.
So its like
if(CheckRecord)
Response.Write("<script>alert('Are you sure youw want to Continue?')</script>");
It doesnt work.
i tired another dll for msgbox, which also doesnt work.
I suspected for the Update panel. And i was right. If i remove the Update Panel both the options fire MessageBox for me.
But i am using Edit,Delete,AddNew methods in GridView henceforth i need Update Panel.
Now i have no Idea what should i do?
Any solutions would be appreciated.
Thanks
-- modified at 8:22 Friday 2nd November, 2007
Cheers
Menon
|
|
|
|
|
Menon,
You cannot use Response.Write while using Microsoft AJAX, since the page will not postbacks fo your request. You can use Client Script of the Microsoft AJAX.
Add handler for endRequest like below,
Sys.WebForms.PageRequestManager.getInstance().add_endRequest(CheckRecordCallBack);
CheckRecordCallBack(sender, arg){
if (args){
if (args.get_error()){
args.set_errorHandled(true);
alert(args.get_error().message);
}
}
}
You must throw the Message which you want to show after CheckRecord process from the CodeBehind.
For more reference, read http://www.asp.net/ajax/documentation/live/ClientReference/default.aspx[^]
|
|
|
|
|
Hi Venkatesh
Thanks for the reply i will try it.
I even found another solution for my question.
ScriptManager.RegisterStartupScript
This also works.
Thanks
Cheers
Menon
|
|
|
|
|
I want to image verification on my user registration asp.net forum. And I must be check between entered user verification code and image. So I need store code which on the image. If user click the button so page is post back and stored code is null. In this case I must be use viewstate (or session variable).
My question is viewstate value maybe stolen by bot. So Is it reasonable using viewstate variable for this process?
Do you have any idea?
Best Regards...
|
|
|
|
|
dataminers wrote: My question is viewstate value maybe stolen by bot.
I don't think so. Viewstate value can be tampered easily. So it's not recommended to keep sensitive information over there.
|
|
|
|
|
Ok, What is your recomendation?
|
|
|
|
|
Hi all,
I am working on web application there is some session timeout problem when it was deployed
In deployment server , while navigating to any of the page in the
application(Website) , it's going to login page(Irrespective of any requested page). But it is working fine in my local machine.
since
Session time out is 20 mins in web.config file.
any suggestions ??
Thanks&Regards
sarankumarv
Thanks&Regards
sarankumarv
|
|
|
|
|
because of server.its happenning like.
|
|
|
|
|
sorry to say this i am not able to get the answer u have posted can u explain in detail for me
Thanks&Regards
sarankumarv
|
|
|
|
|
I would check two things:
- Machine.config settings.
- Is session enabled on the server ?
HTH
/// -------------------------
Braulio Díez
tipsdotnet.com
/// -------------------------
|
|
|
|
|
Hi there,
We're getting ready to move onto ASP.NET 2 websites/webapps, and need some options on a reporting tool or controls that people use...
Don't want to use Crystal Reports due to their horrendous licensing fees, and have looked at DevExpress's XtraReports Suite and also ActiveReports by Data Dymanics, but can't decide
Any help greatly appreciated! We're (obviously!) looking for the best tool for the cheapest price.
Cheers!
Baz
|
|
|
|
|
you can use Reportviewer..
|
|
|
|
|
Err yeah I suppose we could, but I thought it was lacking in features that other 3rd party controls have (but that could just be my ignorance, as I have no real experience of using it - would be happy to find out more though...)
Baz
|
|
|
|
|
hello every buddy
suppose i have a checkboxlist containg 10 items.
and i want to select 2 items at a time then how can i ristrict it.
and also how can i show the messege related to restriction
rajeev kumar sharma
vri software pvt. ltd.
new delhi India
|
|
|
|
|
You need to write all of this in javascript, because you want it to happen on the client side. There's nothing built in to do it. you can handle the data bound event of the checkboxlist to inject attributes on the control, which is how you would handle the click or check changed events in order to fire your scripts. Then, you can just keep track of the ids of items that have been clicked and which ones are checked in your script and show a message if a third is clicked on.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
no no.
actualy i am showing messege througt javascript but i want to get the id of the checkbox for restrict the check if user has allready completed max checks.
rajeev kumar sharma
vri software pvt. ltd.
new delhi India
|
|
|
|
|
I think this will work for u.
Dim i As Integer
For Each item As ListItem In CheckBoxList1.Items
If item.Selected Then
i = i + 1
End If
Next
If i > 2 Then
lblmsg.Text = "Thanks"
Else
lblmsg.Text = "Please Select atleast two items"
End If
God is always with you.
|
|
|
|
|
sorry this code can restrict only the number or selection but suppose i had select 2 and 7 item from the checkboxlist and i m selecting the 4th item in the list then how can i restrict for selection but server side code will post back the page so i want to do this with the javascript
rajeev kumar sharma
vri software pvt. ltd.
new delhi India
|
|
|
|
|
Hi Everyone,
Is it possible to have thousand seperators and currency format in a datagrid. Can anyone help me in this regard.
Regards,
Manowj
|
|
|
|
|
Yes, just define them in your column definitions for the grid, by using ToString on the data items you're showing with a formt string.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Paste below function into .VB file
Function IndiaRupees(ByVal rs As String)
Dim str As String = ""
str = Right(rs, 3)
rs = Left(rs, IIf(rs.Length > 3, rs.Length - 3, 0))
While rs <> ""
str = Right(rs, 2) & "," & str
rs = Left(rs, IIf(rs.Length > 2, rs.Length - 2, 0))
End While
IndiaRupees = "Rs. " & str
End Function
In Datagrid's Item Databound
Dim lbl_Amt As Label<br />
lbl_Amt = IndiaRupees(CType(e.Item.FindControl("lbl_Amount"), Label).Text)
Prakash Samariya
|
|
|
|
|
Hi friens,
I could display several menuitems by vertically and horizontally for SINGLE menu.
But My problem is i want to display MULTIPLE menus(Eg:3 menu) as a headers then i have to display several menuitems by HORIZONTALLY for each menu.
Please help me..
|
|
|
|
|
Use Menu Control from asp.net.and set the properties for the Vertical and horizontal display.It' easy
|
|
|
|
|
Hi Friend,
Please give me with simple example.I couldn't find. Please..
-- modified at 7:50 Friday 2nd November, 2007
|
|
|
|