Skip to content

Instantly share code, notes, and snippets.

go('https://yp.vn');
private void btnDecode_Click(object sender, System.EventArgs e)
{
using (var openDlg = new OpenFileDialog())
{
openDlg.Multiselect = false;
if (openDlg.ShowDialog(this) == DialogResult.OK)
{
string fileName = openDlg.FileName;
if (!File.Exists(fileName))
{
private void btnEncode_Click(object sender, System.EventArgs e)
{
if (string.IsNullOrEmpty(tbxData.Text))
{
MessageBox.Show("Vui lòng nhập nội dung cần mã hóa",
"QR Code Generator");
return;
}
var barcodeWriter = new BarcodeWriter
//Open Website
go("http://vnexpress.net/");
sleep(5, false);
click("/html/body/div[3]/div[2]/div/ul/li[2]/a");
sleep(5, false);
for(i = 1; i <= 25; i++)
{
var text = extract("/html/body/div[4]/div[3]/div/div/div[3]/div/div/ul/li["+ i +"]/div/div/a", "text");
//Create File
go('http://www.yp.vn/business/vn/tabid/493/ctl/s/mid/1835/language/en-US/Default.aspx');
var wait = 15;
var tukhoa = 'AN TOÀN - HỆ THỐNG & THIẾT BỊ';
var thanhpho = 'Hà Nội';
var taptin = 'D:\\doanhnghiep.txt';
sleep(wait, false);
fill("Kwords", tukhoa);
@thangdc
thangdc / gist:1b92269aef40ec9f03dd
Created July 12, 2015 04:07
Custom Javascript with MDS Sharepoint 2013
asyncDeltaManager.add_endRequest(function() {
//Your code
});
@thangdc
thangdc / Generate-QR-Code-from-Excel
Created April 20, 2016 06:36
Generate QR Code from Excel
private void btnGenerateQRCodeFromExcel_Click(object sender, System.EventArgs e)
{
openFileDialog.InitialDirectory = Application.StartupPath + "\\Excels";
openFileDialog.Filter = "Excel files|*.xls;*.xlsx";
var fileDialog = openFileDialog.ShowDialog();
if (fileDialog == System.Windows.Forms.DialogResult.OK)
{
var filePath = openFileDialog.FileName;
var ext = Path.GetExtension(filePath);