| Author | Topic: Help setting "borders" to a group of cells |
---|
| Juan Gonzalez | Help setting "borders" to a group of cells
on Mon, 09 Jan 2023 16:15:43 +0100Hello,
I am having trouble with the sintax to set a border to a group of cells while
generating an Excel file trough ActiveX. All the other properties (format,
colors, etc) are working ok in my code.
This is the part of code with the problem:
oRange:=oExcel:Range("E8:O9")
oRange:Borders["xlEdgeBottom"]:LineStyle:="xlMedium"
But returns error "Parameter has wrong data type".
I cant find where...
Thank you very much,
Juan. |
| Jim Lee | Re: Help setting "borders" to a group of cells
on Tue, 10 Jan 2023 00:22:52 +0100hi,
> oRange:Borders["xlEdgeBottom"]:LineStyle:="xlMedium"
>
> But returns error "Parameter has wrong data type".
hi,
#DEFINE
-4138
to "generate" *.CH of all Constante use Tlb2Ch.exe
Tlb2Ch.exe "EXCEL.APPLICATION" >> EXCEL.CH |
| Juan Gonzalez | Re: Help setting "borders" to a group of cells
on Tue, 10 Jan 2023 11:52:55 +0100Hello Jim, thank you for your answer.
I am using excel.ch in my project, so all the constants are defined here. I
can find xlEdgeBottom and xlMedium...
There is some other syntax error in my line
oRange:Borders["xlEdgeBottom"]:LineStyle:="xlMedium"
Regards,
JJ
Jim Lee wrote in message news:7a88ca90$1fc6dfa0$1117ac@news.alaska-
software.com...
>hi,
>
>> oRange:Borders["xlEdgeBottom"]:LineStyle:="xlMedium"
>>
>> But returns error "Parameter has wrong data type".
>
>hi,
>
>#DEFINE
> -4138
>
>to "generate" *.CH of all Constante use Tlb2Ch.exe
>
>Tlb2Ch.exe "EXCEL.APPLICATION" >> EXCEL.CH |
| Regan Cawkwell | Re: Help setting "borders" to a group of cells
on Tue, 10 Jan 2023 12:31:14 +0100 |
| Damir Hodak | Re: Help setting "borders" to a group of cells
on Tue, 10 Jan 2023 15:39:24 +0100On Tue, 10 Jan 2023 11:52:55 +0100, Juan Gonzalez wrote:
> Hello Jim, thank you for your answer.
>
> I am using excel.ch in my project, so all the constants are defined here. I
> can find xlEdgeBottom and xlMedium...
>
> There is some other syntax error in my line
>
> oRange:Borders["xlEdgeBottom"]:LineStyle:="xlMedium"
>
> Regards,
> JJ
>
>
> Jim Lee wrote in message news:7a88ca90$1fc6dfa0$1117ac@news.alaska-
> software.com...
>>hi,
>>
>>> oRange:Borders["xlEdgeBottom"]:LineStyle:="xlMedium"
>>>
>>> But returns error "Parameter has wrong data type".
>>
>>hi,
>>
>>#DEFINE
>> -4138
>>
>>to "generate" *.CH of all Constante use Tlb2Ch.exe
>>
>>Tlb2Ch.exe "EXCEL.APPLICATION" >> EXCEL.CH
Hi Juan!
Your line should be:
oRange:Borders[xlEdgeBottom]:LineStyle:=xlMedium
Regards
Damir |