Search Results

Search found 4628 results on 186 pages for 'gridview editing'.

Page 5/186 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • GridView Events Clarification

    - by nettguy
    Recently I have been asked an interview question "What are the events order in GridView?". I explained Init() Loading() DataBinding() DataBound() RowCreated .... User interaction events like RowCommand,RowDeleting,RowUpdating PreRender -executes every time when the GridView is modified unload() I would like to check whether my answer is right or not.

    Read the article

  • ASP.NET-C#: Inserting const into TextBox in Gridview

    - by dash
    I have some problems inserting a const "1" into a textbox which is gridviw. the gridview code: <asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" EnableViewState="False"> <Columns> <asp:BoundField DataField="Price" HeaderText="Price" ItemStyle-CssClass="price" > <ItemStyle CssClass="price"></ItemStyle> </asp:BoundField> <asp:TemplateField HeaderText="ProductID"> <ItemTemplate> <asp:Label ID="lblID" runat="server" Text='<%# Eval("ProductID") %>'></asp:Label> </ItemTemplate> </asp:TemplateField> <asp:TemplateField HeaderText="ProductName"> <ItemTemplate> <asp:Label ID="lblName" runat="server" Text='<%# Eval("ProductName") %>'></asp:Label> </ItemTemplate> </asp:TemplateField> <asp:TemplateField HeaderText="Summary"> <ItemTemplate> <asp:Label ID="lblSum" runat="server" Text='<%# Eval("Summary") %>'></asp:Label> </ItemTemplate> </asp:TemplateField> <asp:TemplateField HeaderText="picPath"> <ItemTemplate> <asp:Label ID="lblPic" runat="server" Text='<%# Eval("picPath") %>' ></asp:Label> </ItemTemplate> </asp:TemplateField> <asp:TemplateField HeaderText = "quantity"> <ItemTemplate> <asp:TextBox ID="lblquantity" runat="server" ></asp:TextBox> </ItemTemplate> </asp:TemplateField> <asp:TemplateField HeaderText = "Total"> <ItemTemplate> <asp:Label ID="lblTotal" runat="server" ></asp:Label> </ItemTemplate> </asp:TemplateField> </Columns> </asp:GridView> All the information is populated from the session of the privious page, beside this textbox which doesnt comes from anywhere, its a quantity textbox which the user should enter. and i want it to have a defalt value of "1". I dont actually know how to insert into a textbox which is in the gridview. please help me. thanx

    Read the article

  • Updating a gridview based on dundas chart callback

    - by Daud
    I have a dundas pie chart which when clicked issues a client callback which updates another chart associated with it. Basically its like a drill down thing. I also want to update my gridview based on the user's selection of the pie. But since the update of chart is being done using dundas client callback I'm unable to rebind my Gridview. Is there any way to do it? .

    Read the article

  • How to show GridView in tooptip in asp.net

    - by IrfanRaza
    Hello friends, Normally what happens, a single or more lines are shown as a tooltip. What I need is to show a gridview as a tooltip. Actually in my project i need to show all the notes associated with a stock in a gridview. Can anybody help me? Thanks for sharing your valuable time.

    Read the article

  • Gridview display multiple tables?

    - by Shawn
    I have a gridview setup that gets its data from a SQL database stored procedure. This procedure will return one of several different tables. The gridview complains if the table is different than the one previously displayed. How do I work around this?

    Read the article

  • Keep data with specific value on top when sorting a gridview

    - by aspNetAficionado
    Hi i have a gridview with information about documents: name, document type (policy, guidelines, forms, etc), category, etc. I want to sort the gridview alphabetically (name) and by document type, but always having the 'policy' above the other document types when document name is the same. How do I do that? eg If I do sort by DocumentName, DocumentType ('policy' maybe not be the first one in the list) but if I do sort by DocumentType , DocumentName (I would get for example all guidelines first in alphabetical order, then procedures, then policies, etc)

    Read the article

  • Using hyperlink control with imagefield control in gridview

    - by niks
    I have a gridview and a column of that gridview is displaying images whose path is stored in a database & image is stored in locale folder inside my website. My problem is that I want to use the hyperlink control with the image, so that when the image is clicked it should jump to another page. How can I do that?

    Read the article

  • Gridview disappears inside an update panel

    - by Sachin
    I have a gridview inside an update panel and a treeview on the left side. When i click on a node, data is populated in grid view. The gridview disappears when page index change event is fired. Im binding the data on page index change. This does not happen when i remove the update panel :( Please help me! Thanks

    Read the article

  • Overfocus in GridView

    - by chuck258
    I'm trying to implement a GridView that Focuses the next Item and "Overscrolls at the End of a List. E.g. 1 2 3 4 5 6 7 8 9 I want to scroll 1 2 3 4 5 6 ... just by pressing the right Key. Right now I can only Scroll 1 2 3 and then it stops and I have to scroll with the down Key. I already tried to set the focusViews in code (In the getView() method of my ArrayList Adapter, that fills the GridView) view.setId(position); view.setNextFocusLeftId(position-1); view.setNextFocusRightId(position+1); But that doesn't work. I found the boolean *Scroll(int direction) Methods on grepcode But theese are Package Local and I can't overwrite them. Any suggestions on how to solve this. Can I use another View and get the same Layout as a Gridview? I also set a OnFocusChangeListener to see what happens with no reaction. Edit: I just added this to my MainActivity, but now it seems to onKeyDown only get called when the GridView doesn't handle the KeyEvent (If the Last Item in a row is selected). @Override public boolean onKeyDown(int keyCode, KeyEvent event) { switch (keyCode) { case KeyEvent.KEYCODE_DPAD_LEFT: if (focusedView > 0) { mContainer.setSelection(--focusedView); Log.v("TEST", focusedView+""); } return true; case KeyEvent.KEYCODE_DPAD_RIGHT: if (focusedView < mAdapter.getCount() - 1) { mContainer.setSelection(++focusedView); Log.v("TEST", focusedView+""); } return true; } return super.onKeyDown(keyCode, event); } Edit 2: This is so f***ing stupid but works so damn fine :D @Override public boolean onKeyDown(int keyCode, KeyEvent event) { switch (keyCode) { case KeyEvent.KEYCODE_DPAD_LEFT: mContainer.onKeyDown(KeyEvent.KEYCODE_DPAD_UP, new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_DPAD_UP)); mContainer.onKeyDown(KeyEvent.KEYCODE_DPAD_RIGHT, new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_DPAD_RIGHT)); mContainer.onKeyDown(KeyEvent.KEYCODE_DPAD_RIGHT, new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_DPAD_RIGHT)); return true; case KeyEvent.KEYCODE_DPAD_RIGHT: mContainer.onKeyDown(KeyEvent.KEYCODE_DPAD_DOWN, new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_DPAD_DOWN)); mContainer.onKeyDown(KeyEvent.KEYCODE_DPAD_LEFT, new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_DPAD_LEFT)); mContainer.onKeyDown(KeyEvent.KEYCODE_DPAD_LEFT, new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_DPAD_LEFT)); return true; } return super.onKeyDown(keyCode, event); } I really don't want to post this as Answer, and I really don't want to have to use this Code because it is such a stupid workaround ;TLDR: Help still needed

    Read the article

  • export gridview data

    - by Eric
    What is the best way to export a gridview into an Excel spreadsheet? This seems easy except that my Gridview doesn't have an export attribute. What is the quickest way to do this?

    Read the article

  • Looping Gridview when the button is click

    - by Nyan
    Hi all, I have create a girdview in dialog and in the girdview I added a check boxes, so that, the user can check/uncheck the gridview. And there is a button which send back the information about the check values to the server. My problem is I don't know how to loop the gridview. Is there a way to loop the girdview. Or is there other way to achieve? Thanks in advance for any help Nyan

    Read the article

  • Video Editing Software

    - by stanigator
    I would like to add some text labels certain segments of a video. I have had a lot of trouble using Windows Movie Maker for video editing. I know a friend of mine who uses adobe premiere and adobe after effects, but I don't know what's the easiest software to use to achieve my goal. What are your thoughts?

    Read the article

  • Video-editing software for Windows 7

    - by Fuxi
    I'm looking for good software (free or commercial) for video editing. I tried Magix Video Deluxe but didn't like it that much. The application I'm looking for shouldn't be too professional, but not overly simple either. I'm looking for an easy way to cut out scenes quickly and reorder them, as well as naming or tagging them.

    Read the article

  • Edit/Access data from a CheckBox column in an ASPX:GridView - c#

    - by Endo
    Hi, I have a GridView to which I bind a dataTable I manually create. Both the GridView and the dataTable contain 2 columns, Name and isBusy. My GridView looks like this <Columns> <asp:BoundField HeaderText="Name" DataField="Name" SortExpression="Name"> </asp:BoundField> <asp:CheckBoxField DataField="isBusy" HeaderText="Busy" SortExpression="isBusy" /> </Columns> That works fine, except that the Busy column is non-editable unless you set a specific row to edit mode. I require the entire column of checkboxes to be checkable. So I converted the column to a template, and so the columns look like this: <Columns> <asp:BoundField HeaderText="Name" DataField="Name" SortExpression="Name"> </asp:BoundField> <asp:TemplateField HeaderText="Busy" SortExpression="isBusy"> <ItemTemplate> <asp:CheckBox ID="isBusy" runat="server" Checked='<%# Eval("isBusy") %>' oncheckedchanged="CheckBoxBusy_CheckedChanged" /> </ItemTemplate> </asp:TemplateField> </Columns> Now, this throws an error at runtime, saying System.InvalidCastException was unhandled by user code Message="Specified cast is not valid." Source="App_Web_zzjsqlrr" StackTrace: at ASP.proyectos_aspx.__DataBinding__control24(Object sender, EventArgs e) in c:\Proyect\Users.aspx:line 189 at System.Web.UI.Control.OnDataBinding(EventArgs e) at System.Web.UI.Control.DataBind(Boolean raiseOnDataBinding) at System.Web.UI.Control.DataBind() at System.Web.UI.Control.DataBindChildren() InnerException: Any idea why this is happening? The next step I would need is to know how to set and get a checkbox's state (haven't been able to find how to manually check a checkbox). I appreciate very much any help.

    Read the article

  • Gridview sorting: SortDirection always Ascending

    - by Julien N
    Hi ! I have a gridview and I need to sort its elements when the user clicks on the header. Its datasource is a List object. The aspx is defined this way : <asp:GridView ID="grdHeader" AllowSorting="true" AllowPaging="false" AutoGenerateColumns="false" Width="780" runat="server" OnSorting="grdHeader_OnSorting" EnableViewState="true"> <Columns> <asp:BoundField DataField="Entitycode" HeaderText="Entity" SortExpression="Entitycode" /> <asp:BoundField DataField="Statusname" HeaderText="Status" SortExpression="Statusname" /> <asp:BoundField DataField="Username" HeaderText="User" SortExpression="Username" /> </Columns> </asp:GridView> The code behind is defined this way : First load : protected void btnSearch_Click(object sender, EventArgs e) { List<V_ReportPeriodStatusEntity> items = GetPeriodStatusesForScreenSelection(); this.grdHeader.DataSource = items; this.grdHeader.DataBind(); } when the user clicks on headers : protected void grdHeader_OnSorting(object sender, GridViewSortEventArgs e) { List<V_ReportPeriodStatusEntity> items = GetPeriodStatusesForScreenSelection(); items.Sort(new Helpers.GenericComparer<V_ReportPeriodStatusEntity>(e.SortExpression, e.SortDirection)); grdHeader.DataSource = items; grdHeader.DataBind(); } My problem is that e.SortDirection is always set to Ascending. I have webpage with a similar code and it works well, e.SortDirection alternates between Ascending and Descending. What did I do wrong ?

    Read the article

  • ASP.Net GridView UpdatePanel Paging Gives Error On Second Click

    - by joe
    I'm trying to implement a GridView with paging inside a UpdatePanel. Everything works great when I do my first click. The paging kicks in and the next set of data is loaded quickly. However, when I then try to click a link for another page of data, I get the following error: Sys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 12030 aspx code <asp:UpdatePanel ID="UpdatePanel1" runat="server"> <contenttemplate> <asp:GridView ID="GridView1" runat="server" CellPadding="2" AllowPaging="true" AllowSorting="true" PageSize="20" OnPageIndexChanging="GridView1_PageIndexChanging" OnSorting="GridView1_PageSorting" AutoGenerateColumns="False"> <Columns> <asp:BoundField DataField="ActivityLogID" HeaderText="Activity Log ID" SortExpression="ActivityLogID" /> <asp:BoundField DataField="ActivityDate" HeaderText="Activity Date" SortExpression="ActivityDate" /> <asp:BoundField DataField="ntUserID" HeaderText="NTUserID" SortExpression="ntUserID" /> <asp:BoundField DataField="ActivityStatus" HeaderText="Activity Status" SortExpression="ActivityStatus" /> </Columns> </asp:GridView> </contenttemplate> </asp:UpdatePanel> code behind private void bindGridView(string sortExp, string sortDir) { SqlCommand mySqlCommand = new SqlCommand(sSQL, mySQLconnection); SqlDataAdapter mySqlAdapter = new SqlDataAdapter(mySqlCommand); mySqlAdapter.Fill(dtDataTable); DataView myDataView = new DataView(); myDataView = dt.DefaultView; if (sortExp != string.Empty) { myDataView.Sort = string.Format("{0} {1}", sortExp, sortDir); } GridView1.DataSource = myDataView; GridView1.DataBind(); if (mySQLconnection.State == ConnectionState.Open) { mySQLconnection.Close(); } } protected void GridView1_PageIndexChanging(object sender, GridViewPageEventArgs e) { GridView1.PageIndex = e.NewPageIndex; bindGridView(); } protected void GridView1_PageSorting(object sender, GridViewSortEventArgs e) { bindGridView(e.SortExpression, sortOrder); } any clues on what is causing the error on the second click?

    Read the article

  • TemplateField button causing GridView Invalid Postback

    - by Carter
    Ok, so I've got a template field in a gridview that contains just a simple button... <asp:GridView ID="KeywordsGridView" AllowPaging="false" AutoGenerateColumns="false" BackColor="white" GridLines="None" HeaderStyle-CssClass="Table_Header" RowStyle-CssClass="Table_Style" runat="server"> <Columns> <asp:TemplateField> <ItemTemplate> <asp:Button runat="server" /> </ItemTemplate> </asp:TemplateField> <asp:BoundField DataField="References" SortExpression="References" HeaderText="Total References" /> <asp:BoundField DataField="Keyword" SortExpression="Keyword" HeaderText="Keyword" /> </Columns> </asp:GridView> Whenever I click the button I get the error... Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation. I've found a decent amount of articles referencing this issue, including a couple on SO, for example... http://stackoverflow.com/questions/228969/asp-net-invalid-postback-or-callback-argument-event-validation-is-enabled-usi and... http://stackoverflow.com/questions/103560/invalid-postback-or-callback-argument I might just be misunderstanding, but as far as I can tell they don't really help me. How do I get this to go away without setting enableEventValidation="false"?

    Read the article

  • Assigning a RecID field to Gridview TemplateField (Checbox column)

    - by user279521
    I want to assign a RecID to the checkbox column "cbPOID". The RecID field that is being returned in my dataset, but should not be displayed in the gridview. <asp:GridView ID="gvOrders" runat="server" AutoGenerateColumns="False" CellPadding="4" GridLines="None" Width="100%" AllowPaging="True" PageSize="20" onpageindexchanging="gvOrders_PageIndexChanging" ForeColor="#333333"> <Columns> <asp:TemplateField HeaderText="VerifiedComplete" > <ItemTemplate> <asp:CheckBox ID="cbPOID" runat="server"/> </ItemTemplate> </asp:TemplateField> <asp:BoundField DataField="PurchaseOrderID" HeaderText="PurchaseOrderID" HtmlEncode="False" ></asp:BoundField> <asp:BoundField DataField="VENDOR_ID" HeaderText="Vendor ID"></asp:BoundField> <asp:BoundField DataField="VENDOR_NAME" HeaderText="Vendor Name"></asp:BoundField> <asp:BoundField DataField="ITEM_DESC" HeaderText="Item Desc"></asp:BoundField> <asp:BoundField DataField="SYS_DATE" HeaderText="System Date"></asp:BoundField> </Columns> <FooterStyle CssClass="GridFooter" BackColor="#990000" Font-Bold="True" ForeColor="White" /> <PagerStyle CssClass="GridPager" ForeColor="#333333" BackColor="#FFCC66" HorizontalAlign="Center" /> <SelectedRowStyle BackColor="#FFCC66" Font-Bold="True" ForeColor="Navy" /> <HeaderStyle CssClass="GridHeader" BackColor="#990000" Font-Bold="True" ForeColor="White" /> <RowStyle CssClass="GridItem" BackColor="#FFFBD6" ForeColor="#333333" /> <AlternatingRowStyle CssClass="GridAltItem" BackColor="White" /> </asp:GridView>

    Read the article

  • Acceessing some aggregate functions in a linq datasource in a GridView

    - by Stephen Pellicer
    I am working on a traditional WebForms project. In the project I am trying out some Linq datasources with plans to eventually migrate to an MVC architecture. I am still very new to Linq. I have a GridView using a Linq datasource. The entities I am showing has a to many relationship and I would like to get the maximum value of a column in the many side of the relationship. I can show properties of the base entity in the gridview: <asp:TemplateField HeaderText="Number" SortExpression="tJobBase.tJob.JobNumber"> <ItemTemplate> <asp:Label ID="Label1" runat="server" Text='<%# Bind("tJobBase.tJob.JobNumber") %>'> </asp:Label> </ItemTemplate> </asp:TemplateField> I can also show the count of the many related property: <asp:TemplateField HeaderText="Number" SortExpression="tJobBase.tJob.tHourlies.Count"> <ItemTemplate> <asp:Label ID="Label1" runat="server" Text='<%# Bind("tJobBase.tJob.tHourlies.Count") %>'> </asp:Label> </ItemTemplate> </asp:TemplateField> Is there a way to get the max value of a column called WeekEnding in the tHourlies collection to show in the GridView?

    Read the article

  • Add row to GridView after header row

    - by Jan-Frederik Carl
    I have a GridView with a header and some rows and want to add another row just below the header using jQuery. <form id="form1" runat="server"> <div> <asp:GridView ID="GridView1" ShowHeader="true" runat="server"> <Columns> <asp:TemplateField HeaderText="Activity Name"> <ItemTemplate> <asp:Label runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "Name") %>'></asp:Label> </ItemTemplate> </asp:TemplateField> </Columns> </asp:GridView> <asp:Button Text="Add Activity" runat="server" OnClientClick="addActivity(); return false;" /> </div> </form> My tries were $('#GridView1 tbody').prepend('<tr><td>new activity</td></tr>'); Puts a new row above the header $('#GridView1 table tr:first').after('<tr><td>new activity</td></tr>'); Does nothing (at least nothing visible, as well with any other tr element)

    Read the article

  • Gridview column right click issue

    - by peter
    I have grid named 'GridView1' and displaying columns like this <asp:GridView ID="GridView1" OnRowCommand="ScheduleGridView_RowCommand" runat="server" AutoGenerateColumns="False" Height="60px" Style="text-align: center" Width="869px" EnableViewState="False"> <Columns> <asp:BoundField HeaderText="Topic" DataField="Topic" /> <asp:BoundField DataField="Moderator" HeaderText="Moderator" /> <asp:BoundField DataField="Expert" HeaderText="Expert" /> <asp:BoundField DataField="StartTime" HeaderText="Start" > <HeaderStyle Width="175px" /> </asp:BoundField> <asp:BoundField DataField="EndTime" HeaderText="End" > <HeaderStyle Width="175px" /> </asp:BoundField> <asp:TemplateField HeaderText="Join" ShowHeader="False"> <ItemTemplate> <asp:Button ID="JoinBT" runat="server" CommandArgument="<%# Container.DataItemIndex %>" CommandName="Join" Text="Join" Width="52px" /> </ItemTemplate> <HeaderStyle Height="15px" /> </asp:TemplateField> </Columns> </asp:GridView> Here what is my requirement is whenever we right click on each row in gridview ,it should display three option join meeting(if we click it will go to meeting.aspx),,view details(will go to detail.aspx),,Subscribe(subscribe.aspx) just like when we click right any where we can see view,sortby,refresh like that..Do we need to implement javascript here

    Read the article

  • Android How to get position of selected item from gridview without using onclicklistner, using ontouchlistner instead

    - by zonemikel
    I have a gridview, I need to do stuff on motioneven.action_down and do something for motioneven.action_up ... using onclicklistener is great but does not give me this needed functionality. Is there anyway to easily call the gridview and get its selected item in a ontouchlistener ? I've been having limited success with making my own implementation. Its hard to get the right x,y because if i call the child it gives me the x and y relative to the child so a button would be 0,0 to 48,48 but it does not tell you the actual location on the screen relative to the gridview or the screen itself. this is what i've been doing, its partially working so far. Grid.setOnTouchListener(new OnTouchListener() { public boolean onTouch(View v, MotionEvent event) { if (event.getAction() == MotionEvent.ACTION_DOWN) { int x = (int)event.getX(); int y = (int)event.getY(); int position = 0; int childCount = Grid.getChildCount(); Message msg = new Message(); Rect ButtonRect = new Rect(); Grid.getChildAt(0).getDrawingRect(ButtonRect); int InitialLeft = ButtonRect.left + 10; ButtonRect.offsetTo(InitialLeft, ButtonRect.top); // while(position < childCount){ if(ButtonRect.contains(x,y)){break;} if(ButtonRect.right + ButtonRect.width() > Grid.getWidth()) { ButtonRect.offsetTo(InitialLeft, ButtonRect.bottom);} position++; ButtonRect.offsetTo(ButtonRect.right, ButtonRect.top); } msg.what = position; msg.arg1 = ButtonRect.bottom; msg.arg2 = y; cHandler.sendMessage(msg); }// end if action up if (event.getAction() == MotionEvent.ACTION_UP) { } return false; } });

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >