By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,852 Members | 865 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,852 IT Pros & Developers. It's quick & easy.

Format problem in excel sheet data retrieval

P: 5
Hi all,

I am developing a vb application to retrive data from excel file using excel object.

But the probelm is, the extracted data is not in the correct format.
I am retriving time values such as 22:29 ie in HH:MM format.But my retrived data will be like this:0.965972222 . How can I retrive data in the correct format?
Please help me..
Mar 17 '08 #1
Share this Question
Share on Google+
2 Replies


QVeen72
Expert 100+
P: 1,445
Hi,

Try this :

Text1.Text = Format(0.965972222 ,"HH:MM")

Regards
Veena
Mar 18 '08 #2

P: 5
Hi,

Try this :

Text1.Text = Format(0.965972222 ,"HH:MM")

Regards
Veena
Hi Veena,

Its working fine now. I had tried this function before, but at that time it is working erronously ie. for some values it is showing correct format , but for others not.
I have find out the problem. It is with worksheets. My excel sheet contain several worksheets, and I was using the wrong one.After using the correct worksheet it is solved.Anyway, thank you for your help.
Mar 18 '08 #3

Post your reply

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