Register  |  Login

 Blog List
You must be logged in and have permission to create or edit a blog.
 View Blog
Author: maria Created: 1/8/2010 1:03 AM
My blog will deal with some problems that usually web programmers experience during their development career. I want to share how I resolve my issues and will be glad to be of use to someone if my experience helps them.

In this post I am going to describe a scenario which was a little different from the ones usually found over the internet. The objective was to set up a document library to receive email and upload the received files to an FTP.

I created a workflow in Visual studio 2008 and set it up on the document library. FOllowing is the code in the workflowactivated event. (there is just one activity in the workflow)

1: Private Sub onWorkflowActivated1_Invoked(ByVal sender As System.Object, ByVal e As System.Workflow.Activities.ExternalDataEventArgs) 2: Try 3: Dim request As FtpWebRequest = CType(WebRequest.Create(ConfigurationManager.AppSettings("FTPHost") + Me.workflowProperties.Item.File.Name), FtpWebRequest) 4: request.Method = WebRequestMethods.Ftp.UploadFile 5: request.Credentials = New NetworkCredential(ConfigurationManager.AppSettings("FTPUser"), ConfigurationManager.AppSettings("FTPPassword")) ...

Read More »

We can use as many forms on an page; but we need to have only one of them which is server side (i.e. set to runat=”server”). However there are certain situations in which you have to use an HTML form inside a server form.

Situation would have been a bit easier if there was no cross browser compatibility required and had I not been using a custom built CMS. However, I did have these constraints and I had to set up a functionality for a file download that would only be available to a user once he/she provides some specific information and submits it to an external url.

Here’s how I started what I need to do:

Provide a link to the file download (not the actual link but something that triggers the file download process) Trigger the display of the html form on the link click show the form on the page submit the form to the external url show the actual file download link For the first two steps I opted to use an overlay div; which can be easily shown and hidden using...

Read More »