|
-
Favorite VS .Net 2005 features
Date: 01/09/06
(Asp Dot Net) Keywords: xml, asp, web
I recently installed the new visual studio and I am having a bit of a hard time remembering everything I heard at the 2003 PDC about the new features I can use when doing C# development.
I do remeber the following few: Generics --> has anyone tried this ? Seemed better than having to write your own custom class, is it ? Parial classes -> omg I love this feature ! I love that the very boring generated code wont be in my file. I like my files nice and navigatable. YAY The Xml editor is slightly better but doesnt seem blazing fast as promised. Also I bet some people like not have to use a real web server to test asp pages.
Had anyone tried the ream features ? How are they ? Should we get ris of Test Director ?
Thanks !
Source: http://www.livejournal.com/community/aspdotnet/53224.html
-
paypal/ebay scam
Date: 01/13/06
(Computer Geeks) Keywords: asp, security, ebay
So here is the deal. I was selling this laptop on ebay. Retails about $850. So I get an email in ebay from this guy say he needs it right away and it for his son, blah blah blah. I will pay you $4,000 if you can ship it to me right away and if we can do the transaction through western union. So here is the emails. Just be careful, I am very security minded and almost fell for it. If it wasn't for my distrust in most things, I wouldn't of call western union and found out it was fake.
From: "ade taiwo" | Block Address | Add to Contacts To: lordsaibat Date: 11 Jan 2006, 05:55:09 AM Subject: Congratulations Your Payment Is In Progress !!!
-------------------------------------------------------------------------------- Dear Seller,
This is to inform you that your payment has been made and is currently under processing, I am very sure you are in receipt of the notification of my payment from Western Union.
Anyway, I want the package to be shipped out as soon as you received the approval of your money order from Western Union so that my Son can be able meet up with the need for this package .
Kindly get back to me with the shipment tracking number immediately you shipped my package.
I WANT THIS PACKAGE TO BE SHIPPED AS SOON AS THE PAYMENT APPROVED FROM Western Union AND SHIPPED IT THROUGH Global Express mail 3-5days USPS POST ONLY PLS.
I will be looking forward to hearing from you soonest because the Package is urgently needed.
Regards, Ade
-- _______________________________________________ Get your free email from http://fastermail.com
From: "Western Union Transfer" | Block Address | Add to Contacts To: lordsaibat@gawab.com Date: 11 Jan 2006, 05:54:36 AM Subject: MONEY ORDER PENDING (7650980937)***DO NOT REPLY***
-------------------------------------------------------------------------------- ========================================================================================================== ========================================================================================================== THIS IS AN AUTOMATED MESSAGE, PLEASE DO NOT REPLY ========================================================================================================== ========================================================================================================== *AUCTION PAYMENT NOTIFICATION*
Western Union ® Order Number: 7650980937
Dear Tobias Mccurry,
This is to notify you that Western Union® Accounts Payments has received an order placed by Mr.Ade Tawio, of your auction item to have a Western Union® branded Money OrderSM sent to you as payment for the auction item. The order is currently being processed.
The details of the transaction are stated below: ---------------------------------------------------------------------------------------------------- *AUCTION DETAILS* AUCTION SITE : Ebay Inc. AUCTION ITEM : HP PAVILION Laptop ---------------------------------------------------------------------------------------------------- *FINANCIAL DETAILS* ---------------------------------------- AUCTION AMOUNT : $ 3,800.00 SHIPPING AMOUNT : $ 200.00 ---------------------------------------- TOTAL : $ 4,000.00 ---------------------------------------- Once the order is processed successfully, you will receive another email from Western Union ® informing you that the money order has been approved.The Money OrderSM will be delivered to the address below, Please verify that the name and address (As entered by the buyer)are correct: ------------------------------------------------------------------------------------------------------- NAME : Tobias Mccurry ADDRESS : 7101 C Mcnickle CITY : TAFB STATE : Ok POST CODE : 73145 COUNTRY : USA EMAIL : lordsaibat@gawab.com ------------------------------------------------------------------------------------------------------- Seller Should Not ship until you recieve another email informing you that your money order has been APPROVED, also seller must ship the item upon receipt of the confirmation email that your money order has been APPROVED in other not to delay your money order from being shipped to the designated address provided by the buyer.
Seller must ship the item to the buyer when the money order has been approved and send the tracking number to our agent email address:(helpdesks@consultant.com) DO NOT forget to include Order number,your full name and address. -------------------------------------------------------------------------------------------------------- PLEASE NOTE: This is only a notification informing you that the buyer Has made payment to Western Union®, The payment is currently being processed and is regarded as PENDING as it is still subject to APPROVAL after being successfully processed.Western Union® hereby advises you NOT to ship the item until you have received another message from Western Union® stating that, the order has been APPROVED.Please exercise some patience as the process usually approved within 1 to 24 hours. -------------------------------------------------------------------------------------------------------- Thank you for using Western Union® Accounts Payments. We look forward to serving your online auction payment needs better in the future.
Western Union Team, Accounts Payments.
============================================================================================================= THIS IS AN AUTOMATED MESSAGE, PLEASE DO NOT REPLY =============================================================================================================
From: "Western Union Transfer" | Block Address | Add to Contacts To: lordsaibat@gawab.com Date: 11 Jan 2006, 01:09:31 PM Subject: MONEY ORDER HAS BEEN APPROVED***(7650980937)***DO NOT REPLY
-------------------------------------------------------------------------------- ========================================================================================================== ========================================================================================================== THIS IS AN AUTOMATED MESSAGE, PLEASE DO NOT REPLY ========================================================================================================== ========================================================================================================== *AUCTION PAYMENT NOTIFICATION*
Western Union® Order Number: 7650980937
Dear Tobias Mccurry,
Congratulations! The order placed by Mr.Ade Tawio, of your auction item to have a Western Union Accounts® branded Money OrderSM sent to you as payment for the item has been successfully processed and has consequently been APPROVED. The financial details of the transaction are stated below: --------------------------------------------------------------------------------------- *FINANCIAL DETAILS* ---------------------------------------- AUCTION AMOUNT : $ 3,800.00 SHIPPING AMOUNT : $ 200.00 ---------------------------------------- TOTAL : $ 4,000.00 ---------------------------------------- -------------------------------------------------------------------- ***PLEASE NOTE*** The Money OrderSM will be delivered to the address below, Please verify if the name and address (As entered by the buyer)are correct: ----------------------------------------------------------------------------------------------------------------------------- NAME : Tobias Mccurry ADDRESS : 7101 C Mcnickle CITY : TAFB STATE : Ok POST CODE : 73145 COUNTRY : USA EMAIL : lordsaibat@gawab.com ----------------------------------------------------------------------------------------------------------------------------- ***ATTENTION** The order has been APPROVED, you CAN NOW ship the Item to the buyer shipping address. You are expected to make the shipment within 48 hours of receiving this Payment Approval Notification. This is the buyer shipping information: ----------------------------------------------------------------------------------------------------------------------------- Name : Mr. Ade Tawio Address : 40 queen cinema street City : IBADAN State : OYO STATE Zip : 20001 Country : NIGERIA ----------------------------------------------------------------------------------------------------------------------------- If the buyer has requested that the item be sent to any address other than the one provided above, please ship the item OUT and notify us immediately. Go to http://www.Westernunion.com Be sure to include the Western Union Accounts Payments order number and the change of address the buyer has requested. Also, include the change of address as the subject of your mail. ----------------------------------------------------------------------------------------------------------------------------- ***PLEASE NOTE*** The Money OrderSM will NOT be dispatched until shipment has been verified. This measure is taken in order to protect both seller and buyer interests and to reduce the occurrence of fraudulent activities. ----------------------------------------------------------------------------------------------------------------------------- *SHIPMENT VERIFICATION* You can have the shipment confirmed/verified in any of the following ways:
1. Shipment should be made to the buyer and the TRACKING NUMBER of the shipment should be sent to our agent email address : helpdesks@consultant.com Once the verification of shipment is confirmed, you will be notified and your money order will be shipped out to your designated address immediately.
2. Your money order will be delayed until you send the SHIPMENT TRACKING NUMBER of the item been shipped to our agent as a Confirmation.
3. Your money order will be shipped out immediately you send the shipment notification to our agent. PLEASE ON NO ACCOUNT MUST YOU ALLOW THE BUYER GAIN ACCESS TO THIS MAIL.
Thanks for using Western Union. Looking forward to serve your future Online needs.
Western Union Team, Accounts Payments.
============================================================================================================= THIS IS AN AUTOMATED MESSAGE, PLEASE DO NOT REPLY =============================================================================================================
Source: http://www.livejournal.com/community/computergeeks/859697.html
-
InfoPath 2003 VS Asp.Net
Date: 01/16/06
(Asp Dot Net) Keywords: xml, asp, web
My boss has given me the task of looking into developing a web form that apparently needs to be read by other programs using an XML feed. He suggested using InfoPath 2003, but I then said "Well, ASp.Net would probably be able to do it too." But looking into InfoPath it looks like it may be a good tool for the job. Has anyone had any experience with Infopath, especially vs Asp.Net? I mean I'm not looking to do the most work possible, but also I dont' want to build it in 1 only to have to rebuild it in another to make sure that it can do everything we need it to do. So if anyone has any experience using these tools it'd be greatly appreciated. Thanks.
Source: http://www.livejournal.com/community/aspdotnet/54390.html
-
SQL Server Question
Date: 01/18/06
(Asp Dot Net) Keywords: xml, database, asp, web
I'm working on an ASP.Net page that will need to take information from a database, but the information needs to be multi-line, like a numbered list. How would I either store that or display that properly on the web page? Basically part of the output needs to look like this:
Performance Objectives Participant will be able to: 1. Explain the value of standardizing and institutionalizing performance management across all of X 2. Describe the characteristics of a strong performance management culture 3. Explain how to use the tools and processes that will enable differentiation 4. Explain pay for performance and base salary administration
Any suggestions would be useful. I'm not sure how to integrate XML with this since this is so database driven. Thanks.
Source: http://www.livejournal.com/community/aspdotnet/54950.html
-
asp.net session
Date: 01/18/06
(Asp Dot Net) Keywords: css, asp
below is the code to run my searcg stored procudure i need to find a way to add in the variable TotalRecordCount into the dgResultset dataset so i can call it into the datalist that corrosponds to dgResultset. If there is an easier way of doing it i'd be interested.
Cheers
' Runs the search in the DB for the relevant result Dim SearAccomStat As New Devotion2Motion.AccomSearchClass()
' send the variables to be searched on through to the component in the accomsearch class dgResultset.DataSource = SearAccomStat.SearchAccomStats(accomType, Totalsgle, Totaldble, Totaltwin, TotalTriple, aGarage, aPhone, aCarPark, aTv, aTownCentre, aSwimPool, aRadio, aNearSlopes, aDgsAdmit, aSafe, aCrossCtry, aSuitDisable, aBalcony, aOnTLake, aSolarium, aSuite, aQutZone, aBeautyCb, aMinibar, aTennis, aWhirlPl, aElevator, aSauna, PriceRgLow, PriceRgHigh, DateFromTotal, DateToTotal, aselfcatering, ahalfboard, afullboard, aroomphone, asuitdisableroom, countryID, OrderBy, ResortID, StarRating) dgResultset.DataBind() ' This counts up all the returned records and writes the total into a asp.net label Dim I As Long Dim Counting As Integer Dim RecordCount As Integer Dim TotalRecordCount As Int
For I=0 To dgResultset.Items.Count -1 Counting = 1 RecordCount = RecordCount + Counting Next TotalRecordCount = RecordCount
[asp:datalist RepeatDirection="Vertical" width="650px" ShowHeader="true" EnableViewState="true" ItemStyle-Width="3px" GridLines="none" ID="dgResultset" runat="server"] [headertemplate] [tr] [td colspan="3"][span class="hometitle"]Accommodation available[/span][/td] [/tr] [tr] [td colspan="3"][span class="formlabel"]Your search has resulted in the accommodation listed below. If you want to confirm availability please select the tickbox on any of the accommodation results. Rememeber to send the 'send your enquiry' button at the end of the results.[/span][/br][/br][/td] [/tr] [tr] [td colspan="3" bgcolor="#eeeeee"][span class="AccommResultsedBD"]Accommodation Results[/span] [span class="AccommResultsSmall"]([/span] [asp:Label Text='[%# session("TotalRecordCount") %]' CssClass="AccommResultsSmall" runat="server" /] [span class="AccommResultsSmall"]Item match your selection criteria)[/span][/td] [/tr] [/headertemplate]
Source: http://www.livejournal.com/community/aspdotnet/54652.html
-
Calling ASP2 applications
Date: 01/03/06
(IT Professionals) Keywords: asp, web
How do I instance an ASP2 application from a client machine from within the firewall? Despite that, I wrote it in Visual Studio 2005 Professional Edition, whenever I attempt, it tried to read it as if I wrote it for .Net framework 1.1 and not 2.0. I am calling it over HTTP (i.e., HTTP://pjohnson/website1/default.aspx) where the application resides in a folder in WWWRoot.
Source: http://community.livejournal.com/itprofessionals/31562.html
-
SQL Server Question
Date: 01/18/06
(Asp Dot Net) Keywords: xml, database, asp, web
I'm working on an ASP.Net page that will need to take information from a database, but the information needs to be multi-line, like a numbered list. How would I either store that or display that properly on the web page? Basically part of the output needs to look like this:
Performance Objectives Participant will be able to: 1. Explain the value of standardizing and institutionalizing performance management across all of X 2. Describe the characteristics of a strong performance management culture 3. Explain how to use the tools and processes that will enable differentiation 4. Explain pay for performance and base salary administration
Any suggestions would be useful. I'm not sure how to integrate XML with this since this is so database driven. Thanks.
Source: http://community.livejournal.com/aspdotnet/54950.html
-
asp.net session
Date: 01/18/06
(Asp Dot Net) Keywords: css, asp
below is the code to run my searcg stored procudure i need to find a way to add in the variable TotalRecordCount into the dgResultset dataset so i can call it into the datalist that corrosponds to dgResultset. If there is an easier way of doing it i'd be interested.
Cheers
' Runs the search in the DB for the relevant result Dim SearAccomStat As New Devotion2Motion.AccomSearchClass()
' send the variables to be searched on through to the component in the accomsearch class dgResultset.DataSource = SearAccomStat.SearchAccomStats(accomType, Totalsgle, Totaldble, Totaltwin, TotalTriple, aGarage, aPhone, aCarPark, aTv, aTownCentre, aSwimPool, aRadio, aNearSlopes, aDgsAdmit, aSafe, aCrossCtry, aSuitDisable, aBalcony, aOnTLake, aSolarium, aSuite, aQutZone, aBeautyCb, aMinibar, aTennis, aWhirlPl, aElevator, aSauna, PriceRgLow, PriceRgHigh, DateFromTotal, DateToTotal, aselfcatering, ahalfboard, afullboard, aroomphone, asuitdisableroom, countryID, OrderBy, ResortID, StarRating) dgResultset.DataBind() ' This counts up all the returned records and writes the total into a asp.net label Dim I As Long Dim Counting As Integer Dim RecordCount As Integer Dim TotalRecordCount As Int
For I=0 To dgResultset.Items.Count -1 Counting = 1 RecordCount = RecordCount + Counting Next TotalRecordCount = RecordCount
[asp:datalist RepeatDirection="Vertical" width="650px" ShowHeader="true" EnableViewState="true" ItemStyle-Width="3px" GridLines="none" ID="dgResultset" runat="server"] [headertemplate] [tr] [td colspan="3"][span class="hometitle"]Accommodation available[/span][/td] [/tr] [tr] [td colspan="3"][span class="formlabel"]Your search has resulted in the accommodation listed below. If you want to confirm availability please select the tickbox on any of the accommodation results. Rememeber to send the 'send your enquiry' button at the end of the results.[/span][/br][/br][/td] [/tr] [tr] [td colspan="3" bgcolor="#eeeeee"][span class="AccommResultsedBD"]Accommodation Results[/span] [span class="AccommResultsSmall"]([/span] [asp:Label Text='[%# session("TotalRecordCount") %]' CssClass="AccommResultsSmall" runat="server" /] [span class="AccommResultsSmall"]Item match your selection criteria)[/span][/td] [/tr] [/headertemplate]
Source: http://community.livejournal.com/aspdotnet/54652.html
-
InfoPath 2003 VS Asp.Net
Date: 01/16/06
(Asp Dot Net) Keywords: xml, asp, web
My boss has given me the task of looking into developing a web form that apparently needs to be read by other programs using an XML feed. He suggested using InfoPath 2003, but I then said "Well, ASp.Net would probably be able to do it too." But looking into InfoPath it looks like it may be a good tool for the job. Has anyone had any experience with Infopath, especially vs Asp.Net? I mean I'm not looking to do the most work possible, but also I dont' want to build it in 1 only to have to rebuild it in another to make sure that it can do everything we need it to do. So if anyone has any experience using these tools it'd be greatly appreciated. Thanks.
Source: http://community.livejournal.com/aspdotnet/54390.html
-
Favorite VS .Net 2005 features
Date: 01/09/06
(Asp Dot Net) Keywords: xml, asp, web
I recently installed the new visual studio and I am having a bit of a hard time remembering everything I heard at the 2003 PDC about the new features I can use when doing C# development.
I do remeber the following few: Generics --> has anyone tried this ? Seemed better than having to write your own custom class, is it ? Parial classes -> omg I love this feature ! I love that the very boring generated code wont be in my file. I like my files nice and navigatable. YAY The Xml editor is slightly better but doesnt seem blazing fast as promised. Also I bet some people like not have to use a real web server to test asp pages.
Has anyone tried the team features ? How are they ? Should we get rid of Test Director ?
Thanks !
Source: http://community.livejournal.com/aspdotnet/53224.html
-
Calling ASP2 applications
Date: 01/03/06
(Asp Dot Net) Keywords: asp, web
How do I instance an ASP2 application from a client machine from within the firewall? Despite that, I wrote it in Visual Studio 2005 Professional Edition, whenever I attempt, it tried to read it as if I wrote it for .Net framework 1.1 and not 2.0. I am calling it over HTTP (i.e., HTTP://pjohnson/website1/default.aspx) where the application resides in a folder in WWWRoot.
Source: http://community.livejournal.com/aspdotnet/52694.html
-
First asp.net page - debugging help
Date: 12/23/05
(Asp Dot Net) Keywords: database, asp, sql, microsoft
I'm working on my first asp.net page and am running into some problems. I'm trying to read data from an MS Access database. I'd appreciate if anyone could point me in the right direction - I pretty much lifted the example code from w3schools. Thanks for any help, I'm feeling a bit lost!
The code below gives an error on line 4, character 5 - expected ";".
[%@ Import Namespace="System.Data.OleDb" %> [script runat="server"> sub Page_Load dim dbconn, dbcomm, dbread dbconn=New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=test.mdb") dbconn.Open() sql="SELECT * FROM values" dbcomm=New OleDbCommand(sql,dbconn) dbread=dbcomm.ExecuteReader() value.DataSource=dbread value.DataBind() dbread.Close() dbconn.Close() end sub [/script>
Database: filename: test.mdb, resides in same directory as index.asp file.
table: values fields: ID, key, value
read [s as <.
Source: http://community.livejournal.com/aspdotnet/52113.html
-
visual stuidio 2005 help
Date: 12/11/05
(Asp Dot Net) Keywords: database, asp, sql
I've created 2 pages, one to display data from a database and another to insert data. I'm having trouble with the sql insert query. The first page displays data fine, not in the format I'd like but one thing at a time.
How do I on the second page, create text boxes and the proper connections to insert data into my database. I'm pretty sure this is a simple basic step but I can not figure it out.
Any help or tutorials? I usually hit www.asp.net when I’m stuck and their tutorial is not helping on this one.
Thanks!
Source: http://community.livejournal.com/aspdotnet/51352.html
-
asp - database connection - help me i'm drowning.
Date: 12/08/05
(Asp Dot Net) Keywords: database, asp, sql, web
hello all.. ok here's the story...
i know some basic asp .. i've edited a database driven website fro a while. I'm no trying to create a new site .. thats also database driven.
How do i connect to the server in order to pull info from it?
I tried following the trail from the site i currently update but i'm not sure what i'm seeing here...
Anyone know how to connect an asp site to a sql 2003 database?
Source: http://community.livejournal.com/aspdotnet/51038.html
-
Accessing controls from a GridView EmptyDataTemplate
Date: 12/07/05
(Asp Dot Net) Keywords: css, asp, sql
FYI: Problem resolved
Anyone know how I can access controls within the EmptyDataTemplate of my GridView?
<asp:GridView ID="grdProjectHours" DataSourceID="sqlModifyProjectHours"
PageSize="15" AllowPaging=true AllowSorting=true
AutoGenerateColumns=false GridLines="Both"
ShowFooter=true BorderWidth="2" BorderColor="#000000"
runat=server Width="100%"
OnDataBound="grdProjectHours_OnDataBound"
OnRowUpdating="grdProjectHours_OnRowUpdating"
EditRowStyle-VerticalAlign="top">
...
<Columns>
<asp:TemplateField HeaderText="Project" SortExpression="project">
...
</asp:TemplateField>
</Columns>
<EmptyDataTemplate>
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="gridHeader"><asp:Label ID="lblEmptyProject" runat="server" Text="Project" /></td>
<td class="gridHeader"><asp:Label ID="lblEmptyHours" runat="server" Text="Hours" /></td>
<td class="gridHeader"><asp:Label ID="lblEmptyWorkDate" runat="server" Text="Date of Work" /></td>
<td class="gridHeader"><asp:Label ID="lblEmptyChangeNumber" runat="server" Text="Change Order" /></td>
<td class="gridHeader"><asp:Label ID="lblEmptyComments" runat="server" Text="Comments" /></td>
<td class="gridHeader"></td>
</tr>
<tr>
<td colspan="7" height="2"></td>
</tr>
<tr>
<td colspan="7" bgcolor="#cccccc"></td>
</tr>
<tr>
<td colspan="7" height="1"></td>
</tr>
<tr>
<td class="gridContent"><asp:DropDownList ID="cboNewProject" Width="225" runat="server" DataSourceID="sqlProject" DataTextField="project" DataValueField="id" OnDataBound="cboNewProject_OnDataBound" /></td>
<td class="gridContent"><asp:TextBox ID="txtNewHours" Width="50" runat="server" /></td>
<td class="gridContent"><asp:TextBox ID="txtNewWorkDate" Width="50" runat="server" /></td>
<td class="gridContent"><asp:TextBox ID="txtNewChangeNumber" MaxLength="10" Width="50" runat="server" /></td>
<td class="gridContent"><asp:TextBox ID="txtNewComments" MaxLength="155" Width="100" runat="server" /></td>
<td class="gridContent" align="right"><asp:LinkButton ID="btnAddProjectHours" runat="server" CommandName="insert" Text="add" OnClick="btnAddProjectHours_OnClick" /></td>
</tr>
<tr>
<td class="gridContent"><asp:RequiredFieldValidator ID="reqNewProject" ControlToValidate="cboNewProject" ErrorMessage="Project" CssClass="ErrorMessage" EnableClientScript="false" Display="Dynamic" runat="server" /></td>
<td class="gridContent"><asp:RequiredFieldValidator ID="reqNewHours" ControlToValidate="txtNewHours" ErrorMessage="Hours" CssClass="ErrorMessage" EnableClientScript="false" Display="Dynamic" runat="server" /></td>
<td class="gridContent"><asp:RequiredFieldValidator ID="reqNewWorkDate" ControlToValidate="txtNewWorkDate" ErrorMessage="Date of Work" CssClass="ErrorMessage" EnableClientScript="false" runat="server" /><asp:RangeValidator id="rngWorkDate" runat="server" CssClass="ErrorMessage" ControlToValidate="txtNewWorkDate" MaximumValue="1/1/2100" MinimumValue="1/1/1900" Type="Date" EnableClientScript="false" ErrorMessage="Date of Work (mm/dd/yyyy)" Display="dynamic" /></td>
<td class="gridContent"></td>
<td class="gridContent"></td>
<td class="gridContent" align="right"></td>
</tr>
</table>
</EmptyDataTemplate>
</asp:GridView>
Source: http://community.livejournal.com/aspdotnet/50872.html
-
Calendar Control and Validation
Date: 11/25/05
(Asp Dot Net) Keywords: asp
Validaton of a calender control in asp.net (vb) I need to make sure a value has been clicked in the calendar control and that if there hasn't been a value selected in the calendar control that the page doesn't submit and returns an error.
Source: http://community.livejournal.com/aspdotnet/49250.html
-
File upload control issues with ASP.NET (playing with fire)
Date: 01/03/06
(C Sharp) Keywords: html, asp, security, web
Heya all,
I'm working on a web-based application (using ASP.NET and C# on .NET 1.1.4322, supporting only IE6 for Windows) that allows for file uploads. It seems to be a universally agreed that the file upload control is as ugly as they come, so I want to set its style to "display: none;" and interact only with the standard file upload dialog (which can be summoned by firing the click() method of the control, which is exposed under IE6 but not recent versions of Mozilla).
Attempting programmatic access of a file upload control is generally playing with fire, and this time is apparently no exception. Once I call the click() method, it seems, the page is no longer able to post back. When I attempt to submit the form, the value of the file upload control is cleared and the page just sits there. However, if I make the file upload control visible and manually click its "Browse..." button, the page posts back correctly.
For those of you familiar with Gmail's attachment upload interface, this is very close to the effect I am trying to achieve, but something about ASP.NET is apparently interfering (perhaps for my own protection) with the process. Has anybody experienced similar behavior under the same platform, and if so, explain the behavior or point to a KB article or security documentation that might be enlightening ?
Thanks greatly for your time. Toy code can be found after the cut.
Codeahead:
<%@ Page language="c#" Codebehind="Foo.aspx.cs" AutoEventWireup="false" Inherits="FooApp.Foo" %>
Codebehind:
using System;
using System.Collections;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Web;
using System.Web.SessionState;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;
namespace FooApp
{
public class Foo : System.Web.UI.Page
{
protected HtmlInputFile f;
protected HtmlGenericControl s;
private void Page_Load(object sender, System.EventArgs e)
{
if (this.IsPostBack)
{
s.InnerText = String.Format("{0} file(s) posted", Request.Files.Count);
if (1 == Request.Files.Count) { s.InnerText += String.Format(", content length: {0}", Request.Files[0].ContentLength); }
}
}
override protected void OnInit(EventArgs e)
{
InitializeComponent();
base.OnInit(e);
}
private void InitializeComponent()
{
this.Load += new System.EventHandler(this.Page_Load);
}
}
}
Source: http://community.livejournal.com/csharp/45787.html
-
Of Character Encodings
Date: 11/18/05
(C Sharp) Keywords: database, asp, sql, web
I am converting a web app from ASP to ASP.net and have stumbled on an annoying problem.
1. ASP code accepts user input and stores value in the database SQL field type is nvarchar(200). BUT the query does not use N'' to specify that the string is unicode.
2. Value stored in the database is '陳å°æ˜¥'
3. Value displayed on web page (utf8 encoding, no server side changes) is '陳小春'
4. Actual UTF data in the database is displayed on screen as ??? (database value: 人, display value: ?)
5. ASP.net application using the EXACT same queries results in point 4 being displayed correctly (as japanese) but the values that were displayed correctly in the ASP app are now exactly as they are in the database.
Please Help ... My only guess was that the ADO connection was converting the UTF in the database to Non-UTF for display in ASP and the ADO connection in .Net is preserving the Unicodeness of it.
But i did a simple test in ASP where i selected the data, stored it in a variable and then inserted back into the database (non using N'') and well ... i got the exact same .... japanese was japanese the rest was garbage.
Anyone have any ideas???
Source: http://community.livejournal.com/csharp/41546.html
-
Offtopic: почему некоторые так пишут
Date: 01/03/06
(Code WTF) Keywords: asp
Немного о том, откуда берутся некоторые образцы для code_wtf. http://blogs.msdn.com/oldnewthing/archive/2005/12/28/508689.aspx
В статье неплохо изложено, чем мог руководствоваться человек, сделавший вот такую утечку памяти: void sample()
{
LPDWORD lpdw = new DWORD;
if (GetBinaryType(TEXT("explorer.exe"), lpdw)) {
...
}
}
Source: http://community.livejournal.com/code_wtf/22779.html
-
PHP designer
Date: 01/04/06
(PHP Development) Keywords: php, asp
Hi,
Is there any PHP GUI available for development of PHP scripts? like windows guys use ASP .NET? or Visual Basic or Qt Designer for KDE people?
If not, anybody interested in developing such thing?
X-Posted to php
Source: http://community.livejournal.com/php_dev/62818.html
|