|
Hi all
i have build a autocomplete textbox control that works on keyup event in javascript. everytime a keyup is called , a request is send back to server and the suggestion are displayed in div below the textbox.
when enter is pressed,selected value comes in textbox. Now the problem is when i pressed enter button event is called. and the list disapears.
To solve this i set it to on keydown event. but the keydown is called twice, i dont why. even when keydown is pressed i dint get the typed word.
Could anyone tell the solution of this one.
Thanks in advance.
Jagwinder Singh
Er. Jagwinder Singh
|
|
|
|
|
Hi
i am using update panel in which there is a file upload control
but this file upload control is not working in update panel
error which i am getting "object reference is not set"
how con i resolve this issue please help me
krishna veer singh
|
|
|
|
|
krishnaveer wrote: error which i am getting "object reference is not set"
Can you show the code you are using? More than likely, you are missing a new somewheres.
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
"Not only do you continue to babble nonsense, you can't even correctly remember the nonsense you babbled just minutes ago." - Rob Graham
|
|
|
|
|
If FileUpload_Con.PostedFile.FileName <> Nothing Then
files = Path.GetFileName(FileUpload_Con.PostedFile.FileName)
FileUpload_Con.SaveAs(Server.MapPath("Logo_Image/" & Path.GetFileName(FileUpload_Con.PostedFile.FileName) & ""))
this is my code
krishna veer singh
|
|
|
|
|
I suspect File upload control will not work in UpdatePanel. You need to run that outside of UpdatePanel or have that upload alone happening in a new popup window or IFrame.
K.P.Kannan
|
|
|
|
|
File Upload Control will not work with in Update Panel.
If you want File Upload Control with in Update Panel then you need to set
asp:PostBackTrigger to Update Panel..
<asp:updatepanel id="UpdatePanel1" runat="server" xmlns:asp="#unknown">
<contenttemplate>
...
<triggers> <asp:postbacktrigger controlid="btnImgUpload">
<triggers><asp:updatepane>
|
|
|
|
|
Hi, I tried publishing my website via the publish option when I right click my web app, it only created the PrecompiledWeb folder... And i dont know what it does, it just contained my files and a new dll file. What is this for??
Anyway,
I also tried doing the Web application setup but there was an error. I just installed IIS so that my Setup.exe can run.. It says the installation is incomplete..
Can anyone help me on how to deploy or create a setup for Web Application? Thanks!
|
|
|
|
|
when we publish a website,it creates dll for all the layers and C# paghes.In UI layer it keeps the aspx pages that are linked with dlls.After publishing you need to do just deploy it at IIS.Create a virtual directory for it.
if you want ot make a setup you can do all this by C#(ie creating virtual directory and setting the properties.
Cheers!!
Brij
modified on Wednesday, November 12, 2008 12:22 AM
|
|
|
|
|
graced88 wrote: it just contained my files and a new dll file. What is this for??
When you deploy you website with precompiled option, your .cs files will be compilled into dll's. ASPX files will have a reference to this DLL's. Are you not seeing any ASPX files inside that directory? Then probably you are doing something wrong. Check this[^]
|
|
|
|
|
Hmm ok.. stupid question, how will i put it in my IIS?...
My PrecompiledWeb folder has my aspx files and the bin folder which has the dll.
I need the Web Setup Application for this, right?
I would like to have a Setup.exe for this so that I can run my Web Application installed on other PCs..
But when I try to add a project output, the only selection is "Content Files".
|
|
|
|
|
hi i was wondering what is the best way to send data in my case, from an html table to the code behind.the data of the table is added dynamically and when user press on the submit button i need to get the data in c# code behind. i dont want to use gridview at this case. my thinking was building a string that will hold all of the table data and then using ajax or hidden field to get it in the code behind. is it the best way to do that? is there a way to pass objects from js to code behind?
thank u in advance..
j
|
|
|
|
|
For sending data to Code behind,AJAX is better.By the way all depends on the size of data,if size is small,hidden field is better option.
Cheers!!
Brij
|
|
|
|
|
|
1) I'm just working on a website, and the images simple don't display in the Visual Web Designer. They just appear like broken links.
However when I run the page it successfully finds all the images and displays everything correctly.
I'm using a basic tag.
eg
<img src="images/pixi_clear.gif" width="517" height="30"></img>
2) Lets say someone helps me out and tells me how to get the images to display, should the 'width and height' aspects of this be unneccessary as they're built into the image?
|
|
|
|
|
I can only assume my questions is too stupid to be answered? Oh well. I'll continue to look at dead image links.
|
|
|
|
|
Hi, i hope u help me, i want to set my table's height to 100% of the browser even if its content is smaller, this is my code :
<html xmlns="http://www.w3.org/1999/xhtml">
<body style="background-color:Aqua">
<form id="form1" runat="server">
<table align="center" width="80%" style="height: 100%">
<tr>
<td style="width: 100%; height: 91px"></td>
</tr>
<tr>
<td style="width: 100%; height: 100%" rowspan="1">
<asp:contentplaceholder id="ContentPlaceHolder1" runat="server">
</asp:contentplaceholder>
</td>
</tr>
</table>
<table width="80%" align="center">
<tr>
<td style="color: white">Copyright 2008 </td>
</tr>
</table>
</form>
</body>
</html>
thanks in advance
|
|
|
|
|
Try this
use topmargin="0" in body tag
Cheers!!
Brij
|
|
|
|
|
I have 1 checkboxlist, 5 dropdownlits and three textboxes.I have to write the SQL query and c# code for that advanced search.
<asp:CheckBoxList ID="reposotoryCheckBoxList" runat="server" Style="z-index: 106; left: 226px;position: absolute; top: 18px">
asp:ListItem Text="computer" Value="2"></asp:ListItem>
<asp:ListItem Text="math" Value="3"></asp:ListItem>
<asp:ListItem Text="science" Value="1"></asp:ListItem>--%>
</asp:CheckBoxList><asp:DropDownList ID="DropDownList1" runat="server">
<asp:ListItem>Anywhere</asp:ListItem>
<asp:ListItem>Title Words</asp:ListItem>
<asp:ListItem>Creator Name Words</asp:ListItem>
<asp:ListItem>Subject Words</asp:ListItem>
</asp:DropDownList>
<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox><br />
<asp:DropDownList ID="DropDownList2" runat="server">
<asp:ListItem>and</asp:ListItem>
<asp:ListItem>or</asp:ListItem>
<asp:ListItem>not</asp:ListItem>
</asp:DropDownList>
<asp:DropDownList ID="DropDownList3" runat="server">
<asp:ListItem>Anywhere</asp:ListItem>
<asp:ListItem>Title Words</asp:ListItem>
<asp:ListItem>Creator Name Words</asp:ListItem>
<asp:ListItem>Subject Words</asp:ListItem>
</asp:DropDownList><asp:TextBox ID="TextBox2" runat="server"></asp:TextBox><br />
<asp:DropDownList ID="DropDownList4" runat="server">
<asp:ListItem>and</asp:ListItem>
<asp:ListItem>or</asp:ListItem>
<asp:ListItem>not</asp:ListItem>
</asp:DropDownList>
<asp:DropDownList ID="DropDownList5" runat="server">
<asp:ListItem>Anywhere</asp:ListItem>
<asp:ListItem>Title Words</asp:ListItem>
<asp:ListItem>Creator Name Words</asp:ListItem>
<asp:ListItem>Subject words</asp:ListItem>
</asp:DropDownList><asp:TextBox ID="TextBox3" runat="server"></asp:TextBox>
The dropdown list items are from different table, Title from tblTitle,Subject from tblSubject and createrName from tblName.
Any help will be highly appreciated.
Thanks
|
|
|
|
|
I did this and I have problem to select the different table from dropdownlist.
here is my sql query:(inside the App_Code)
public static DataSet GetReport(String repository, String name, String title, String subject)
{
String sql = " Select distinct col.ID,col.CollectionAbstract,col.Title,col.SortTi tle,col.Scope,col.CollectionIdentifier from tblCollections_Collections col" +
" LEFT JOIN tblCollections_CreatorIndex colCI " +
" ON col.ID = colCI.CollectionID " +
" LEFT JOIN tblCreators_Creators cr" +
" ON colCI.CreatorID = cr.ID " +
" LEFT JOIN tblCollections_SubjectIndex sbI " +
" ON col.ID = sbI.CollectionID " +
" LEFT JOIN tblSubjects_Subjects sub " +
" ON sbI.SubjectID = sub.ID " +
" where ( 1=1 )" + //
(repository == null || repository.Trim() == "" ? "" : " and col.RepositoryID in( " + repository + " )") +
(title == null || title.Trim() == "" ? "" : " and col.Title like '%" + title + "%'") +
(name == null || name.Trim() == "" ? "" : " and cr.Name like '%" + name + "%'") +
(subject == null || subject.Trim() == "" ? "" : " and sub.Subject like '%" + subject + "%'")+
" order by col.Title";
return SqlHelper.ExecuteDataset(GetConnectionString(), CommandType.Text, sql);
}
aspx.cs file contains:
protected void Button1_Click(object sender, EventArgs e)
{
try
{
String repository = "";
Boolean first = false;
if (reposotoryCheckBoxList.Items[0].Selected == true)
{
repository = " 1,3,5";
}
else
{
first = false;
for (int i = 0; i <= reposotoryCheckBoxList.Items.Count - 1; i++)
{
if (reposotoryCheckBoxList.Items[i].Selected == true)
{
if (first == false)
{
repository = reposotoryCheckBoxList.Items[i].Value.ToString();
first = true;
}
else
{
repository = repository + " , " + reposotoryCheckBoxList.Items[i].Value.ToString();
}
}
}
}
......My questions .....how to implement that 5 dropdownlists here..............???.......
string str = TextBox1.Text.ToString();
string str1 = TextBox2.Text.ToString();
string str2 = TextBox3.Text.ToString();
str = str.Trim();
str1 = str1.Trim();
str2 = str2.Trim();
//throw new Exception();
DataSet ds;
ds = DataAccess.GetReport(repository, str1, str, str2);
Repeater1.DataSource = ds;
Repeater1.DataBind();
}
I have problem to handle these dropdownlists.Any help will be highly appreciated.
Thanks for your help.
|
|
|
|
|
Hello All,
We're deploying a .net 2.0 web application to a windows 2003 server running IIS. It currently has various .net 1.* running on it. We created a seperate threading pool, insured the framework was installed, registered it to use .net 2.0, through the app on, and we're getting a rather odd error. The event log states "Failed to execute request because the App-Domain could not be created.Error 0x80131522" We have this app running in similar environments with no issues.
Any ideas would be greatly appreciated,
Thanks,
Ryan
|
|
|
|
|
hi, what i am trying to do is , when a button is clicked a row should be added containing one column with a textbox in gridview.
For that i have used datatable for binding,, but i am unable to get the added textbox reference using find control method
here is my cs code.
using System;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
loadDynamicGrid();
}
}
private void loadDynamicGrid()
{
DataTable dt = new DataTable();
DataColumn dcol = new DataColumn();
dcol.ColumnName = "gggg";
dt.Columns.Add(dcol);
DataRow drow = dt.NewRow();
dt.Rows.Add(drow);
GridView1.DataSource = dt;
GridView1.DataBind();
}
protected void Button1_Click(object sender, EventArgs e)
{
DataTable dt = new DataTable();
DataColumn dcol = new DataColumn("gggg");
dt.Columns.Add(dcol);
foreach (GridViewRow gvr in GridView1.Rows)
{
DataRow drow= dt.NewRow();
TextBox tt = (TextBox)gvr.Cells[0].FindControl("Text1");
drow[0] = tt.Text;//Here gives error as it is always null
dt.Rows.Add(drow);
}
DataRow dr = dt.NewRow();
dr[0] = "";
dt.Rows.Add(dr);
GridView1.DataSource = dt;
GridView1.DataBind();
}
protected void GridView1_RowDataBound1(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
TextBox tb = new TextBox();
tb.ID = "Text1";
tb.Text = "chanu";
e.Row.Cells[0].Controls.Add(tb);
}
}
}
//here is my aspx code
]]>
<title>Untitled Page
<asp:scriptmanager id="ScriptManager1" runat="server" xmlns:asp="#unknown">
<asp:updatepanel id="UpdatePanel1" runat="server" xmlns:asp="#unknown">
<contenttemplate>
<asp:gridview id="GridView1" runat="server">
Width="200px"
onrowdatabound="GridView1_RowDataBound1" >
<columns>
<asp:button id="Button1" runat="server" onclick="Button1_Click" text="Button">
“You will never be a leader unless you first learn to follow and be led.”
–Tiorio
"Coming together is a beginning, staying together is progress, and working together is success." Henry Ford
|
|
|
|
|
i have show data in gridview
now i want to Export that data to Excel on click of button so user can save it.
|
|
|
|
|
|
thnx
|
|
|
|
|
Hi,
please tell me how to validate ” dd/mm/yyyy” date format using comparevalidator…
|
|
|
|