|
Well, if you're not naming the column anywhere in your code, where is it coming from ? Perhaps from something that's auto generated ?
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
The Column Name that you are retrieving(in the database) is different from your Column Name in the table.
God is always with you.
|
|
|
|
|
Which bit are you stuck on, ready XML ( google XPath ), or creating dynamic textboxes ?
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hi guys
I found this example - where the files from a folder is listed within a Gridview. I have never seen this before - and to get it up running would really be usefull to many.
It runs fine on the localhost - but when it´s launched to a server it fails to list any files.
The error from the label is as:
The example is from: http://www.rekenwonder.com/aspnet/foldercontentsdatasource.html[^]
------------------------------------------------------------------
cs: WORKS FINE
------------------------------------------------------------------
protected void FolderContentsDataSource1_Selected(object sender, rw.FolderContentsDataSourceStatusEventArgs e)
{
if ((e.Exception != null))
{
lblError.Text = e.Exception.Message;
e.ExceptionHandled = true;
}
}
protected void gvFile_RowDeleted(object sender, System.Web.UI.WebControls.GridViewDeletedEventArgs e)
{
if ((e.Exception != null))
{
lblError.Text = e.Exception.Message;
e.ExceptionHandled = true;
}
}
protected void gvFile_RowUpdated(object sender, System.Web.UI.WebControls.GridViewUpdatedEventArgs e)
{
if ((e.Exception != null))
{
lblError.Text = e.Exception.Message;
e.ExceptionHandled = true;
}
}
------------------------------------------------------------------
ASP.NET *****Failure marked with stars*****
------------------------------------------------------------------
<asp:textbox id="tbFolder" runat="server" *******text="/Files" *******="" visible="false">
<asp:button id="btnShow" runat="server" text="Show contents" causesvalidation="false">
<asp:gridview id="GridView2" runat="server" datasourceid="FolderContentsDataSource1" autogeneratecolumns="False" allowpaging="True"
="" allowsorting="True" onrowdeleted="gvFile_RowDeleted" onrowupdated="gvFile_RowUpdated" backcolor="White" bordercolor="#999999" borderstyle="None" cellpadding="3" gridlines="Vertical" width="400px">
<headerstyle cssclass="headerstyle" backcolor="#000084" font-bold="True" forecolor="White">
<alternatingrowstyle cssclass="altstyle" backcolor="#DCDCDC">
<rowstyle cssclass="itemstyle" backcolor="#EEEEEE" forecolor="Black">
<columns>
<asp:boundfield datafield="Name" headertext="Filnavn" sortexpression="Name">
<asp:boundfield datafield="Size" headertext="Størrelse" sortexpression="Size" readonly="True">
<itemstyle horizontalalign="Right">
<asp:boundfield datafield="Created" headertext="Uploadet" sortexpression="Created"
="" readonly="True">
<asp:templatefield>
<itemtemplate>
<asp:linkbutton id="btnRename" runat="server" commandname="Edit" causesvalidation="false"
="" commandargument="<%# Container.DataItemIndex %>" text="Rename" tooltip="Skift filnavnet">
<asp:linkbutton id="btnDelete" runat="server" commandname="Delete" causesvalidation="false"
="" commandargument="<%# Container.DataItemIndex %>" text="delete" onclientclick="return confirm('Er du sikker på at du vil slette filen?');">
<edititemtemplate>
<asp:linkbutton id="btnUpdate" runat="server" commandname="Update" text="update"
="" commandargument="<%# Container.DataItemIndex %>">
<asp:linkbutton id="btnCancel" runat="server" commandname="Cancel" causesvalidation="false"
="" text="cancel">
<itemstyle horizontalalign="Center">
<footerstyle backcolor="#CCCCCC" forecolor="Black">
<selectedrowstyle backcolor="#008A8C" font-bold="True" forecolor="White">
<pagerstyle backcolor="#999999" forecolor="Black" horizontalalign="Center">
<cc1:foldercontentsdatasource id="FolderContentsDataSource1" runat="server" onselected="FolderContentsDataSource1_Selected">
<selectparameters>
<asp:controlparameter name="Directory" type="String" controlid="tbFolder" propertyname="Text">
<asp:label id="lblError" runat="server" enableviewstate="False" forecolor="Red">
|
|
|
|
|
You need to post the code again with "Ignore HTML tags in this message" checked.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
"Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
|
|
|
|
|
I have a data list show a image and a text the data is shown over laped.
The data show come from database it come from a select statment with a condition this query is in SQLDatasource
and the conection between the field and database is set visual. why the record come over laped?
merwa
|
|
|
|
|
Hi,
I have a requirement where I have a folder on local hard-drive containing many .pdf files.
Now I want to have a Hyperlink control point to this path of hard-drive folder and upon clicking on it the the pdf file should open in the browser.
The file path is say: C:/DocumentUpload/abc.pdf
I apply this to the url of hyperlink but it does not work. On mouse over the url shows:
file:///C:/DocumentUpload/abc.pdf
It will however work if i place the file in my web directory and just apply the filename "abc.pdf" to the url. Then the hyperlink on mouse over shows
http://localhost/mydomain/abc.pdf
How can I have my files in C:/DocumentUpload/ and still make it work using hyperlink. Or is there some other alternative. NOTE: I positively cannot place the files in web directory folder.!!
Any help is eagerly awaited!
Pankaj Chamria,
Software Programmer.
|
|
|
|
|
Pankaj C wrote: NOTE: I positively cannot place the files in web directory folder.!!
- Use IE
- Add your website in the trust site.
then, I think it will work.. but it's not good practice for public site.
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
"Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
|
|
|
|
|
Tks for the reply Michael. I tried your suggestion but it is behaving still in the same manner. I think for a hyperlink only http://.... type of urls work. I guess a url like c:/DocumentUpload is not identified by the explorer.
Anyone with any other suggestions, pl lemme know!
Pankaj Chamria,
Software Programmer.
|
|
|
|
|
Hi,
I have a user control. It should display a list of employees in a department, but in a nested way. It is currently defined like this:
- It contains a single div.
- Inside this div there are three controls:
- A HyperLink control (showing the name of the department)
- A GridView control (listing all employees within this department)
- A Repeater control (which should display all sub-departments).
The repeater should actually contain a copy of the user control itself!, since it is really displaying the exact same information, only for subdepartments - and there could be an (theoretically) infinite amount of nested subdepartments.
Now, obviously a user control cannot directly contain a control which is an instance of itself. However, I've managed to bypass that problem by letting the repeater contain a single PlaceHolder, and then use LoadControl to load any number of the UC. This works correctly and all the data is displayed - but in the same gridview: the gridview defined in the first UC which is loaded with LoadControl. All the others are empty.
It appears that when I call e.Item.FindControl during the ItemDataBound event for the repeater, it always seems to give me the same control.
Has anyone had any similar problem - or what is more important - a solution?
Regards,
Daníel
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
Obviously it will give the same control. but u can bind different data as u like.it can have different value of the same control in gridview.
Devjit Das.
|
|
|
|
|
I know the steps to create master page:
a. In the Solution Explorer window, right-click C:\..\Lab1and select “Add New Item.”
b. In the Add New Item dialog, select “Master Page” and type “Site.master” into the Name box. Be sure “Place code in separate file” is checked and the appropriate language is selected in the Language box before clicking Add.
But I am not able to see Master Page option in Add Item dialog...
I am using VS 2003
On simple aspx pages when I am trying to add asp DetailsView tag then it says
:: The active schema does not support the element 'asp:DetailsView'. ::
I surfed net a lot but didnot find any help.
Plz help me....
|
|
|
|
|
Master pages were only introduced in .NET 2.0, which became available in VS2005.
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|
|
what about detailsview...??
is there any dll which I can download to make detailsview available at my VS??
Is there any other option available for master page??
Actually I have to develop a website in asp.net
I am not able to create masterpage, sitemap, detailsview
I don't know How to start things. I am ASP Programmer and facing a lot problems in ASP.Net
I need help... Anybody Plz plz help me
|
|
|
|
|
The best way to implement all these is to move to asp.net 2.0.
Other wise you need to sacrifice some of the features which is not present in earlier versions.
|
|
|
|
|
Hi all,
What function in javascript will enable to to detect browser?
Like wheather the browser is IE,Firefox,NetScape,Opera....
Thanks
|
|
|
|
|
|
If you want to use Javascript this should do it although their are other methods using ASP.NET:
Hydraman says "Make mine a water"
|
|
|
|
|
Thanks I have a real media player embeded pluginn in my HTML page.It opens fine On Internet Explorer.However When i open it in Firefox it become very small in size.
Do i have to code the plaginn for each browser diffrently.
Please advice
Thanks
|
|
|
|
|
kibromg wrote: Do i have to code the plaginn for each browser diffrently.
No.
Try this[^] topic to find links and issues related to Real problems in Firefox.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Pete O`Hanlon wrote: No.
Why no? We need to install "Realplayer" plugin for Firefox, isn't it?
Pete O`Hanlon wrote: Try this[^] topic to find links and issues related to Real problems in Firefox.
Sorry. I can't access this page from here. it's blocked.. I will take a look when I get back home..
Thanks and Regards,
Michael Sync ( Blog: http://michaelsync.net)
"Please vote to let me (and others) know if this answer helped you or not. A 5 vote tells people that your question has been answered successfully and that I've pitched it at just the right level. Thanks."
|
|
|
|
|
Dear all programer
I have create one container and i bound one form into the container but i want to display fix size of the container in aspx file. but what happend, it container size automatically increase when page is display.
|
|
|
|
|
Harun.Net wrote: I have create one container and i bound one form into the container
Container??? What is it? try placing the container inside a DIV with height and width specified.
Regards - J O H N -
|
|
|
|
|
container means i have used web user control and i place webcontrol in div but size is automaticaly increase because form contains textboxes,gride etc...it display full size, i want to display in fix size so all the component of the form may me automatically decrease the size
|
|
|
|
|
hi
can anybody claer my doudt as here i had created crystalreport.rpt file and set all properties to it and now the database is also connectd
ow in my aspx file i had created tables in sql and here i got my datatable and my code follows like this
//this i wrote it in button click
Dim dt As DataTable dt=trackFac.ActivityFullReportCRDropDownList1.Text....) myreports.Load(Server.MapPath("CrystalReport.rpt"))
myreports.SetDataSource(dt)
//in my page load
CrystalReportViewer1.ReportSource = myreports
but i am not getting crystalreport
padma
|
|
|
|