|
you need to replace your html radio button with asp radio button
<asp:RadioButton ID="gvradio1" runat="server" />
|
|
|
|
|
but in these case the radio button will allow mutiple check but i need to restrict to select one only.
KaKaShi HaTaKe
|
|
|
|
|
Try setting
<input type="Radio" name="gvradio" id="gvradio1" runat=server> ;
|
|
|
|
|
Hai,
I am using Master Pages and content Pages to design my website. Inside the content Page i have Form with textboxes. To validate the text boxes in client side, I am using Jscript. But when controls are placed inside the content page the Id of the controls are changed as follows "txtPwd" to "ctl00_CPH_txtPwd".Due to this i can't able to access the controls in client side. I am inneed of an immediate solution to solve this problem.
Can you help me in solving this issue.Thanks in advance.
|
|
|
|
|
Can you use validation controls, for validations.
|
|
|
|
|
|
Thank you SeMartens for your immediate response,I would be more useful. If you provide a simple sample about how to access the controls in client side.
|
|
|
|
|
How do you attach the validation to the controls? If you have sth like a client-side event attached to the controls you can do sth like this:
ASP-Code
myTextbox.Attributes("onclick", "javascript:validateTextbox('" + myTextbox.ClientID + "')");
and the javascript will look like this:
validateTextbox(clientID) {
var control = document.getElementByID(clientID);
}
|
|
|
|
|
you can either read it this way
document.getElementById("<%=Button1.ClientID%>")
or
set the master page id in page load of master page like this
this.ID = "MyID";
then your control id will be
MyID_contentplaceholderid_controlid
also keep in mind that clientid wont work in js files
|
|
|
|
|
Use
document.getElementById ("<%=TextBox1.ClientId%>").value
|
|
|
|
|
How can I move between asp pages and change the first page?
|
|
|
|
|
This place is like a sheltered workshop.
What the hell do you mean by 'move between'. Do you mean Response.Redirect ? Why are you asking questions when you plainly have not done ANYTHING to learn ASP.NET, assuming that's what you mean when you say ASP. Buy yourself a book.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Christian Graus wrote: This place is like a sheltered workshop.
It is getting worse day by day.
BTW, happy to see you back in action
|
|
|
|
|
I hav Created Custom control using AJAX Calender and Textbox.Class Inherits Webcontrol .I am not able to Call TextChanged Event of Textbox. If any body Knows answer Plz Help.
|
|
|
|
|
What do you mean, you can't 'call' an 'event' ? The answer is that you should read the guide to asking good questions, and consider why it is that you expect us to be able to help based on the lack of information you've provided.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Hi There,
I had generated tree by using XMLData Source.When I try to fire Menu Click event it is not get fired.Whats the problem can anybody please tell me.
Thanks.
|
|
|
|
|
The problem is in your code. Hard to say more, based on what you posted.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Thanks For Reply
This My XML File
////////
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" indent="yes" encoding="utf-8">
<xsl:template match="/Menus">
<menuitems>
<xsl:call-template name="MenuListing">
<xsl:template name="MenuListing">
<xsl:apply-templates select="MENU_TREE_STRUCTURE">
<xsl:template match="MENU_TREE_STRUCTURE">
<menuitem>
<xsl:attribute name="Text">
<xsl:value-of select="MTS_GUID_DESC">
<xsl:attribute name="ToolTip">
<xsl:value-of select="MTS_GUID_DESC">
<xsl:attribute name="NavigateUrl">
<xsl:value-of select="MTS_GUID">
<xsl:if test="count(MENU_TREE_STRUCTURE) > 0">
<xsl:call-template name="MenuListing">
////////////////
I had Written Following Code On Master Pages Page Load Event
///////////////
DataSet ds = new DataSet();
string connStr = "Integrated Security=SSPI;Persist Security Info=False;User ID=pank;Initial Catalog=MARKETING;Data Source=ASP6";
using (SqlConnection conn = new SqlConnection(connStr))
{
string sql = "Select MTS_ID, MTS_GUID_DESC, MTS_GUID, MTS_SUBID from MENU_TREE_STRUCTURE";
SqlDataAdapter da = new SqlDataAdapter(sql, conn);
da.Fill(ds);
da.Dispose();
}
ds.DataSetName = "Menus";
ds.Tables[0].TableName = "MENU_TREE_STRUCTURE";
DataRelation relation = new DataRelation("ParentChild",
ds.Tables["MENU_TREE_STRUCTURE"].Columns["MTS_ID"],
ds.Tables["MENU_TREE_STRUCTURE"].Columns["MTS_SUBID"],
true);
relation.Nested = true;
ds.Relations.Add(relation);
xmlDataSource.Data = ds.GetXml();
if (Request.Params["Sel"] != null)
Page.Controls.Add(new System.Web.UI.LiteralControl("You selected " + Request.Params["Sel"]));
///////////////
This Is My Menu Trees Controls Source Code
///////////////
<asp:menu id="Menu1" runat="server" datasourceid="xmlDataSource" skinid="Menu" orientation="Horizontal" onmenuitemclick="Menu1_MenuItemClick" xmlns:asp="#unknown">
<databindings>
<asp:menuitembinding datamember="MenuItem" navigateurlfield="NavigateUrl" textfield="Text" tooltipfield="ToolTip">
////////////////
Thanks
modified on Friday, January 30, 2009 2:26 AM
|
|
|
|
|
I don't see any click event in this code. I still don't know what you mean, b/c I'd expect to see an event defined, if you think you have one and it's not working.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Thanks For Reply,
By Mistake I sent you my previous code.Now you can see above pasted code.I had updated it.
|
|
|
|
|
Hi There,
If anybody know the answer please help
Thanks
|
|
|
|
|
How to fetch the particular data and store in a variable when that data was clicked?
For example in my repeater i have fields like Id,Name,etc. When i click on the Id field,that particular Id will be stored in a variable so that i can use it for my process? Can anyone give Idea or Code with c#?
|
|
|
|
|
You need to handle the click and then work out what row was clicked. I assume the field is a button or a link, if it's a button, use a button that lets you pass back a command argument, if it's a link, put the value on the URL.
This is very basic stuff, perhaps you should buy a book on ASP.NET ?
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
|
Hi,
As im new to WMI please help me out regarding the problem which is as follows...
WMI connection through asp.net from Computer A(windows 2003 server) to Computer B(Windows XP).
the code is as follows...
ConnectionOptions options = new ConnectionOptions();
options.Username =username;
options.Password = password;
string machinename = "*******";
// Read registry of remote machine....
ManagementScope myScope = new ManagementScope("\\\\" + machinename + "\\root\\default", options);
myScope.Options.EnablePrivileges = true;
myScope.Options.Impersonation = ImpersonationLevel.Impersonate;myScope.Options.Authentication = AuthenticationLevel.Packet;
myScope.Connect();
and the error is as follows
Server Error in '/Skywebadmin' Application.
--------------------------------------------------------------------------------
The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Runtime.InteropServices.COMException: The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[COMException (0x800706ba): The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)]
System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo) +0
System.Management.ManagementScope.InitializeGuts(Object o) +711
System.Management.ManagementScope.Initialize() +162
System.Management.ManagementScope.Connect() +4
sk._Default.Page_Load(Object sender, EventArgs e) +167
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +50
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053
|
|
|
|