SharePoint / ASP.Net Development
Experiences from the field
Navigation
   RSS 2.0
Categories
Entries by Month

# Thursday, June 15, 2006

One of the patches on June 13, 2006 is causing problems on some pages. A few pages to review to get up to speed and the work-around:

InfoWorld's article

KBase Article

MSDN Technical Article with the work-around

Thursday, June 15, 2006 9:59:49 AM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 
# Monday, August 22, 2005

Do you have an ASP.Net application that will run in an Application Pool with a specific identity? Before you enter the user account in the Identity tab of the Application Pool properties dialog, you should add the account to the local group IIS_WPG. If you forget, you get permission issues. And permission issues are the hardest to fix, imho.

(I am sure you can guess why I am blogging this...)

Monday, August 22, 2005 11:58:52 AM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 
# Tuesday, July 12, 2005

In response to a post in the ASP.Net forums, here is a routine to upload a file to a document library.

Sub ProcessPostedFile(ByVal fileUpload As HtmlControls.HtmlInputFile)
    Try
    ' get the filename and stream
    Dim fn As String = System.IO.Path.GetFileName(fileUpload.PostedFile.FileName)
    Dim stm As System.IO.Stream = fileUpload.PostedFile.InputStream
    Dim contents(CInt(stm.Length)) As Byte

    stm.Read(contents, 0, CInt(stm.Length))
    stm.Close()

    ' get the library path
    Dim docLibPath As String = Configuration.ConfigurationSettings.AppSettings("DocUploadPath")
    ' first, get the site containing the library
    Dim site As SPSite = New SPSite(docLibPath)
    Dim web As SPWeb = site.OpenWeb
    ' then get the folder
    Dim docFolder As SPFolder = web.GetFolder(docLibPath)

    ' delete the file if it exists
    Dim docFile As SPFile
    Try
        docFile = docFolder.Files(fn)
    Catch ex As Exception
    End Try

    If Not docFile Is Nothing Then
        docFolder.Files.Delete(fn)
    End If

    ' save the file
    docFile = docFolder.Files.Add(fn, contents)

    Catch ex As Exception
        Context.Trace.Warn(ex.ToString)
    End Try
End Sub

Tuesday, July 12, 2005 12:43:24 PM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 
# Friday, February 18, 2005
Friday, February 18, 2005 11:54:08 PM (Central Standard Time, UTC-06:00)  #    Comments [0]  | 
# Friday, January 07, 2005

Brian Goldfarb is soliciting help about what type of MasterPage templates to build. (He doesn't say so, but I assume he means that these would be shipped with ASP.Net 2.0 or at least downloadable.)

My response in his comments:

I think have at least a few "ready-to-go" pages would be helpful. Like SharePoint services -- some templates are full of web parts, others are just shells.

Friday, January 07, 2005 1:27:44 PM (Central Standard Time, UTC-06:00)  #    Comments [0]  | 
# Monday, July 12, 2004

I'm working on an ASP.Net application that requires the entry of a date and time. The user interface needs to resemble Outlook's appointment form, where the date is entered separately from the time. The date box has a button to display a pop-up calendar, and the time has a dropdown that displays the work day in half-hour increments. Both boxes can be entered manually.

Matt Hawley of Excentrics World has just what I need: a Calendar pop-up and a Time Picker. Thank you Matt!!

A word of caution, however. The time picker returns the users entry/selection as a date data type. This included both the date and time. The date part is today's date, which may not be what you want...

Monday, July 12, 2004 12:40:24 PM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 
# Thursday, May 27, 2004

Kent Sharkey posted the regex code necessary for ASP.Net to recognize Firefox & Netscape 7.1.

If I understood regular expressions, I would provide the update for Safari.  But I don't, so instead I'll provide you with the User Agent strings for the various versions.

Thursday, May 27, 2004 2:01:02 PM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 
# Friday, May 21, 2004

Another thing I discovered...

Defining a relation/contraint between two tables in the DataSet designer does not always create the DataRelation in the resulting DataSet object.

Friday, May 21, 2004 9:00:28 AM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 

I use strongly-typed datasets. I like the intellisense and it IsXXXNull methods. And I bind them to data grids. Everything is good.

When acting on a datagrid in ItemCreated or ItemCommand, it is common to access the underlying data. This is acheived via e.Item.DataItem. When a grid is bound to a DataSet or DataTable, this property returns a DataRowView. My lovely, strongly-typed object is gone. :(

I needed to build a page that displayed hierarchical data. So, instead of binding my grid to a DataTable, I was binding to a GetChildRows method, which is a DataRow(). My strongly-typed DataRow is back!!!

To get the strongly-type datarow without a relation, bind to dataSet.dataTable.Rows.

Friday, May 21, 2004 8:58:52 AM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 
# Thursday, March 11, 2004

Over the last few months, I have had difficulty with running FrontPage websites on the same shared host as ASP.Net websites.  I don't understand completely, other that sometimes the .Net sites issue a generic “Error occurred” message. 

Today was the last straw.  Two different sites were unavailable, for no apparent reason.  No explanation from the vendor.  I am moving to SecureWebs. They host the blog of Scott Watermasysk, the creator of the .Text blog engine.

I have received top-notch help from Scott (a different Scott) at SecureWebs. I am excited about the move, which will be complete before the end of the month.

Thursday, March 11, 2004 3:50:04 PM (Central Standard Time, UTC-06:00)  #    Comments [0]  | 
# Friday, March 05, 2004

I found a .Net-based program that will generate statistical reports from your webserver log files. SmarterTools is fee for use on your development machine, so it is perfect for in-frequent requests about traffic.  Very nice.

Friday, March 05, 2004 10:01:24 AM (Central Standard Time, UTC-06:00)  #    Comments [0]  | 
# Friday, May 16, 2003

I wrote this function to set the focus of a page on the first text box.

SetFocus.htm (3.13 KB)
Friday, May 16, 2003 4:53:47 AM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 
# Thursday, April 24, 2003
Don XML has identified a bug that affects me. I just got the call yesterday and found the cause today. Could be a lucky day...
Thursday, April 24, 2003 4:52:50 AM (Central Daylight Time, UTC-05:00)  #    Comments [0]  | 
# Friday, January 17, 2003
It is a bit to get your hands around, especially the reader/writer objects for I/O. Overall, I like it. The DataGrid control is nice, and is definately less coding once you understand how it works. I also wrote less code for updating the database, thanks to ADO.Net. As Jerry Pournelle writes, it gets an Orchid.
Friday, January 17, 2003 1:22:45 AM (Central Standard Time, UTC-06:00)  #    Comments [0]  | 
Search

Powered by: newtelligence dasBlog 2.2.8279.16125

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2010, Paul Schaeflein

Send mail to the author(s) E-mail