Skip to content

Instantly share code, notes, and snippets.

View Zhouxing-Su's full-sized avatar
💭
I may be slow to respond.

Mr. Ree Zhouxing-Su

💭
I may be slow to respond.
View GitHub Profile
@Zhouxing-Su
Zhouxing-Su / Office.Excel.ConsolidateWorkbooks.bas
Created August 20, 2017 03:05
Consolidate all worksheets from multiple workbooks (.xlsx files) into single (current) workbook.
' http://www.excel-easy.com/vba/examples/import-sheets.html
' https://trumpexcel.com/combine-multiple-workbooks-one-excel-workbooks/
' https://stackoverflow.com/questions/579797/open-excel-file-for-reading-with-vba-without-display
Sub ConsolidateWorkbooks()
Application.ScreenUpdating = False
Call AppendWorkbook("D:\workspace\cpp\InventoryRoutingProblem\Deploy\Doc\7 Analysis\", "2.16.CorrelationBetweenObjAndCost.xlsx", "2.16")
Call AppendWorkbook("D:\workspace\cpp\InventoryRoutingProblem\Deploy\Doc\7 Analysis\", "2.18.CorrelationBetweenObjAndCost.xlsx", "2.18")
Call AppendWorkbook("D:\workspace\cpp\InventoryRoutingProblem\Deploy\Doc\7 Analysis\", "2.20.CorrelationBetweenObjAndCost.xlsx", "2.20")
Call AppendWorkbook("D:\workspace\cpp\InventoryRoutingProblem\Deploy\Doc\7 Analysis\", "2.26.CorrelationBetweenObjAndCost.xlsx", "2.26")
Application.ScreenUpdating = True
@Zhouxing-Su
Zhouxing-Su / Life.Tampermonkey.QueryElectricity.js
Last active August 7, 2017 12:36
华中科技大学学生宿舍电费查询
// ==UserScript==
// @name Hust.Dorm.QueryElectricity
// @namespace http://szx.studio/
// @version 0.1
// @description 华中科技大学学生宿舍电费查询
// @author szx
// @match http://202.114.18.218/Main.aspx
// @grant none
// ==/UserScript==
@Zhouxing-Su
Zhouxing-Su / Office.Visio.ExportAllPages.bas
Created May 16, 2017 12:16
Export all pages to high resolution .png images by importing this script into your .vsdx file and run it.
Attribute VB_Name = "ExportAllPages"
Sub ExportAllPagesToHighResolutionPng()
Application.Settings.SetRasterExportResolution visRasterUsePrinterResolution, 600#, 600#, visRasterPixelsPerInch
Application.Settings.SetRasterExportSize visRasterFitToSourceSize, 10.666667, 7.739583, visRasterInch
Application.Settings.RasterExportDataFormat = visRasterInterlace
Application.Settings.RasterExportColorFormat = visRaster24Bit
Application.Settings.RasterExportRotation = visRasterNoRotation
Application.Settings.RasterExportFlip = visRasterNoFlip
Application.Settings.RasterExportBackgroundColor = 16777215
@Zhouxing-Su
Zhouxing-Su / Lemon.MinCostFlow.NS.Sample.cpp
Last active December 31, 2022 16:57
Sample code of using Network Simplex in Lemon for Min Cost Flow problem.
#include <iostream>
#include <lemon/smart_graph.h>
#include <lemon/network_simplex.h>
using namespace lemon;
using namespace std;