473,378 Members | 1,067 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

NumberFormat in Excel

hi,

I have tried to automate excel (2007) in vb.net and i have problem
with function NumberFormat.
I want set the thousand separator for range:
Range("C1:C6").NumberFormat = "0,0.00"
and it pops up an error msg like: can't set property NumberFormat for
Range

Does anyone know the solution??

thanks in advance.
MaTe
Jun 27 '08 #1
4 4479
On May 22, 3:49*am, MaTe <matelk...@gmail.comwrote:
hi,

I have tried to automate excel (2007) in vb.net and i have problem
with function NumberFormat.
I want set the thousand separator for range:
* *Range("C1:C6").NumberFormat = "0,0.00"
and it pops up an error msg like: can't set property NumberFormat for
Range

Does anyone know the solution??

thanks in advance.
*MaTe
Take out the comma and see what happens.
Jun 27 '08 #2
On May 22, 6:48 pm, scorpion53061 <kellyjmart...@gmail.comwrote:
On May 22, 3:49 am, MaTe <matelk...@gmail.comwrote:
hi,
I have tried to automate excel (2007) in vb.net and i have problem
with function NumberFormat.
I want set the thousand separator for range:
Range("C1:C6").NumberFormat = "0,0.00"
and it pops up an error msg like: can't set property NumberFormat for
Range
Does anyone know the solution??
thanks in advance.
MaTe

Take out the comma and see what happens.
allways the same error :-(
Jun 27 '08 #3
On May 22, 12:42*pm, MaTe <matelk...@gmail.comwrote:
On May 22, 6:48 pm, scorpion53061 <kellyjmart...@gmail.comwrote:


On May 22, 3:49 am, MaTe <matelk...@gmail.comwrote:
hi,
I have tried to automate excel (2007) in vb.net and i have problem
with function NumberFormat.
I want set the thousand separator for range:
* *Range("C1:C6").NumberFormat = "0,0.00"
and it pops up an error msg like: can't set property NumberFormat for
Range
Does anyone know the solution??
thanks in advance.
*MaTe
Take out the comma and see what happens.

allways the same error :-(- Hide quoted text -

- Show quoted text -
IN this case write all the data from c1-c6 to a text file instead and
see if you have a data issue that might be preventing it from being
able to be formatted in this fashion.
Jun 27 '08 #4
On May 22, 9:16 pm, scorpion53061 <kellyjmart...@gmail.comwrote:
On May 22, 12:42 pm, MaTe <matelk...@gmail.comwrote:
On May 22, 6:48 pm, scorpion53061 <kellyjmart...@gmail.comwrote:
On May 22, 3:49 am, MaTe <matelk...@gmail.comwrote:
hi,
I have tried to automate excel (2007) in vb.net and i have problem
with function NumberFormat.
I want set the thousand separator for range:
Range("C1:C6").NumberFormat = "0,0.00"
and it pops up an error msg like: can't set property NumberFormat for
Range
Does anyone know the solution??
thanks in advance.
MaTe
Take out the comma and see what happens.
allways the same error :-(- Hide quoted text -
- Show quoted text -

IN this case write all the data from c1-c6 to a text file instead and
see if you have a data issue that might be preventing it from being
able to be formatted in this fashion.
each of this cell containing correct number
Jun 27 '08 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: v_verno | last post by:
Good day, I have a web page that shows info retrieved from a MySQL db and I would like to convert all these data into an .XLS file. Have searched the net high and low but seems that I'm unable to...
3
by: Otie | last post by:
I found the following under the GetObject help notes and in the example for GetObject: "This example uses the GetObject function to get a reference to a specific Microsoft Excel worksheet...
0
by: B | last post by:
Using Access2000, the sample code below is what I have been modifying and working on since the past week and I could not get it to work properly. What I wanted to accomplish: 1) read from a...
9
by: Andi Plotsky | last post by:
I have an Access app (running under Access2000) where I want to export the data to an Excel spreadsheet. This has worked fine in the past, but after taking it to my client site (where I ran it...
4
by: BerkshireGuy | last post by:
I have the following Access code that exports to Excel, inserts a title, changes the color of the title, and then changes the format of several columns to currency. The following code sometimes...
1
by: stf | last post by:
Hello, I use c# to start excel and to get numberformat of active cell. VBA outputs results as expected, but via c# i get result 'Standard' instead of 'General' for a call to numberformat. Why?...
8
by: John Brock | last post by:
I am creating an Excel workbook using VB.NET, and have run into a problem. Excel at times insists on reformatting data that I enter into cells, e.g., converting "01234" to "1234", and this screws...
4
by: wellscrambled | last post by:
Folks, Probably don't have the right forum here, but this is all a bit new to me. I have a web site that sends me a daily email with an excel spreadsheet attachment that contains some customer...
3
kirubagari
by: kirubagari | last post by:
I would like to duplicate the numbers from from excel sheet 1 to excel sheet 2.Kindly help me on this.Sometime its unable to duplicate.. Sub Duplicate Dim oDoc As Object, oSheet As Object,...
1
kirubagari
by: kirubagari | last post by:
Hai experts, How to duplicate the data from 1 excel sheet to another excel sheet 2. Lets say Name Voucher Value Voucher Number lee 300.00 ...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.