Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is there an easier way
Message
 
To
23/06/2002 21:15:51
John Baird
Coatesville, Pennsylvania, United States
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00671465
Message ID:
00671557
Views:
20
>I understand the use of ranges (I think). The problem is that you don't get fully formed boxes when you use a range. The only way I could get it to work was loop through each cell succesively setting the form for all four sides.
>
>The command .Borders(xlHorizontalInside).LineStyle = xlContinuous and
>.Borders(xlHorizontalInside).LineStyle = xlContinuous both gave me an error when used with the range. Without them, you just get 2 vertical lines....not horizontal. If you set a range like your suggesting, you get a border around the entire range, not around each cell.

Try this:
WITH oSheet.UsedRange
	.Borders(xlEdgeTop).LineStyle	 = xlContinuous
	.Borders(xlEdgeLeft).LineStyle 	 = xlContinuous
	.Borders(xlEdgeRight).LineStyle  = xlContinuous
	.Borders(xlEdgeBottom).LineStyle = xlContinuous
	.Borders(xlInsideHorizontal).LineStyle  = xlContinuous
	.Borders(xlInsideVertical).LineStyle = xlContinuous
ENDWITH
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform