Commit a8a684bf authored by ElenaSubbotina's avatar ElenaSubbotina

xlst->xlsx fix chart range (= defined name)

parent 64a7d22f
...@@ -789,6 +789,10 @@ namespace BinXlsxRW{ ...@@ -789,6 +789,10 @@ namespace BinXlsxRW{
} }
} }
} }
else
{
//range is defined name
}
} }
} }
void ChartWriter::parseMultiLvlStrRef(const OOX::Spreadsheet::CT_MultiLvlStrRef* pMultiLvlStrRef, bool bUpdateRange, const wchar_t* cRangeName) void ChartWriter::parseMultiLvlStrRef(const OOX::Spreadsheet::CT_MultiLvlStrRef* pMultiLvlStrRef, bool bUpdateRange, const wchar_t* cRangeName)
......
...@@ -408,6 +408,7 @@ namespace OOX ...@@ -408,6 +408,7 @@ namespace OOX
bool bRes = false; bool bRes = false;
int nIndex = sRef.Find('!'); int nIndex = sRef.Find('!');
CString sCellRef; CString sCellRef;
if(-1 != nIndex) if(-1 != nIndex)
{ {
CString sSheetPrefix = sRef.Left(nIndex); CString sSheetPrefix = sRef.Left(nIndex);
...@@ -416,8 +417,10 @@ namespace OOX ...@@ -416,8 +417,10 @@ namespace OOX
sSheetPrefix = sSheetPrefix.Mid(1, sSheetPrefix.GetLength() - 2); sSheetPrefix = sSheetPrefix.Mid(1, sSheetPrefix.GetLength() - 2);
} }
sSheetPrefix.Replace(L"''", L"'"); sSheetPrefix.Replace(L"''", L"'");
int nIndexWbStart = sSheetPrefix.Find('['); int nIndexWbStart = sSheetPrefix.Find('[');
int nIndexWbEnd = sSheetPrefix.Find(']'); int nIndexWbEnd = sSheetPrefix.Find(']');
if(-1 != nIndexWbStart && -1 != nIndexWbEnd) if(-1 != nIndexWbStart && -1 != nIndexWbEnd)
{ {
workbook = sSheetPrefix.Mid(nIndexWbStart + 1, nIndexWbEnd - nIndexWbStart - 1); workbook = sSheetPrefix.Mid(nIndexWbStart + 1, nIndexWbEnd - nIndexWbStart - 1);
...@@ -456,6 +459,7 @@ namespace OOX ...@@ -456,6 +459,7 @@ namespace OOX
static bool parseRef(CString sRef, int& nRow, int& nCol) static bool parseRef(CString sRef, int& nRow, int& nCol)
{ {
bool bRes = false; bool bRes = false;
nRow = 0; nRow = 0;
nCol = 0; nCol = 0;
int nLegnth = sRef.GetLength(); int nLegnth = sRef.GetLength();
...@@ -477,8 +481,11 @@ namespace OOX ...@@ -477,8 +481,11 @@ namespace OOX
{ {
nCol = nCol * 26 + sAdd[i] - 'A' + 1; nCol = nCol * 26 + sAdd[i] - 'A' + 1;
} }
if (!sDig.IsEmpty())
{
nRow = _wtoi(sDig); nRow = _wtoi(sDig);
bRes = true; bRes = true;
}
} }
} }
return bRes; return bRes;
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
QT -= core QT -= core
QT -= gui QT -= gui
VERSION = 2.0.2.391 VERSION = 2.0.2.392
DEFINES += INTVER=$$VERSION DEFINES += INTVER=$$VERSION
TEMPLATE = app TEMPLATE = app
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment