Click here to Skip to main content


GeneralRe: Back Page link with Attachment 4 Pinmembern.podbielski18-Nov-12 23:14 
GeneralRe: Back Page link with Attachment 4 Pinmemberεїзεїзεїз19-Nov-12 22:29 
GeneralRe: Back Page link with Attachment 4 Pinmembern.podbielski19-Nov-12 22:33 
GeneralRe: Back Page link with Attachment 4 Pinmemberεїзεїзεїз20-Nov-12 0:02 
AnswerRe: Back Page link with Attachment 4 PinmemberZaf Khan26-Nov-12 10:02 
GeneralRe: Back Page link with Attachment 4 Pinmemberεїзεїзεїз26-Nov-12 21:49 
GeneralRe: Back Page link with Attachment 4 PinmemberZaf Khan27-Nov-12 8:55 
Questioncall javascript in button1_click in bihindcode [modified] Pinmemberjojoba201116-Nov-12 23:22 
How i can call javascript OK function in click event of btnOK :
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="GridviewGhataKhadamat.aspx.cs"
    Inherits="Tina.WebUI.WorkFlows.Forms.Khadamat.GridviewGhataKhadamat" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">
<html xmlns="">
<head runat="server">
    <script type="text/javascript">
        function Close() {
        function OK(Id,Name,Code) {
            var vReturnValue = new Object();
            vReturnValue.Id = Id;
            vReturnValue.Name = Name;
            vReturnValue.Code = Code;  
            window.returnValue = vReturnValue;
<body >
    <form id="form1" runat="server">
       <%-- <asp:HiddenField ID="GridviewTypeT" runat="server" />--%>
        <asp:GridView ID="gvGhataKhadamat" runat="server" AutoGenerateColumns="False" BackColor="White"
            BorderColor="#CC9966" BorderStyle="Inset" BorderWidth="1px" CellPadding="4" Font-Names="Verdana">
            <FooterStyle BackColor="#FFFFCC" ForeColor="#330099" />
                <asp:TemplateField HeaderText="">
                        <input name="rbGhataKhadamat" type="radio" value="<%# Eval("Id") %>,<%# Eval("Name") %>,<%# Eval("Code") %>" />
                <asp:BoundField DataField="Id" HeaderText="ID" Visible="false" />
                <asp:BoundField DataField="Code" HeaderText="<%$ Resources:Khadamat, Code %>" />
                <asp:BoundField DataField="Name" HeaderText="<%$ Resources:Khadamat, Name %>" />
            <RowStyle BackColor="White" ForeColor="#330099" />
            <SelectedRowStyle BackColor="#FFCC66" Font-Bold="True" ForeColor="#663399" />
            <PagerStyle BackColor="#FFFFCC" ForeColor="#330099" HorizontalAlign="Center" />
            <HeaderStyle BackColor="#990000" Font-Bold="True" ForeColor="#FFFFCC" />
     <asp:Button runat="server" ID="btnOk" Text="<%$ Resources:Khadamat, ok %>" 
    <asp:Button runat="server" ID="btnCancel" Text="<%$ Resources:Khadamat, cancel %>"
        OnClientClick="Close()" />
and this is bihind code
protected void btnOk_Click(object sender, EventArgs e)
            string[] strSelected=Request.Form["rbGhataKhadamat"].Split(new char[]{','});
            Page.ClientScript.RegisterStartupScript(GetType(), "OK", "OK(" + "'" + strSelected[0] + "','" + strSelected[1] + "','" + strSelected[2] + "'"+");", true);
it doesnt call OK function.
id didnt used onclientclick event cause i must pass the selected grid values.
thanks in advanced!

modified 17-Nov-12 4:50am.

NewsSOVED ! Pinmemberjojoba201117-Nov-12 0:28 
QuestionMulti tenancy PinmemberFernando "Poorlyte" Girotto16-Nov-12 20:40 
QuestionWhat is this doing Pinmemberrakeshs31215-Nov-12 23:10 
AnswerRe: What is this doing Pinmemberryanb3116-Nov-12 8:41 
QuestionBuilding DOM from xml - controls, or html controls? Pinmemberlvq68415-Nov-12 22:17 
AnswerRe: Building DOM from xml - controls, or html controls? Pinmemberjkirkerx16-Nov-12 9:13 
GeneralRe: Building DOM from xml - controls, or html controls? Pinmemberlvq68418-Nov-12 23:10 
QuestionRe: Building DOM from xml - controls, or html controls? Pinmembern.podbielski17-Nov-12 2:47 
QuestionChild config files Pinmemberindian14315-Nov-12 17:33 
AnswerRe: Child config files Pinmemberjkirkerx16-Nov-12 9:54 
Questionbind multiple XMLDataSource to one Repeater Pinmemberjrahma15-Nov-12 4:19 
AnswerRe: bind multiple XMLDataSource to one Repeater PinmemberAnurag Gandhi15-Nov-12 22:20 
QuestionAspx control Pinmemberrakeshs31214-Nov-12 22:07 
AnswerRe: Aspx control PinmemberRobert Bettinelli3-Dec-12 16:30 
QuestionCould not load file or assembly Pinmemberxut244714-Nov-12 21:11 
AnswerRe: Could not load file or assembly Pinmemberryanb3116-Nov-12 8:42 
QuestionProblem with foreach loop in MVC 3 Razor View Pinmembersolomon20114-Nov-12 5:09 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Advertise | Privacy | Mobile
Web02 | 2.8.150123.1 | Last Updated 24 Jan 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid