Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Mobile > PDA Issue

Thread Tools

PDA Issue

Posts: n/a

Using IE 6.0,IE 7.0,IE 8.0, We are not able to upload the
attachments(*.doc,*.pdf,*.jpeg) in PDA Device. Only text file is able to
attach but in deksotp it works fine for all file types.

We are using the following controls which is generating at runt time.

Button: Dim htb As New HtmlControls.HtmlInputButton("Submit")

Page Name: MultipleAttachment.aspx

Design Code :->
<%@ page language="VB" autoeventwireup="false"
inherits="AttachmentHandler.multipleAttachment" validaterequest="false"
CodeFile="multipleAttachment.aspx.vb" EnableEventValidation="false" %>
<%@ OutputCache Duration="1" VaryByParam="None" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"

<html xmlns="" >
<head runat="server">


<form action="" runat="server" method="POST" id="form1"
<asp:Label ID="Label1" runat="server" Text="Add
Attachment"></asp:Label><br />
<br />
<input type="file" id="Browse" name="Browse" />


User can browse the file using Browse button and the Upload button generates
at run time
[Dim htb As New HtmlControls.HtmlInputButton("Submit")] when page
loads.After clicking on Upload the following Submit() function called.
In this function , for PDA, System.Web.HttpContext.Current.Request.Files
always does not contain anything and hence file_coll.Item(0).FileName

Sub AddNewAttachment(ByVal sender As Object, ByVal e As System.EventArgs)
Dim index As Integer
Dim file_coll As HttpFileCollection
Dim uploadedFile As HttpPostedFile
Dim fname As String
Dim filesize As String
'Changes for WAP Attachment Issue starts -- Jeywin Lizy
Dim curAttachmentsfile As New ArrayList()
Dim curAttachments As New ArrayList()
Dim curAttachmentsSize As New ArrayList()


If (Not Session(curTasksAttachFile) Is Nothing) Then

curAttachmentsfile = Session(curTasksAttachFile)
curAttachments = Session(curTasksAttach)
curAttachmentsSize = Session(curTasksAttachSize)
End If
'Changes for WAP Attachment Issue ends -- Jeywin Lizy
If assignmentAuthenticateandGet() Then

'Dim req As System.Web.HttpRequest

file_coll = System.Web.HttpContext.Current.Request.Files 'Get file
collection from request

If (file_coll.Item(0).FileName = "") Then 'jeywin lizy
'If file_coll.Count = 0 Then 'Check
if file collection contains file(s)

'Throw New local_exception("File Collection was not
writeToMsgwindow("File Collection was not found")

If (file_coll.Item(0).ContentLength = 0) Then
'jeywin lizy
'Throw New local_exception("Cannot attach empty
file- upload file")
writeToMsgwindow("Cannot attach empty file-
upload file")

End If

End If

uploadedFile = file_coll.Item(0)
fname = uploadedFile.FileName
filesize = Request.ContentLength

If Request.ContentLength < 10485760 Then

If fname <> "" Then
'Changes for WAP Attachment Issue starts --
Jeywin Lizy
If (file_coll.Item(0).ContentLength > 0) Then
'jeywin lizy

Session(curTasksAttachFile) =
Session(curTasksAttach) = curAttachments
Session(curTasksAttachSize) =

End If
'Changes for WAP Attachment Issue ends --
Jeywin Lizy
End If
'Changes for WAP Attachment Issue starts -- Jeywin
index = 0

Do While index < curAttachments.Count 'Create table
with attachment details
curAttachments.Item(index), curAttachmentsSize.Item(index))
index = index + 1
'Changes for WAP Attachment Issue ends -- Jeywin Lizy
writeToMsgwindow("Can't attach a file larger than 10
End If

End If

Catch ex As Exception
'Throw ex
writeToMsgwindow(ex.Message()) 'Changes for WAP Attachment
Issue starts -- Jeywin Lizy

End Try

End Sub

It seems that rendering not happening for these file types in PDA for
HTMLInput button type but it is happening only in desktop. Please help us in
case; we need to change the control type.


Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
PDA Issue deepak ASP .Net Web Controls 1 06-24-2009 01:52 PM
Windows CE 5.0 PDA - Wireless Network Security issue =?Utf-8?B?Q2xhcmE=?= Wireless Networking 1 11-05-2007 08:17 PM
Wireless Access Point for PDA =?Utf-8?B?Ym9i?= Wireless Networking 1 10-11-2004 10:01 AM
Wireless Networkng with PDA Ed Wireless Networking 6 10-01-2004 05:09 PM
Windows PDA applications or ASP.NET web PDA applications?? Anil ASP .Net Mobile 1 07-31-2004 08:38 AM