Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > Other .NET > General .NET
|
General .NET For general discussion of MICROSOFT .NET topics that don't fall within any of the other .NET forum subcategories or .NET language forums.  If your question is specific to a language (C# or Visual Basic) or type of application (Windows Forms or ASP.Net) try an applicable forum category. ** PLEASE BE SPECIFIC WITH YOUR QUESTION ** When posting here, provide details regarding the Microsoft .NET language you are using and/or what type of application (Windows/Web Forms, etc) you are working in, if applicable to the question. This will help others answer the question without having to ask.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the General .NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 21st, 2004, 08:55 AM
dkb dkb is offline
Authorized User
 
Join Date: Oct 2003
Posts: 33
Thanks: 0
Thanked 0 Times in 0 Posts
Default Pasting Data into a webform

Hi there,

Just a quick query....

Does anyone know if there is a .net control that would allow a user to past columns of data into it? (say from Excel or Access).

I'm not sure if this is something the DataGrid will allow....

Thanks



 
Old June 22nd, 2004, 07:51 AM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

You are limited to what HTML is capable of. Unfortunately, HTML doesn't have the ability to do what you want. However...

When you copy from excel and paste into a text-only control (be it notepad or a HTML text area) the column values are separated by tabs and the rows by a carriage return/line feed. So you could provide a "paste area" where someone could paste text copied from Excel, then you just need to parse the text for the correct separater characters. In the case of .NET, look for Environment.Newline and the tab literal (" ", which probably won't show up with this is posted, but it's just a tab between quotes). Then you can construct whatever data structure you would like from that parsing.
 
Old July 4th, 2004, 04:29 AM
dkb dkb is offline
Authorized User
 
Join Date: Oct 2003
Posts: 33
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks very much for your answer!






Similar Threads
Thread Thread Starter Forum Replies Last Post
pasting data from clipboard rahesh Visual Basic 2005 Basics 0 May 23rd, 2008 12:40 PM
Pasting into spreadsheets IainAL VB How-To 0 April 23rd, 2007 04:33 AM
Copy and Pasting jilly Beginning VB 6 1 March 8th, 2006 09:46 AM
easy pasting problem reverand Excel VBA 17 November 25th, 2005 01:11 AM
Pasting information to a second database Brendan Bartley Access 1 September 27th, 2005 09:45 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.