473,503 Members | 2,178 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

copy to a folder

29 New Member
hi,

I have created a .aspx page, where it generates a matrix in excel sheet.
I passed projectid and other three items in query string.

Now whenever a user generates a matrix ( i mean opens the .aspx page)
it should also be stored in a folder on the server.
I mean that page should be stored in a folder on the server.
For example, if the aspx page is c:\\test.com\pgMy.aspx?pid=823 & p=1
and the folder on the server be StorageFolder
I want to store this page in StorageFolder.

Some times the pid and p values change, it will be stored as a different page.

Does any one have the idea as how to do it?

Its really urgent.

Thanks
Aug 6 '06 #1
2 1672
Began
3 New Member
hi,

the below code will create a file and store it in c deive.

ExcelApplication excel = new ExcelApplication();
excel.Visible = true;

excel.Workbooks.Add(Missing.Value);
Worksheet worksheet = (Worksheet) excel.ActiveSheet;

Range r = worksheet.get_Range("C6", Missing.Value);
r.Value2 = "Hello";
r.Interior.ColorIndex = 6;

worksheet.SaveAs(@"c:\ExcelExample.xls",
Missing.Value, Missing.Value, Missing.Value, Missing.Value,
Missing.Value, Missing.Value, Missing.Value, Missing.Value,
Missing.Value);
excel.Quit();

regards,
Began.
Aug 7 '06 #2
priya0123
29 New Member
Thanks,

Let me try, I will let u know the output.


hi,

the below code will create a file and store it in c deive.

ExcelApplication excel = new ExcelApplication();
excel.Visible = true;

excel.Workbooks.Add(Missing.Value);
Worksheet worksheet = (Worksheet) excel.ActiveSheet;

Range r = worksheet.get_Range("C6", Missing.Value);
r.Value2 = "Hello";
r.Interior.ColorIndex = 6;

worksheet.SaveAs(@"c:\ExcelExample.xls",
Missing.Value, Missing.Value, Missing.Value, Missing.Value,
Missing.Value, Missing.Value, Missing.Value, Missing.Value,
Missing.Value);
excel.Quit();

regards,
Began.
Aug 7 '06 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
4493
by: Frank | last post by:
I have files in myurl.com/myfolder and I would like to copy all of them into myurl.com/newfolder I'd like to copy all of the subdirectories and files that are in /myfolder and I would...
8
17013
by: Ram Baruch | last post by:
Hi, I'm trying to use the File.Copy() function. It works well when the desenation file is local (Like: C:\dest\dest.exe). The problem is that when I'm trying to copy to a destenation that starts...
8
2557
by: Paw | last post by:
Greetings. I use asp. what I need is is when a visitor comes to the site, I need it to check the host name. if "www.hometowndigest.com" is the host, then check a folder named "something" and if...
4
11722
by: sajid_yusuf | last post by:
Hi I am trying to develop a Windows service in VB.NET which has timer enabled and keeps checking a folder (or group of folders) for any new file or changed files. As soon as it detects any new...
5
3246
by: Saabster | last post by:
Hi all, It's always the simple stuff that trips you up I guess. Here is the issue I'm dealing with. I have a folder with 1400 excel files that I need to move to another location. Since each...
25
2854
by: Andy_Khosravi | last post by:
I just recently changed my database that I'm running from a monolithic DB to a split FE/BE. The front end resides on the client machine and the BE resides on a network drive. I'm experimenting with...
1
3859
by: =?Utf-8?B?UVNJRGV2ZWxvcGVy?= | last post by:
Using .NET 2.0 is it more efficient to copy files to a single folder versus spreading them across multiple folders. For instance if we have 100,000 files to be copied, Do we copy all of them to...
3
5115
by: =?Utf-8?B?R2FuZXNoYQ==?= | last post by:
Hi I would like to use File.Copy with UNC paths. I have seen this problem reported by others as well. Can i use File.Copy with UNC paths. ie., i would like to copy a file from one of the folder to...
9
6488
by: AWW | last post by:
Running XP - Visual Studio 2005 - VB Want to have duplicate projects - one safe and stable - other for experimenting Can't fine easy way to make duplicate project. Stupid question? or stupid ME?...
3
4612
by: David V | last post by:
I'm having trouble copying DLLs from a folder in my project to the project's output directory. I have copied seven SQL CE DLLs (the SqlCe*.dll set) to a Libs folder in my project. The DLLs VS...
0
7093
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7353
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7011
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7468
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
5023
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4689
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3180
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3170
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
401
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.