Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@
!/Examples/*.cpp
!/Examples/external
!/Examples/external/*
!/Examples/files
!/Examples/files/*
!/Examples/images
!/Examples/images/*

# include gnu-make-crutch folder
!/gnu-make-crutch
Expand Down
6 changes: 6 additions & 0 deletions Examples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -87,3 +87,9 @@ target_link_libraries(Demo9 PRIVATE OpenXLSX::OpenXLSX)
#=======================================================================================================================
add_executable(Demo10 Demo10.cpp)
target_link_libraries(Demo10 PRIVATE OpenXLSX::OpenXLSX)

#=======================================================================================================================
# Define Demo11 target
#=======================================================================================================================
add_executable(Demo11 Demo11.cpp)
target_link_libraries(Demo11 PRIVATE OpenXLSX::OpenXLSX)
4 changes: 2 additions & 2 deletions Examples/Demo1.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ using namespace OpenXLSX;
void printAllDocumentComments(XLDocument const & doc)
{
for( size_t i = 1; i <= doc.workbook().worksheetCount(); ++i ) {
auto wks = doc.workbook().worksheet(i);
auto wks = doc.workbook().worksheet(static_cast<uint16_t>(i));
if( wks.hasComments() ) {
std::cout << "worksheet(" << i << ") with name \"" << wks.name() << "\" has comments" << std::endl;
XLComments wksComments = wks.comments();
Expand Down Expand Up @@ -114,7 +114,7 @@ int main()
// date/time data. See https://en.cppreference.com/w/cpp/chrono/c/tm for more information.

// An XLDateTime object can be created from a std::tm object:
std::tm tm;
std::tm tm = {}; // Initialize all members to zero
tm.tm_year = 121;
tm.tm_mon = 8;
tm.tm_mday = 1;
Expand Down
Loading