I'm confused as hell with all the bazillion ways to read/write/create excel files. VSTO, OLEDB, etc, but they all seem to have the requirement that office must be installed.
Here is my situation: I need to develop an app which will take an excel file as input, do some calculations and create a new excel file which will basically be a mo...
Here is the code that applies an advanced filter to the column A on the Sheet1 worksheet (List range) by using the range of values on the Sheet2 (criteria range)
Range("A1:A100").AdvancedFilter Action:=xlFilterInPlace, CriteriaRange:= _
Sheets("Sheet2").Range("A1:A10"), Unique:=False
After running this code, I need to do somet...
I have a c++ unmanaged project whose output is an .xll file which is an add-in loaded by excel at startup, this add-in can work with both versions, excel 2003 and excel 2007.
Now, what I need to do is to obtain the version of the excel instance that the user is actually using for working with my add-in.
Does anyone can suggest me how t...
I have some code which intercepts the Before_Print event in excel to make sure that the user has filled in all the required fields before they print the sheet. However, I only want this code to fire when the user is actually printing, not when they are just calling the print preview.
Is there any way to tell in the Before_Print code wh...
I am working on an Excel report and I would like the top rows to be empty to allow for an image to be inserted. However, I do not want the image size to change the width of the columns and would rather the data below do that.
This is what I have so far:
If ComDset.Tables(0).Rows.Count > 0 Then
Try
With Excel
...
Hi
How can I set the column width and leave the top 10 rows empty in order to insert an image into my Excel report?
Here is my code:
If ComDset.Tables(0).Rows.Count > 0 Then
Try
With Excel
.SheetsInNewWorkbook = 1
.Workbooks.Add()
.Worksheets(1).Select()
Dim i As Integer = 1...
Hi,
I have an XML schema and an XML data file.
I've implemented it in Excel and it works great.
I want to Automate the process using vb.
I want to open the xls file, the schema is already mapped in the file.
then I want to import the XML data file and print a selected working sheet.
this is the code that I have to open the file and t...
This is a follow on question to
How to properly clean up excel interop objects in c#.
The gyst is that using a chaining calls together (eg. ExcelObject.Foo.Bar() ) within the Excel namespace prevents garbage collection for COM objects. Instead, one should explicitly create a reference to each COM object used, and explicitly release the...
I've an excel spreadsheet with a column which has the date and time of a particular event. I would like to round this to the nearest 15 minute interval so that I can count the total number of events in this period. What is the best way to do do the rounding?
...
I have written a program in C# whereby it automatically generates a graph for me from a CSV file and puts it onto a new XLS file. However, I need to change the color of the Line (as it is a Line Chart) to red rather than the default blue.
I am finding this extremely difficult to do and the stuff I've found online has not worked. Please ...
In our project we have an excel template (.xlt) and an add-ins file (.xla). These files are used to create a dataview. Dataview is nothing but a kind of report. The xla contains code to create controls for creating, deleting, managing the dataview and its contents. These controls are OCX controls created in VC++ for creating the dataview...
Hi
How to read the excel file and show its data in grid view ? I tried the ODBC provider its working but, it is happening win "Dns=EXCELF", how it will possible with connection sring ? I generate my Excel sheet connection string as :
Provider=MSDASQL.1;Persist Security Info=False;User ID=admin;Data Source=Excel Files;Initial Catalog=D:\...
I'm using AxFramerControl in order to embed Excel worksheet in my application. The problem is - each time a dialog window or something like that obscures part of the worksheet, the worksheet is not repainted automatically. Calling axFramerControl.Refresh() doesn't help. What can be done?
...
Hi there,
I'm wanting to SUM a number of rows in Excel, based on a value. In the picture below, you can see the table.
I want to put a value in F1, containing the sum of the values for Jan -> (month # specified in C2) where the Status is the value in C1.
If you do
=SUMIF(B5:B11,"open",INDIRECT(CONCATENATE("C5:",ADDRESS(11,2+C2))))
...
Hi All,
I'm a sys admin and I am trying to learn how to use powershell... I have never done any type of scripting or coding before and I have been teaching myself online by learning from the technet script centre and online forums.
What I am trying to accomplish is to open an excel spreadsheet get information from it (usernames and pas...
Is there some trick to getting a SpringMVC custom view to cause a file download in the broswer? I've implemented the render method from org.springframework.web.servlet.View but the code results in my data being written to the page as a blob of data rather having a download action start.
try {
Document oDoc = (Document) model.get("o...
is it possible to run excel with an SAS engine and run SAS code on it?
the purpose of this i want to learn SAS a little bit and i dont want to buy it, so maybe i could use it through excel?
...
My application lets user download their data as csv files. These are supposed to open in spreadsheet applications. On a linux system, I get prompted correctly to open with OpenOffice. But some of my users complain that when they download the file, it doesnot open automatically excel, but asks them to choose the application. When they dow...
Hello everyone,
I am using the following code in classic ASP to generate Excel file, the code is simple and it works. I run the code under IIS 7.0 on Windows Vista x86. Two issues,
there is a weird warning box, here is the screen snapshot
http://i27.tinypic.com/2n81udw.jpg
All cells' background is white, no border of each cell sho...
original column is like:
0.45::rafas::4.0::0.0::0.9
0.35::rasaf::4.0::110.0::1.0
and i would like to break the string in to the following (:: as separator) in Excel
col1 col2 col3 col4 col5
0.45::rafas::4.0::0.0::0.9 0.45 rafas 4.0 0.0 0.9
0.35::rasaf::4.0::110.0::1.0 0.35 rasaf 4.0...