Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Casting Error in Export-Excel #108

Closed
fMichaleczek opened this issue Jun 28, 2016 · 5 comments
Closed

Casting Error in Export-Excel #108

fMichaleczek opened this issue Jun 28, 2016 · 5 comments
Assignees

Comments

@fMichaleczek
Copy link

I have an reccurent error in Export-Excel.ps1

The french message error is (sorry I don't have a english system available now) :
Surcharge introuvable pour « TryParse » et le nombre d'arguments « 4 ».

Problem is a casting problem that can be resolve in ligne 184 :

Before :
if( [Double]::TryParse( $cellValue, [System.Globalization.NumberStyles]::Any, [System.Globalization.NumberFormatInfo]::InvariantInfo, [ref]$r ) ) {

After :
if( [Double]::TryParse( [string]$cellValue, [System.Globalization.NumberStyles]::Any, [System.Globalization.NumberFormatInfo]::InvariantInfo, [ref]$r ) ) {

@dfinke
Copy link
Owner

dfinke commented Jun 28, 2016

Thanks, I'll investigate.

@dfinke dfinke self-assigned this Jun 28, 2016
@dfinke
Copy link
Owner

dfinke commented Jun 28, 2016

@fMichaleczek Please, could you post a small sample of data that causes the problem

@fMichaleczek
Copy link
Author

gps | Export-Clixml -Path $env:temp\a.clixml
$gps = Import-Clixml -Path $env:temp\a.clixml
$gps | Export-Excel -Path $env:temp\a.xlsx

@dfinke
Copy link
Owner

dfinke commented Jun 28, 2016

Great, could you post the a.clixml file?

@dfinke
Copy link
Owner

dfinke commented Jun 28, 2016

never mind. it caused the error on my side

dfinke added a commit that referenced this issue Jun 28, 2016
@dfinke dfinke closed this as completed Jun 28, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants