|
Hi All,
I am using Ajax ModalPopupExtender in my application. The code is given below
<asp:Panel ID="panelJobType" runat="server" CssClass="modalPopup">
<asp:Panel ID="panelJobTypeHead" runat="server" Style="cursor: move; background-color: #DDDDDD;
border: solid 1px Gray; color: Black">
<div>
<p>
Add the Job Type</p>
</div>
</asp:Panel>
<div>
<table>
<tr>
<td width="28" height="17">
</td>
<td align="left" valign="top" class="search" width="168" height="17">
Job Type:
</td>
<td align="left" valign="top" width="291" height="17">
<asp:TextBox ID="txt_Ctitle" runat="server" CssClass="border" size="25" MaxLength="50"></asp:TextBox>
<font class="msg">*</font>
</td>
</tr>
<tr>
<td colspan="3" height="5">
</td>
</tr>
<tr>
<td height="25" colspan="3">
</td>
</tr>
<tr>
<td colspan="3" bgcolor="074264" align="right" valign="bottom" class="heading5" height="25">
<asp:Button ID="btnSubmitJob" CssClass="rpt_btn" runat="server" Text="Save" />
<asp:Button ID="btnCancel" CssClass="rpt_btn" runat="server" Text="Cancel" />
</td>
</tr>
</table>
</div>
</asp:Panel>
<ajaxToolkit:ModalPopupExtender ID="ModalPopupExtender" runat="server" TargetControlID="LinkButton1"
PopupControlID="panelJobType" BackgroundCssClass="modalBackground"
OkControlID="btnSubmitJob" CancelControlID="btnCancel"
DropShadow="true" PopupDragHandleControlID="panelJobTypeHead" />
Now what I want is to generate events from the buttons in the Panel.
For example I want to store the value of textbox into database by clicking on the button.
Is it possible??? and if yes than how.
Thanks in advance.
modified on Tuesday, August 25, 2009 5:47 AM
|
|
|
|
|
Hi All ,
I am loging into the web site after all validation i have to open another page in popup in which user select the hospital name then i have to redirect to index page.
Dim strScript As String
strScript = "<script language=javascript>" & vbCrLf & _
"window.opener.location.reload('index.aspx');window.close();" & _
vbCrLf & "</script>"
If Not ClientScript.IsClientScriptBlockRegistered("RefreshOpener") Then
ClientScript.RegisterStartupScript([GetType], "RefreshOpener", strScript)
Else
'lblError.Text = "Please Enter Valid Brokerage"
'lblError.Visible = True
End If
Thanks ,
This is working fine for IE but not for firefox
Amit
|
|
|
|
|
Amit Patel1985 wrote: This is working fine for IE but not for firefox
Install firebug[^] and debug the JS.
|
|
|
|
|
Hi,
I created a control and compile it. When I add it to an ASPX page it is
displayed fairly good at design time. But when I am trying to run it
an error has been raised.
Could not load file or assembly 'ServerTime' or one of its
dependencies. The located assembly's manifest definition does not match the
assembly reference. (Exception from HRESULT: 0x80131040)
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.IO.FileLoadException: Could not load file or
assembly 'ServerTime' or one of its dependencies. The located assembly's
manifest definition does not match the assembly reference. (Exception from
HRESULT: 0x80131040)
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.
Assembly Load Trace: The following information can be helpful to determine
why the assembly 'ServerTime' could not be loaded.
WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value
[HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind
failure logging.
To turn this feature off, remove the registry value
[HKLM\Software\Microsoft\Fusion!EnableLog].
Please help me with this.
|
|
|
|
|
Hi to all,
I am trying to add the menu items dynamically. But I am stucked in problem. I am unable to find the index of the menu items where menu text is "something".
public void populate_menu()
{
DataSet ds = GetMenuData();
foreach(DataRow drow in ds.Tables["CATEGORY"].Rows)
{
MenuItem masteritem = new MenuItem((string)drow["category_name"]);
name = masteritem.Text;
get_id();
par_id = Convert.ToInt32 (ViewState["p_id"]);
if (par_id == 0)
{
Menu1.Items.Add(masteritem);
}
else
{
get_category_name();
ca_name = ViewState["cname"].ToString();
Menu1.Items[0].ChildItems.Add(masteritem);
}
}
}
please assist me..
cheers,
sneha
|
|
|
|
|
I guess you need to maintain a value path and work with Menu.FindItem()[^] method.
Other way is to recursively search the menu items and sub items until you get the required item.
|
|
|
|
|
Hello every one,I have some images in mysql data base .I am trying to get it in web page.I am writing following code but i am getting error some array outof Rang exception.Please give me the solution.The code is as follow
OdbcConnection con = new OdbcConnection(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString);
OdbcDataAdapter da = new OdbcDataAdapter("select Image from test4", con);
DataSet ds = new DataSet();
da.Fill(ds, "test4");
DataRow row=ds.Tables ["test4"].Rows [0];
byte[] image = (byte[])row["Image"];
Response.BinaryWrite(image);
|
|
|
|
|
hi,
You can try like this:
cmd = new OleDbCommand("select * from gallery where event_id='"+ id +"'", conn);
dr = cmd.ExecuteReader();
if (dr.HasRows)
{
cmd1 = new OleDbCommand("select event_name from events where event_id=" + id, conn);
dr1 = cmd1.ExecuteReader();
dr1.Read();
lblevent.Text = "<h3>" + dr1[0].ToString() + "</h3>";
lblevent.Text = lblevent.Text + "<p>";
dr1.Close();
while (dr.Read())
{
lblevent.Text = lblevent.Text + "<a href='images/events/" + dr[3].ToString() + "' rel=\"lightbox[events Photos]\"><img src=\"images/events/thumb/" + dr[2].ToString() + " \" alt='' width=\"100\" height=\"96\" border=\"1\" /></a>";
}
lblevent.Text = lblevent.Text + "</p>";
cheers,
sneha
|
|
|
|
|
Well, I guess that you don't have a single row in your table. I would try to debug the code, setting a breakpoint where you access the row.
Regards
Sebastian
|
|
|
|
|
I am writting this syntex for insert. its showing syntex error in insert.plz tell me the correct one.
INSERT INTO Registration (DATE OF BIRTH,CONTACT NUMBER) VALUES('" + DateT.Text + "','" + ContactT.Text + "')
|
|
|
|
|
I think you haven't read any book on SQL, you have no idea about T-SQL.
In this statement you should use [] in column name because there are spaces in column name (which is not a good practice).
Second you should pass parameters...
Be an Eagle, Sky is Yours.
|
|
|
|
|
Hi,
You should use parameter mapping to avoid sql injection.
cheers,
sneha
|
|
|
|
|
INSERT INTO Registration ([DATE OF BIRTH],[CONTACT NUMBER]) VALUES('" + DateT.Text + "','" + ContactT.Text + "')
Be aware from SQL Injections!
I Love T-SQL
"Don't torture yourself,let the life to do it for you."
If my post helps you kindly save my time by voting my post.
www.aktualiteti.com
|
|
|
|
|
I have created a registration form. The details of this registration form should be stored in table.
How to do that and what is the syntex for insert.
|
|
|
|
|
You want that someone write code for you (absolutely free ).
First read some beginner's book on C# and SQL.
Be an Eagle, Sky is Yours.
|
|
|
|
|
If u dont mind than can u suggest me some books for thi
|
|
|
|
|
insert into tbl_name(coulmn_names separated by commas) values(Values to be insert)
|
|
|
|
|
Hi guys, I'm trying to built a grid view from scratch, create it then do all the bindings by code, do u know of any good articles related to this matter ?
thanx
Mr.K
|
|
|
|
|
|
Hi All,
I want to integrate flex(Adobe ) with ASP.Net can anyone help me to find out the way .
Thanks
Amit Patel
|
|
|
|
|
The only thing that i can send from client side to side is string. Is it right or wrong????
If right,why it is being so.
if wrong, then what are all things i can send from client to server
thanks
regards
Subramanian
|
|
|
|
|
Hi,
not sure if I got your question right. Which technology do you use? Lowlevel TCP/IP or higher like ASP.NET.
I would say that communicating at a low level (like TCP/IP) everything sent from client to server are bytes. These will be interpreted as string. Since nearly each type has a string representation you can send everything from client to server. It is just a matter of the layer above TCP/IP to build an object from a special type from the received string.
Regards
Sebastian
|
|
|
|
|
Hi all,
I have a gridview control in asp.net 2.0,and some datas are binding from the database.If there is no data in the databse,then the grid is not displayed.Is it possible to display the grid without any data.The data is added by <boundfield>
Thanks
Denny
|
|
|
|
|
by assigning a empty datatabel with relevant column name can be useful.
eg:
DataTable dt = new DataTable();
dt.Columns.Add("dummy");
dt.Rows.Add();
GridView1.DataSource = dt;
GridView1.DataBind();
//but this is not a best practise....
|
|
|
|
|
<
DataTable source = new DataTable();
gridViewAppointment.DataSource = source;
// New empty row is added to the grid view to dis play the data table.
source.Rows.Add(source.NewRow());
gridViewAppointment.DataBind();
int columnsCount = gridViewAppointment.Columns.Count;
gridViewAppointment.Rows[0].Cells.Clear();// clear all the cells in the row
gridViewAppointment.Rows[0].Cells.Add(new TableCell()); //add a new blank cell
gridViewAppointment.Rows[0].Cells[0].ColumnSpan = columnsCount;
gridViewAppointment.Rows[0].Cells[0].HorizontalAlign = HorizontalAlign.Center;
gridViewAppointment.Rows[0].Cells[0].ForeColor = System.Drawing.Color.Red;
gridViewAppointment.Rows[0].Cells[0].Font.Bold = true;
// set No Results found to the new added cell
gridViewAppointment.Rows[0].Cells[0].Text = "No Appointment Found!";
>
yes it is possible but u have to display some message like no recordfound
first create the data table bind it with grid view
then get column count
clear all cells then join all column through colspan then add text
|
|
|
|