随笔分类 -  编程

摘要:function mainMenu { $mainMenu = 'X' while($mainMenu -ne ''){ Clear-Host Write-Host "`n`t`t My Script`n" Write-Host -ForegroundColor Cyan "Main Menu" W 阅读全文
posted @ 2025-08-06 15:38 tec2019 阅读(14) 评论(0) 推荐(0)
摘要:$Url = "https://www.bing.com" $IE = New-Object -com internetexplorer.application; $IE.visible = $true; $IE.navigate($url) 阅读全文
posted @ 2025-08-06 15:16 tec2019 阅读(64) 评论(0) 推荐(0)
该文被密码保护。
posted @ 2025-07-30 11:09 tec2019 阅读(0) 评论(0) 推荐(0)
摘要:Step 1 官网下载sqlite3.dll与宏文件放到同一个目录。 Step 2 新建一个xlsm的宏文件,通过API的方式调用dll 文件。 ' 需要先声明API函数 Private Declare Function sqlite3_open Lib "sqlite3.dll" (ByVal f 阅读全文
posted @ 2025-04-08 13:34 tec2019 阅读(356) 评论(0) 推荐(0)
摘要:Option Explicit Private Declare Sub MoveMemory Lib "kernel32" Alias "RtlMoveMemory" _ (Destination As Long, Source As Long, ByVal Length As Long) Priv 阅读全文
posted @ 2024-10-24 11:00 tec2019 阅读(103) 评论(0) 推荐(0)
摘要:Declare PtrSafe Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" _ (ByVal hwnd As Long, ByVal lpszOp As String, _ ByVal lpszFile As Strin 阅读全文
posted @ 2024-10-23 09:29 tec2019 阅读(162) 评论(0) 推荐(0)
摘要:Sub createFolder() Dim wks As Worksheet On Error Resume Next Set wks = ThisWorkbook.Worksheets(1) basepath = ThisWorkbook.Path & "\" Max = wks.Range(" 阅读全文
posted @ 2024-10-23 09:12 tec2019 阅读(40) 评论(0) 推荐(0)
摘要:app.py @app.route('/register', methods=['GET', 'POST']) def register(): if request.method == 'POST': username = request.form['username'] password = re 阅读全文
posted @ 2024-10-18 10:44 tec2019 阅读(46) 评论(0) 推荐(0)
摘要:page.html <!--这个是分页展示下面的页码--> {%macro my_paginate(pagination,url)%} <nav> <ul class="pagination"> {%if pagination.has_prev%} <li class="page-item acti 阅读全文
posted @ 2024-10-10 16:20 tec2019 阅读(51) 评论(0) 推荐(0)
摘要:database.py from flask_sqlalchemy import SQLAlchemy db = SQLAlchemy() config.py import os from database import db from flask import Flask basedir=os.p 阅读全文
posted @ 2024-10-09 13:06 tec2019 阅读(101) 评论(0) 推荐(0)
摘要:uname = "$env:USERPROFILE" $uname=$uname.Substring($uname.length -8) $checkpath = test-path \\xx.xx.xxx.xxx\xx\xx\*.lnk if($checkpath -eq "True"){ cop 阅读全文
posted @ 2024-02-23 14:13 tec2019 阅读(45) 评论(0) 推荐(0)
摘要:Option Explicit Private Declare Function GetSystemDefaultLCID Lib "kernel32" () As Long Private Sub Form_Load() Dim LocaleID As Long LocaleID = GetSys 阅读全文
posted @ 2023-08-09 10:40 tec2019 阅读(126) 评论(0) 推荐(0)
摘要:窗体 ' '->Forms ' Module ' ClassModules ' Option Explicit Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As Str 阅读全文
posted @ 2023-08-01 13:27 tec2019 阅读(1678) 评论(1) 推荐(0)
摘要:模版表名Template sheet25 数据列表名sheet1 打印程序 Sub PrintLabel() With ThisWorkbook.Sheets("Sheet1") limitmax = .Range("B10000").End(xlUp).Row For i = 2 To limit 阅读全文
posted @ 2023-02-06 16:12 tec2019 阅读(95) 评论(0) 推荐(0)
摘要:import pandas as pd import pyodbc import time # 文件路径及文件名 mdb_file = r"X:\xxx.accdb" driver = '{Microsoft Access Driver (*.mdb, *.accdb)}' cnxn = pyodb 阅读全文
posted @ 2022-11-01 11:11 tec2019 阅读(224) 评论(0) 推荐(0)
摘要:Server: import socket # 创建socket tcp_server_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM) # 本地信息 address = ('服务器ip', 3000) # 绑定 tcp_serve 阅读全文
posted @ 2022-09-23 15:15 tec2019 阅读(291) 评论(0) 推荐(0)
摘要:Sub GetSheetName() Dim Path As String Dim File As String Dim WB As Workbook Dim sht As Worksheet Dim arr() As String Dim narr() As String Application. 阅读全文
posted @ 2022-06-28 14:02 tec2019 阅读(295) 评论(0) 推荐(0)
摘要:Sub GetSheetName() Dim Path As String Dim File As String Dim WB As Workbook Dim sht As Worksheet Application.ScreenUpdating = False Path = ThisWorkboo 阅读全文
posted @ 2022-06-28 08:45 tec2019 阅读(1076) 评论(0) 推荐(0)
摘要:Sub compact_code() On Error Resume Next Dim Element As Object For Each Element In ActiveWorkbook.VBProject.VBComponents ActiveWorkbook.VBProject.VBCom 阅读全文
posted @ 2022-06-14 08:43 tec2019 阅读(617) 评论(0) 推荐(0)
摘要:用vim新建一个python文件后,如pw.py,会自动填写文件头部,如: # !/usr/bin/env python # -*- coding: utf-8 -*- # Pw @ 2013-04-15 17:26:33 将以下代码加入/etc/vim/vimrc文件: function Head 阅读全文
posted @ 2022-03-14 19:23 tec2019 阅读(142) 评论(0) 推荐(0)