Access Row In Telerik Grid In MVC2 Application?
Dec 27, 2010
I am using telerik grid in mvc2 application. I have to perform Watin UI test for my application. For that i need to select a row from the telerik grid. I was not able to select id for the telerik grid as the telerik grid doesn't have any id. can u please help me to select the particular row from the grid. I have 6 columns in the grid. Based on the value of a row in the column(should iterate though the column) i need to select the id of that row and hit on the select button of that row.
View 1 Replies
Similar Messages:
Jan 14, 2011
My grid has 5 data columns and 1 command column (update/delete)the column separator between command column and last data column is missing, making everything shift when entering inline edit mode.
this is the grid's view code:
<%=
Html.Telerik().Grid<ActivityPOCO>()
.Name("ActivityGrid")
.DataKeys(dataKeys =>
{
dataKeys.Add(e => e.ActivityID);
}
.ToolBar(commands => commands.Insert().ButtonType(GridButtonType.Image))........
View 1 Replies
Oct 20, 2010
[Code]....
And in a submit button click event,I am writting the following code:ut,the problem is:I am gettting null for ChannelNumber,ServiceID,TransponderID,NetworkID,i.e.,not being able to access the values entered in those respective textboxes.Where am I going wrong?Do I need to write the same code in diff event?or diff code in diff event
View 1 Replies
Sep 15, 2010
I'm developing a MVC2 application and using Forms Authentication on it. The scripts, images and styles are all blocked to unlogged users and, consequently, the login page looks awful. It works well local, the problem is when I publish to the server. Does anyone has any idea WHY? The server IIS is version 7.5
<configuration>
<system.web>
<globalization culture="pt-BR" uiCulture="pt-BR" />
<httpRuntime requestValidationMode="2.0"/>
<customErrors mode="Off" />
<compilation debug="true" targetFramework="4.0">
<assemblies>
<add assembly="System.Web.Abstractions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Web.Routing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Web.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
</assemblies>
</compilation>
<pages>
<namespaces>
<add namespace="System.Web.Mvc" />
<add namespace="System.Web.Mvc.Ajax" />
<add namespace="System.Web.Mvc.Html" />
<add namespace="System.Web.Routing" />
<add namespace="Admin.Models" />
</namespaces>
</pages>
<authentication mode="Forms">
<forms name="AGAuth" loginUrl="~/Home/Login" timeout="120" />
</authentication>
</system.web>
<system.webServer>
<validation validateIntegratedModeConfiguration="false"/>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0" newVersion="2.0.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
<connectionStrings>
<add name="DBContainer" connectionString="metadata=res://*/Database.DB.csdl|res://*/Database.DB.ssdl|res://*/Database.DB.msl;provider=System.Data.SqlClient;provider connection string="Data Source=thewebserver.com,5158;Initial Catalog=thedatabase;Persist Security Info=True;User ID=theuser;Password=thepassword;MultipleActiveResultSets=True"" providerName="System.Data.EntityClient" />
</connectionStrings>
</configuration>
View 9 Replies
Nov 22, 2010
I have a telerik grid with a checkbox. I am using a client template. There is a .DataBinding Ajax call attached. When the grid initially comes up, instead of a checkbox, it has the id value as text.If I hit refresh, the ajax call gets executed and when it comes back the checkbox appears. Is there any way to force the ajax call to happen when the grid initially paints so that I have a checkbox and not text..
View 1 Replies
Dec 15, 2010
How can i pass asp.net mvc telerik grid data to controller using Ajax call.I need to save the telerik MVC grid data in database.
View 2 Replies
Sep 3, 2010
Currently i am using Telerik grid which filters are applied to each column. I am binding the SQL result set to grid. If the result set is empty from the database while binding, I should disable the filter option in the grid.
How can i achive the same through ASPX or Code behind using C#. Does Telerik Grid have any property to disable the filtering option when thre are no records.
View 2 Replies
Nov 18, 2010
Currently i am using Telerik grid which filters are applied to each column. I am binding the SQL result set to grid. If the result set is empty from the database while binding, I should disable the filter option in the grid.
How can i achive the same through ASPX or Code behind using C#. Does Telerik Grid have any property to disable the filtering option when thre are no records.
View 1 Replies
Apr 24, 2010
Again a question about RadioButtons/ RadioButtonList
I've the following Model:
public class SkillLevelModel
{
public long? Id { get; set; }
public int? SelectedLevel { get; set;}
}
I've the following Controller:
public class SkillController : BaseController
{
public ActionResult Index()
{
var skills = new List<SkillLevelModel>();
for (int i = 0; i < 10; i++)
skills.Add(new SkillLevelModel() { Id = i, SelectedLevel = new Random().Next(0,5) });
return View(skills);
}
I've the following code in the View:
<% foreach (var item in Model) { %>
<tr>
<td style="width: 30px" align="center">
<%= Html.Encode(item.Id) %>
</td>
<td>
<% Html.RenderPartial("UCSkillLevel", item); %>
</td>
</tr>
<% } %>
I've the following code in the PartialView:
<% for (int i = 0; i <= 5; i++) { %>
<td align="center">
<%= Html.RadioButton("SelectedLevel", i, new { id = Model.Id + "_" + i })%>
</td>
<% } %>
The problem is that no radiobutton is checked, althought they have a level.
View 2 Replies
May 12, 2010
I've introduced the (awesome) grid control and got it working fine on my dev environment.I deployed my site to my local dev server and got the following error:
[Code]....
View 4 Replies
Oct 25, 2010
What im trying to do is have an edit button that instead of opening the line for editing, it forwards you to a page where you can edit. Is this possible? I tried something with the client template, but the grid render is ignoring it completely.
View 1 Replies
Dec 16, 2010
I have the following markup in a 'content' page. Without the Render call, nothing renders, and with the Render call, the grid renders as the first element in the whole page, not inside the 'content' section defined by my view:
@using Telerik.Web.Mvc.UI
@model Outdoor.Mvc.ViewModels.OutdoorSite.SiteList
@{
Html.Telerik().Grid(Model.ItemList).Name("Site Grid")
.Columns(columns =>
{
columns.Bound(o => o.SiteId);
columns.Bound(o => o.Name);
})
.Pageable()
.Sortable()
.Render();
}
View 1 Replies
Apr 20, 2010
Is it possible to add client side validation to the fields of the Telerik MVC Grid at runtime. I am having validation JSON strings stored in the DB which I need to use when inserting or updating content
View 1 Replies
Apr 16, 2010
I need the capability to display a chart, click on a region and display the details in a jqgrid on the same page. I tried using a pie Chart and I can't seem to capture or create a click event for the chart. The data points contain a .url property which I can redirect to a different page but I need to display details on the same page like a master-detail page.
View 3 Replies
Aug 1, 2010
is it possible ro insert grid inside a panelbar i try this but i have some errorsi define a grid in the inctructuion .content()
View 1 Replies
Mar 8, 2011
I have a Telerik grid. For each row there is a details table. The row is of type NominationTypeClass and the rows in the details table is of type Nomination. So what this means for each nomination type there is a list of nominations. The grid's code:
<telerik:RadGrid
AllowPaging="true"
AllowSorting="true"
AutoGenerateColumns="false"
GridLines="None"
ID="rgMyNominations".......
I have an action column that has a link that says Withdrawn. When clicked I have a JavaScript confirm box with a Yes or No option. If yes, then the nomination status is updated to withdrawn. Then I want the grid to be refreshed to show the updated status. I used the grid's update command to to show the show the JavaScript's command box. It updates, but is it the correct way to do it?
protected void rgMyNominations_UpdateCommand(object source, GridCommandEventArgs e)
{
try
{
StatusManager.InsertStatus( /* required parameters */ );
// Refresh grid
rgMyNominations.DataSource = GetNominationTypes();
rgMyNominations.DataBind();.....
...it says that NominationDate is not a property of NominationTypeClass. This is wrong, I don't know why it is taking the type for the row to be the type of the details table? NominationDate is a property of Nomination. It seems like it is overriding the datasources.
View 1 Replies
Dec 21, 2010
Problem: How to display more columns in a Telerik grid than are displayed in the rendered grid?
eg I'd like to only display on the screen the Surname, but on dump to csv would like firstname too.
I've tried visible = false, and display = false on the GridBoundColumns, but then they don't come out on the csv.
<telerik:RadGrid ID="grdAuctions" runat="server" AllowAutomaticDeletes="True" AllowAutomaticUpdates="True"
AllowPaging="False" AllowSorting="True" AutoGenerateColumns="False" DataSourceID="odsAuctionSales"
GridLines="None" EnableEmbeddedSkins="False" OnItemDataBound="grdAuctionSales_ItemDataBound">
<ExportSettings HideStructureColumns="true" />
[Code]....
View 2 Replies
Jun 15, 2010
i m using Telerik grid to present memos received by user below is the code
[Code]....
where i m binding third column (Subject) my intention is to make an ActionLink where subject is the display text and i want a dynamic ID coming from <#=MemoID#>. memo id is working fine and gives me a link with dynamic Memo IDs. the problem is with the subject i.e ("<#=Subject#>") is rendered as it is on the screen without mapping to the actual subject of the memo. i have also tried ("<%#=Subject%>") but to no gain.
View 12 Replies
May 17, 2010
I have a telerik grid bound to a Linq data object, however, I limit the fields returned:
<IQueryable>filter = data.Select(x => new {x.ID, x.Name, x.Age});
I would like to access these fields in the ItemCreated method of the grid:
protected void rgPeople_ItemCreated(object sender, GridItemEventArgs e)
{
Telerik.Web.UI.GridDataItem item = (GridDataItem)e.Item;
?????? Person = (???????)e.Item.DataItem;
}
What do I declare ?? as so that I can use:
String ID = Person.ID;
String Name = Person.Name; etc
View 2 Replies
May 25, 2010
I wanted to ask what is the best practice to manage width of the radGrid.
For my application most users are running 1280 x 1024 so I would be happy to set my overall grid width to 1100. However, depending on the form in use, I sometimes have horizantal scroll bars. To solve this, I have been playing with the width of the grid, and also I have played with setting the itemstyle-width for one or two columns. Sometimes I accidentally get it right, and sometimes it is not quite right.
What is the best way to manage this? Do I set the grid, and then all columns, or just the grid, or just the columns? I guess there is a best practice, so just wondering how you handle it,
View 2 Replies
Jun 29, 2010
I want to select the row of telerik radgrid and get the value of column 1For thi can't use select or deselect columns, Here i want to select row by clicking only.here I also require code to get the value of column 1 of selected row
View 4 Replies
Dec 3, 2010
I am using telerik grid. I need to apply a filter for all the columns in my grid. Currenly I am customizing the filter option using the following code. By using the following code, I am removing the certain items for all the columns. But, for a date column what are the possible options for filtering in the grid and how to customize those filtering options?
Code Behind
protected void RGVTest_Init(object sender, EventArgs e)
{
GridFilterMenu menu = RGVTest.FilterMenu; [code]....
View 1 Replies
Apr 2, 2011
I am facing serious problem while trying to work in clientevents provided with asp.net mvc telerik grid.
Here's the two different scenarios:When I am putting the following script in a view or partial view it works fine;
<%= Html.Telerik().Grid()
.Name("Grid")
.DataKeys(keys => keys.Add(p => p.StaffId))
[code]...
View 1 Replies
Oct 30, 2010
I am trying to use this solution to access items inside a telerik menu item:
ascx code:
<asp:Label ID="DivLeave" runat="server"></asp:Label>
In the ascx.cs file I run this code to disable the asp label
RadMenuItem expenses = RadMenu1.FindItemByText("Expenses");
Label DivLeave = (Label)expenses.FindControl("DivLeave");
DivLeave.Visible = false;
but I get this error when I try to run the code:
{"Object reference not set to an instance of an object."}
I really need to run this server side as code surrounding the above code does some work server side and it will all fit in neatly...
View 2 Replies
Mar 1, 2011
how can i connect mySql to my mvc application
i need a tutorial and all steps to connect to mySQL
View 1 Replies