Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default HTML / Excel format problem

I'm not sure if this is the correct group in which to post this, but here goes.

I'm creating a spreadsheet in an ASP page where I include the meta tag so that the browser converted the data into an excel file. The Meta tag is added as follows:
Response.AddHeader("Content-Type", "application/x-msexcel")

But no matter what I do, if the user tries to sort the data I get this error:
This operation requires the merged cells to be identically sized

I see that there is a workaround of highlighting the data and unmerging the cells, but I'm not sure that my client is going to go for that solution. However I cannot figure out why it thinks the cells are merged. All cells are individual when I create the page so I'm baffled.

Is there anyone who has figured out how to get rid of this problem?

Thanks,
Velvet

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 225
Default HTML / Excel format problem

Hi Velvet,

Thanks for your posting!
I did not understand your scenario very much.
Firstly I would like to clarify the scenario with you.
Do you mean you want to Export an Excel file in an asp page?
So that when the End User access to the ASP page with IE, the Excel
Application will open to show the Excel file.
or
Can you describe the scenario more clearly?

Best regards,

Peter Huang

Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default HTML / Excel format problem

Yes. Basically the ASP page find whether the user wants to see the data
from the query in HTML or to be saved as an XLS file. Depending on the form
selection I set the meta tag MIME type to HTML or XLS mode.

If the user chooses XLS (and I add the MIME type header), then the browser
pops up a message asking if they want to open the file or save it. My
customer wants to save it and then open it offline. When they open it,
after saving to the local hard drive, and he tried to sort the data he get's
the afore mentioned error.

The workaround to the error is to unmerge the merged cells, but I would
rather not have any of them merged in the first place. I'm wondering if
this is something I'm doing in my table (in the way of formatting) to make
the cells merge or if this is just par for the course when using the MIME
type for conversion. I think I'll just have it spit out one row and see if
the error still pops.

Thanks!
Velvet

""Peter Huang" [MSFT]" wrote in message
...
Hi Velvet,

Thanks for your posting!
I did not understand your scenario very much.
Firstly I would like to clarify the scenario with you.
Do you mean you want to Export an Excel file in an asp page?
So that when the End User access to the ASP page with IE, the Excel
Application will open to show the Excel file.
or
Can you describe the scenario more clearly?

Best regards,

Peter Huang

Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no
rights.



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default HTML / Excel format problem

Ok, I only spit out about 40 rows and the error didn't happen. So now I'm
convinced it's something in the data. Maybe a double quote messing up the
formatting or something... More testing...


"Velvet" wrote in message
...
Yes. Basically the ASP page find whether the user wants to see the data
from the query in HTML or to be saved as an XLS file. Depending on the
form selection I set the meta tag MIME type to HTML or XLS mode.

If the user chooses XLS (and I add the MIME type header), then the browser
pops up a message asking if they want to open the file or save it. My
customer wants to save it and then open it offline. When they open it,
after saving to the local hard drive, and he tried to sort the data he
get's the afore mentioned error.

The workaround to the error is to unmerge the merged cells, but I would
rather not have any of them merged in the first place. I'm wondering if
this is something I'm doing in my table (in the way of formatting) to make
the cells merge or if this is just par for the course when using the MIME
type for conversion. I think I'll just have it spit out one row and see if
the error still pops.

Thanks!
Velvet

""Peter Huang" [MSFT]" wrote in message
...
Hi Velvet,

Thanks for your posting!
I did not understand your scenario very much.
Firstly I would like to clarify the scenario with you.
Do you mean you want to Export an Excel file in an asp page?
So that when the End User access to the ASP page with IE, the Excel
Application will open to show the Excel file.
or
Can you describe the scenario more clearly?

Best regards,

Peter Huang

Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no
rights.





  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default HTML / Excel format problem

Found it! It was a <br that the client had added to the field contents in
the database.

Thanks!


"Velvet" wrote in message
...
Ok, I only spit out about 40 rows and the error didn't happen. So now I'm
convinced it's something in the data. Maybe a double quote messing up the
formatting or something... More testing...


"Velvet" wrote in message
...
Yes. Basically the ASP page find whether the user wants to see the data
from the query in HTML or to be saved as an XLS file. Depending on the
form selection I set the meta tag MIME type to HTML or XLS mode.

If the user chooses XLS (and I add the MIME type header), then the
browser pops up a message asking if they want to open the file or save
it. My customer wants to save it and then open it offline. When they
open it, after saving to the local hard drive, and he tried to sort the
data he get's the afore mentioned error.

The workaround to the error is to unmerge the merged cells, but I would
rather not have any of them merged in the first place. I'm wondering if
this is something I'm doing in my table (in the way of formatting) to
make the cells merge or if this is just par for the course when using the
MIME type for conversion. I think I'll just have it spit out one row and
see if the error still pops.

Thanks!
Velvet

""Peter Huang" [MSFT]" wrote in message
...
Hi Velvet,

Thanks for your posting!
I did not understand your scenario very much.
Firstly I would like to clarify the scenario with you.
Do you mean you want to Export an Excel file in an asp page?
So that when the End User access to the ASP page with IE, the Excel
Application will open to show the Excel file.
or
Can you describe the scenario more clearly?

Best regards,

Peter Huang

Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no
rights.









  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 225
Default HTML / Excel format problem

Hi Velvet,

Thanks for your quickly reply!
I am glad you have found the solution.
If you still have any concern, please feel free to post here.

Best regards,

Peter Huang

Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Automation problem saving Excel as HTML. nicol Excel Programming 1 February 1st 06 10:16 AM
Problem saving Excel file in HTML format nicol Excel Programming 0 January 24th 06 10:42 AM
how to convert a html page to excel format ? michaeltan Excel Discussion (Misc queries) 9 August 3rd 05 06:02 AM
Use excel in html format change the links Eric van der Linden Excel Programming 0 February 4th 04 02:12 PM
HTML TAGS that format Data for import into Excel Warren LaFrance Excel Programming 1 November 5th 03 03:46 PM


All times are GMT +1. The time now is 06:34 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"