|
Hi
I have page, which consists of a master page and of course content pages. My master page has a sticky header, footer and navigation bar, which sits on the left. To scroll the content pages, the div tag on the master page uses a css attribute of overflow-x:scroll.
However, I have noticed that on some of pages the bottom of my scroll bar, the down arrow, is hidden or missing under my footer, making it impossible to see the bottom of the page, and also my navigation bar on the left moves out of position by going up the page when the mouse rolls over it. This does not happen other pages, where the entire scroll bar is visible and navigation bar stays where it should be.
I am not sure whether this is anything to do with some of div tags not having the correct size, or whether something else is going on.
Can someone please advise me on this?
Thanks
|
|
|
|
|
Hey,
For having fixed header and footers, I always suggest u to hide the document scroll bar, rather just place a div where the content will come and the div will have a scrollbar.
Means no scollbar will be shown to the body, rather the scrollbar will be shown only to the content of the fixed height div.
I know you can make the entire body to scroll, just in that case you need to take the 16px fix for IE as IE renders scrollbar outside the div, while all other browsers renders it inside.
Just check the user agent and do the alteration using javascript.
|
|
|
|
|
Hi All,
I have a gridview, contains itemtemplate and fooetertemplate.
very first time when the page loads then it should show first is in editablemode, this can be achieved using footertemplate.
The problem is lets say now my grid is having 2 rows now i am in 3rd row, i filled the fieds for third row and then i pressed save button.
Now i need to populate all the three rows. but grid already contains first two rows. only thing when i press save it will save information about the third row and then it should bind with existing rows.
in rowcommand i am getting third row column values and able to store in DB.
I think understood about the problem.
Anybody knows the solution for this please let me know.
|
|
|
|
|
Just refresh the datasource of the Gridview with all the 3 rows in it and call its DataBind. I think it will do it automatically
|
|
|
|
|
Hello everyone,
If page1.aspx starts the session and then user redirects from page1.aspx to page2.aspx, but page2.aspx needs to be secure (starts with https). If we write absolute URL for redirection, session would be lost.
Whats the best and efficient way to redirect from unsecure to secure apsx pages without loosing Session?
Thanks in advance.
|
|
|
|
|
Hi,
I have a big MasterPage (MasterPage_System) e several MasterPages inheriting (don't think it's the right word) this master page.
My question is: Could a web page using a MasterPage_A (that already uses my MasterPage_System) access the MasterPage_System properties?
I tried in the Page_Load method something like this:
((MasterPage_System)(Master.Master)).MyProperty = true; but it doesn't work
Thanks,
Dirso
modified on Friday, September 18, 2009 3:41 PM
|
|
|
|
|
Go into the debugger and walk the tree of objects to find where your class instance is.
I always derive all pages from my own custom base page, so that I can access a strongly typed version of my master page without having to cast every time.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
How to filter top 4 records from a dataset using rowfilter property in codebehind page
|
|
|
|
|
anushh wrote: How to filter top 4 records from a dataset using rowfilter property in codebehind page
No, the RowFilter property was not designed to do that. It is more analogous to the WHERE clause of an SQL statement.
Why dont you do it at the SQL Server itself?
Anyways, you may also try to use this approach:
private DataView GetTopDataViewRows(DataView dv, Int32 n)
{
DataTable dt = dv.Table.Clone();
for (int i = 0; i < n-1; i++)
{
if (i>= dv.Count)
{
break;
}
dt.ImportRow(dv[i].Row);
}
return new DataView(dt, dv.RowFilter, dv.Sort, dv.RowStateFilter);
}
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
hey manas...
How about
datataable.AsEnumerable().Take(n) //where n is the no of rows from datatable.
|
|
|
|
|
Abhishek Sur wrote: datataable.AsEnumerable().Take(n)
This is so nice.
I am still living with VS 2005. I must plan to move on to the VS 2010 soon
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
I guess so mate. Few days back... I was in 2005 like you.
But after using LINQ.. I always suggest to shift from 2005, and work in 2008. 2010 is far apart. Even I didnt have a chance to work on it..
Cheers.
|
|
|
|
|
Abhishek Sur wrote: 2010 is far apart
Not that far. Already started the download[^]
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
Yes Thank you for the link... Already tried the Parallel Extensions in .NET 3.5 .. Excited to see .NET 4.0 with truely multicore support in it.
I have already downloaded the 2010 Beta.. Just have to start doing some tests in this 1.
Hope you are also enjoying this big release too.
|
|
|
|
|
I had a setup where I had a datalist of course listings, and when the items were created I went out to a remote sql server and retrieved the faculty for each course. But, that seems to take too long to load, so I thought it would be faster to go get all the data at once on page load and then filter with data views. But, I can't seem to get there. I tested on a datagrid outside the datalist and it populates with 3 rows fine. (Number one - is my assumption correct? Number two - what am I doing wrong? Is the Public Data.dataView not available when I'm trying to call it?)
It stops on the line
'dv.RowFilter = "eid=" & myEID.ToString
with the error: Object reference not set to an instance of an object.
If I comment out the line, I get no datagrids.
Imports dsList
Partial Class orpce_hcClasses
Inherits System.Web.UI.Page
Public ds As New Data.DataSet
Public myFacView As Data.DataView
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not Page.IsPostBack Then
Dim myList As dsSql = New dsSql() ''''instantiate the function to get dataset
Dim myView As Data.DataView
Dim myStr As String = ""
ds = myList.dsListAll(go get the initial course datalist dataset)
If ds.Tables("list").Rows.Count > 0 Then
myView = ds.Tables("list").DefaultView
dlList.DataSource = myView
myView.Sort = "startSort"
dlList.DataBind()
If ds.Tables("list").Rows.Count > 0 Then
Dim i As Integer
For i = 0 To ds.Tables("list").Rows.Count - 1
myStr &= ds.Tables("list").Rows(i)("eid").ToString & ","
Next
myStr = Left(myStr, Len(myStr) - 1)
End If
ds = myList.dsListFac(myStr)
myFacView = New Data.DataView
myFacView = ds.Tables("faculty").DefaultView
End If
End If
End Sub
Protected Sub dlList_ItemDataBound(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DataListItemEventArgs) Handles dlList.ItemDataBound
Dim myEID As String = Convert.ToInt32(CType(e.Item.FindControl("txtEID"), TextBox).Text)
Dim dv As Data.DataView
Dim dg As DataGrid = CType(e.Item.FindControl("dgFac"), DataGrid)
dv = myFacView
'dv.RowFilter = "eid=" & myEID.ToString
dg.DataSource = dv
dg.DataBind()
End Sub
|
|
|
|
|
hello there, I have one question. I am rewriting whole web application, and some pages of the old one are in html format. I want to know if the session will be maintained once the user open the html file, and is it still possible to add items from the html file to the shopping cart, which is build in asp.net. Thanks for your help
|
|
|
|
|
Yes, the session exists on the server. I don't know if requesting a html page would reset the timeout, but I'd suspect it would. Either way, going between them will not erase the session automatically, even if it does cause issues with a timeout. Your best bet is to test it. Set something up in the session. Refresh a html page every minute or so for 10 or 15 minutes, whatever the timeout is, plus a bit. Then go to a page that shows the session value.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Hi Dears
I traveled from VS2005 To VS2008 team system.
It's so good, but i got a problem!
In VS2005, we can change the "Default Css Positioning" and set it to Absolute, but in VS2008 i can't find this option.
Please Help me.
Thank you for your help in anticipation.
|
|
|
|
|
|
Hi,
I am making a web application which uses webservices. The problem is that whenever I reopen my web application after closing it, I get an error message:
http://lh3.ggpht.com/_EC8qUhn9kJY/SrOHGWPKa0I/AAAAAAAAAHE/vByKCtukRsk/error%28web_service%29.JPG[^]
Then I have to delete and add webservices again to make the project back in working state.
This same problem also occurs when I leave my project in idle state for long time.
How can I resolve this error?
Any help shall be appreciated.
|
|
|
|
|
Can you specify the actual error message that comes. I cant see the image, I think there must be some problem with the link.
|
|
|
|
|
the error is as follows
Failed to update WEB REFERENCE 'MAILSERVICE_assign_req.SENDMAILService3'
ERROR: there was an error downloading 'http://localhost:1446/sendmailservice/sendmailservice3.asmx?disco'.(0x80131509)
|
|
|
|
|
Can you tell me what you are referencing while adding the web service. Are you adding sendmailservice3.asmx?wsdl
If so try to connect to sendmainservice3.asmx?disco
Have you tried to browse the disco file directly?
You can also add reference to web service manually.
open Visual studio command prompt,
browse to your application directory
type
disco http://localhost:1446/sendmailservice/sendmailservice3.asmx
this will generate a wsdl file, disco, and discomap file on your disk
Next type
wsdl sendmailservice3.asmx
This will generate the c# file
Now include those files to your project and try to run.
|
|
|
|
|
Hi Abhishek,
I tried adding the things YOU specified but nothing seems to happen all the files were added , but the error still comes.
here is the code along with responses You asked me to Run in visual studio cmd:
Setting environment for using Microsoft Visual Studio 2008 x86 tools.
C:\Program Files\Microsoft Visual Studio 9.0\VC>cd\
C:\>cd C:\Documents and Settings\server\My Documents\Visual Studio 2008\WebSites
\my_project
C:\Documents and Settings\server\My Documents\Visual Studio 2008\WebSites\ my_project >disco http://localhost:1446/SendMailService/SendMailService.asmx
Microsoft (R) Web Services Discovery Utility
[Microsoft (R) .NET Framework, Version 2.0.50727.1432]
Copyright (C) Microsoft Corporation. All rights reserved.
Disco found documents at the following URLs:
http://localhost:1446/SendMailService/SendMailService.asmx?disco
http://localhost:1446/SendMailService/SendMailService.asmx?wsdl
The following files hold the content found at the corresponding URLs:
.\SendMailService.disco <- http://localhost:1446/SendMailService/SendMailServi
ce.asmx?disco
.\SendMailService.wsdl <- http://localhost:1446/SendMailService/SendMailServic
e.asmx?wsdl
The file .\results.discomap holds links to each of these files.
If you would like more help, please type "wsdl /?".
C:\Documents and Settings\server\My Documents\Visual Studio 2008\WebSites\ my_project >wsdl http://localhost:1446/sendmailservice/sendmailservice3.asmx
Microsoft (R) Web Services Description Language Utility
[Microsoft (R) .NET Framework, Version 2.0.50727.1432]
Copyright (C) Microsoft Corporation. All rights reserved.
Writing file 'C:\Documents and Settings\server\My Documents\Visual Studio 2008\W
ebSites\my_project\Service3.cs'.
please reply
|
|
|
|
|
Hi all,
I've been having trouble trying to figure out a way to loop through controls in a User Control to find LoginViews and when found manipulate each of them.
With the following code snippet the LoginView controls are found but cannot be manipulated.
Code:
For Each lv as Control In Me.Controls
If lv.GetType().ToString().Equals("System.Web.UI.WebControls.LoginView") Then
CType(lv, System.Web.UI.WebControls.LoginView).RoleGroups(0).Roles = "role"
End If
Next
Thanks in advance.
|
|
|
|