Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
186 views
Hi

i have a Radmap and i am attempting to follow the example on
http://demos.telerik.com/aspnet-ajax/map/examples/functionality/cross-layer-integration/defaultcs.aspx

to get some lines on the map , but despite the Json file existing it just doesnt seem to work whenever the map loads up it doesnt display any points.

The Page Code is
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="LNGRails.aspx.cs" Inherits="Eclipse_Internal_Portal_2.LNG.LNGRails" %>
 
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div class="tup_background">
        <div class="tup_headings" style="width: 100%;">
            <asp:Label ID="Label1" runat="server" Text="LNG Rails"></asp:Label>
            <telerik:RadClientDataSource runat="server" ID="RadClientDataSource1">
                <DataSource>
                    <WebServiceDataSourceSettings ServiceType="GeoJSON">
                        <Select Url="Rails/Rails.Json" DataType="JSON" ContentType="application/json"  />
                    </WebServiceDataSourceSettings>
                </DataSource>
            </telerik:RadClientDataSource>
            <telerik:RadAjaxPanel ID="RadAjaxPanel1" runat="server" LoadingPanelID="RadAjaxLoadingPanel1" EnableAJAX="true">
                <div>
                    <telerik:RadMap ID="RadMap1" runat="server" Skin="Vista" AppendDataBoundLayers="true" AppendDataBoundMarkers="true">
                        <LayersCollection>
                            <telerik:MapLayer Type="Shape" ClientDataSourceID="RadClientDataSource1" Opacity="0.7">
                                <StyleSettings>
                                    <StrokeSettings Color="Black" Width="200" />
                                </StyleSettings>
                            </telerik:MapLayer>
                            <telerik:MapLayer Type="Tile" Subdomains="a,b,c"
                                UrlTemplate="http://#= subdomain #.tile.openstreetmap.org/#= zoom #/#= x #/#= y #.png"
                                Attribution="© <a href='http://osm.org/copyright' title='OpenStreetMap contributors' target='_blank'>OpenStreetMap contributors</a>.">
                            </telerik:MapLayer>
                        </LayersCollection>
                    </telerik:RadMap>
                </div>
                <div>
                    <telerik:RadButton ID="btnSave" runat="server" Text="Save" OnClick="btnSave_Click"></telerik:RadButton>
                    <telerik:RadButton ID="btnIgnore" runat="server" Text="Ignore" OnClick="btnIgnore_Click"></telerik:RadButton>
                    <telerik:RadGrid ID="RadGrid1" runat="server" AllowPaging="True" AllowSorting="True" Skin="Glow" OnSelectedIndexChanged="RadGrid1_SelectedIndexChanged" OnNeedDataSource="RadGrid1_NeedDataSource">
                        <ClientSettings Selecting-AllowRowSelect="true" EnablePostBackOnRowClick="true">
                        </ClientSettings>
                    </telerik:RadGrid>
                </div>
            </telerik:RadAjaxPanel>
        </div>
    </div>
</asp:Content>

and the Json file is
{"type":"LineString","coordinates":[[55.9178333333333,26.2851666666667],[56.0778333333333,26.3465],[56.6416666666667,25.3191666666667],[56.6125,25.2808333333333],[56.53,25.2685],[56.5256666666667,25.2695],[56.5258333333333,25.2705],[56.526,25.2708333333333],[56.5261666666667,25.2705],[56.526,25.2705],[56.526,25.2703333333333],[56.526,25.2703333333333],[56.526,25.2698333333333],[56.526,25.2693333333333],[56.5263333333,25.2688333333],[56.5261666666667,25.2688333333333],[56.5268333333333,25.2681666666667],[56.5271666667,25.268],[56.5266666666667,25.2685],[56.5268333333333,25.2683333333333],[56.5265,25.2686666666667],[56.5263333333333,25.269],[56.5263333333333,25.269],[56.5266666667,25.2685],[56.5268333333333,25.2683333333333],[56.5276666666667,25.2678333333333],[56.5278333333,25.2678333333],[56.5278333333333,25.268],[56.528,25.2678333333333],[56.531,25.268],[56.53,25.2673333333333],[56.5506666667,25.278],[56.64,25.231],[56.916,25.0915],[63.798,20.0096666666667],[66.3725,17.7773333333333],[69.2525,15.2438333333333],[69.6238333333333,14.9146666666667],[72.1481666666667,12.6655],[74.9048333333333,9.81816666666667],[76.7155,7.5155],[77.5243333333333,7.11866666666667],[79.5831666666667,5.77616666666667],[80.418,5.5015],[83.7298333333333,5.50933333333333],[84.214,5.50166666666667],[87.5165,5.5015],[87.5451666666667,5.50216666666667],[90.4086666666667,5.49616666666667],[94.4676666666667,6.08816666666667],[100.270833333333,3.432],[100.9965,2.80233333333333],[101.222,2.671],[101.415833333333,2.579],[101.6685,2.3805],[101.877166666667,2.212],[102.0215,2.06516666666667],[104.286833333333,1.2715],[134.594666666667,31.9163333333333],[139.047833333333,34.4635],[139.267,34.5651666666667],[139.425166666667,34.5986666666667],[139.681666666667,34.6461666666667],[139.695513333,34.9835916667],[139.77999,35.1670433333333],[139.74876,35.3525866666667],[139.817805,35.34591],[139.820528333333,35.3427166666667],[139.81761,35.3463316666667]]}

i have confirmed the paths are correct etc , can anyone suggest why it doesnt work Note the script manager is in the master page .

Konstantin Dikov
Telerik team
 answered on 28 Oct 2014
1 answer
103 views
I have a page with :

    2 textbox : ID is txt1 and txt21
     RadGrid : ID rgTest

using Simple Paging for "rgTest" and set EnableSEOPaging=True

Each times i change page of "rgTest" i get URL like :http://localhost:9526/Default.aspx?rgTestChangePage=5

My question is :

How to change the name of QueryString : "rgTestChangePage" -> MyPage

How to add params in QueryString like that:Default.aspx?rgTestChangePage=5&&param1=txt1&&param2=txt2
Daniel
Telerik team
 answered on 28 Oct 2014
2 answers
212 views
I am displaying a number of images in thumbnail area with DisplayAreaMode="ToolTip".

Then a user clicks an image, it selects the thumbnail and shows the tooltip with a larger image.  Works great!

When the tool tip goes away, the thumbnail is still selected -- how would I get the selected Thumbnail on the server side?

Thanks,
Todd.
Todd A
Top achievements
Rank 1
 answered on 27 Oct 2014
3 answers
904 views
I can hide major and minor grid lines, but does anyone know how to hide the X or Y axis line?
See attach image.
Thanks,
~bg
Tina Stancheva
Telerik team
 answered on 27 Oct 2014
2 answers
92 views
Is it possible to have many ListView with client-side databinding on one page?
Konstantin Dikov
Telerik team
 answered on 27 Oct 2014
1 answer
87 views
Does somebody know how to hide the link from GridHyperLinkColumn.DataNavigateUrlFormatString ?
I mean not showing in the browser status bar.

In asp.net for Hyperlink control there is a OnMouseOver javascript event very useful to do this.

Thanks in advance.


Eyup
Telerik team
 answered on 27 Oct 2014
1 answer
83 views
I have tried to copy this demo you have
http://demos.telerik.com/aspnet-ajax/tooltip/examples/clientsideapi/defaultcs.aspx?#qsf-demo-source
however when I click on the submit button, the tooltip doesn't show. If I click 5 or 6 times it will show up, then go away when I click again.Not sure if this is a postback issue or not but if so, why is it not an issue in the demo?
Marin Bratanov
Telerik team
 answered on 27 Oct 2014
2 answers
96 views
I have a grid with a textbox and a ClientSelectColumn. I would like to copy the value from one column into the textbox in an itemTemplate column when the selectcolum checkbox is checked. I would like to do this client-side as posting back and using server-side code can take as much as 2 seconds - unacceptable for high-volume data entry.

I would also like to do this for all columns when the checkbox in the header is checked.

TotalAmt would be copied into AmtApproved. I also need to be able to deselect and have the value clear if it exists in the textbox.

Thank you in advance for your help!

 <telerik:GridBoundColumn DataField="TotalAmt" DataType="System.Decimal" FilterControlAltText="Filter TotalAmt column" HeaderText="TotalAmt" SortExpression="Total Due" UniqueName="TotalAmt" DataFormatString="{0:F}" HeaderStyle-HorizontalAlign="Right" ItemStyle-HorizontalAlign="Right" ItemStyle-Width="75px" HeaderStyle-Width="75px">
                                </telerik:GridBoundColumn>
<telerik:GridTemplateColumn HeaderText="Amount Approved" UniqueName="AmtApproved" HeaderStyle-Width="55px" ItemStyle-Width="55px" HeaderStyle-HorizontalAlign="Right" ItemStyle-HorizontalAlign="Right">
                                    <ItemTemplate>
                                        <asp:TextBox ID="AmountApproved" runat="server" Width="55px" OnTextChanged="AmountApproved_TextChanged" AutoPostBack="true" CssClass="numericAlign"></asp:TextBox>
                                    </ItemTemplate>
                                </telerik:GridTemplateColumn>
                                <telerik:GridClientSelectColumn HeaderText="Pay in Full" UniqueName="ClientSelectColumn">
                                </telerik:GridClientSelectColumn>
Thomas Derenthal
Top achievements
Rank 1
 answered on 27 Oct 2014
1 answer
42 views
I have a grid (rgVisitors) with a NestedViewTemplate that contains another grid (rgLogs).

The grids are populated using client side webservices.

On the client (javascript) I clear and refresh the main rgVisitors grid data.
Part of that process involves toggling a GridClientSelectColumn column in the rgVisitors grid using MasterTableView.showColumn(colIndex)

This all works fine except that once I have the data; when I expand a rgVisitor row and attempt to populate the NestedView grid (rgLogs) then this rgLogs grid doesn't display across the whole width of the containing Grid (HTML inspection shows it has a colspan=7 )

If I flip the toggle again to hide and then show my GridClientSelectColumn column, then after reloading the main grid (rgVisitors) and attempting to expand the row shows the NestedView grid (rgLogs) data even narrower than last time (HTML inspection shows it has a colspan=4 )

I have attached 2 images that demonstrate this along with the highlighted line of HTML with Colspan that seems to be dynamically changing.

Any ideas? Is it a bug?



Maria Ilieva
Telerik team
 answered on 27 Oct 2014
4 answers
621 views
We're using the free trial to perform a trial run of converting to Telerik since ComponentArt has abandoned their UI Framework product. The most used control in our system is the grid control.  With the ComponentArt grid we bind it to a DataView and everything is passed once to the client where it's formatted, paginated, searchable, etc.  There is no AJAXing of data or postbacks - the data can be navigated and interacted with on the client side quickly and easily.

The closest I can get with a Telerik grid is pagination and formatting but all interaction with the grid causes a postback and reloading of the data.  Is AJAX simply a requirement of using the Telerik grid or is there a way to get similar functionality where all the data is sent once and then everything happens on the client?  I'd rather not create a bunch of web services since we have close to a 100 unique grids in the app that all work this way.

Sample ComponentArt grid code:
01.<ComponentArt:Grid ID="gdCards" runat="server" EnableViewState="false" PageSize="17" RunningMode="Client">
02.    <Levels>
03.    <ComponentArt:GridLevel
04.        DataKeyField="card_id">
05.        <Columns>
06.            <ComponentArt:GridColumn DataField="card_id" HeadingText="Card ID" Width="60" FixedWidth="true" DefaultSortDirection="Ascending" />
07.                <ComponentArt:GridColumn DataField="card_tp_desc" HeadingText="Card Type" />
08.                <ComponentArt:GridColumn DataField="trk_act_dt" HeadingText="Activate Date" Width="85" FixedWidth="true" FormatString="d" />
09.                <ComponentArt:GridColumn DataField="fname" HeadingText="First Name" />
10.                <ComponentArt:GridColumn DataField="lname" HeadingText="Last name" />
11.                <ComponentArt:GridColumn DataField="amt_left" HeadingText="Amount Left" FixedWidth="true" Width="75" />
12.                <ComponentArt:GridColumn DataField="needs_printed" HeadingText="Print?" FixedWidth="true" Width="50" ColumnType="CheckBox" />
13.                <ComponentArt:GridColumn DataField="card_num" HeadingText="Card #" FixedWidth="true" Width="100" />
14.            </Columns>
15.        </ComponentArt:GridLevel>
16.    </Levels>
17.</ComponentArt:Grid>
ComponentArt grid data binding:
1.gdCards.DataSource = tblCards.DefaultView;
2.gdCards.DataBind();

Telerik grid trial implementation:
01.<telerik:RadGrid ID="rgCards" runat="server" PageSize="17" AllowPaging="true">
02.    <MasterTableView AutoGenerateColumns="false" DataKeyNames="card_id">
03.        <Columns>
04.            <telerik:GridBoundColumn DataField="card_id" HeaderText="Card ID" HeaderStyle-Width="60"></telerik:GridBoundColumn>
05.            <telerik:GridBoundColumn DataField="card_tp_desc" HeaderText="Card Type"></telerik:GridBoundColumn>
06.            <telerik:GridBoundColumn DataField="trk_act_dt" HeaderText="Activate Date" HeaderStyle-Width="85" DataFormatString="{0:d}"></telerik:GridBoundColumn>
07.            <telerik:GridBoundColumn DataField="fname" HeaderText="First Name"></telerik:GridBoundColumn>
08.            <telerik:GridBoundColumn DataField="lname" HeaderText="Last name"></telerik:GridBoundColumn>
09.            <telerik:GridBoundColumn DataField="amt_left" HeaderText="Amount Left" HeaderStyle-Width="75" DataFormatString="{0:c}"></telerik:GridBoundColumn>
10.            <telerik:GridCheckBoxColumn DataField="needs_printed" HeaderText="Print?" HeaderStyle-Width="50"></telerik:GridCheckBoxColumn>
11.            <telerik:GridBoundColumn DataField="card_num" HeaderText="Card #" HeaderStyle-Width="100"></telerik:GridBoundColumn>
12.        </Columns>
13.    </MasterTableView>
14.</telerik:RadGrid>
Telerik grid data binding:
1.rgCards.DataSource = tblCards.DefaultView;
2.rgCards.DataBind();

Thanks in advance for your help.  Also, sorry if this information is somewhere else in the forums - I did several searches but nothing seemed relevant.
Konstantin Dikov
Telerik team
 answered on 27 Oct 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?