公告版位

沒有痛苦 就沒有收穫
若內容對你有幫助,可以留言讓我知道哦~
有問題想要諮詢可以請至這裡連絡我哦 =>不會就放這邊

 


Q:sbin底下沒有ldconfig 這東西哪裡來的?

A:找你編譯環境下的sbin底下就有ldconfig 

找半天 = =都只有說ldconfig怎麼用卻沒有寫怎麼來的

JL8051 發表在 痞客邦 留言(0) 人氣()

安装下列程序: catchsegv, gencat, getconf, getent, glibcbug, iconv, iconvconfig, ldconfig, ldd, lddlibc4, locale, localedef, mtrace, nscd, nscd_nischeck, pcprofiledump, pt_chown, rpcgen, rpcinfo, sln, sprof, tzselect, xtrace, zdump 和 zic

安装下列库文件: ld. so, libBrokenLocale.[a,so], libSegFault. so, libanl.[a,so], libbsd-compat.a, libc.[a,so], libc_nonshared.a, libcrypt.[a,so], libdl.[a,so], libg.a, libieee.a, libm.[a,so], libmcheck.a, libmemusage. so, libnsl.a, libnss_compat. so, libnss_dns. so, libnss_files. so, libnss_hesiod. so, libnss_nis. so, libnss_nisplus. so, libpcprofile. so, libpthread.[a,so], libresolv.[a,so], librpcsvc.a, librt.[a,so], libthread_db. so 和 libutil.[a,so]


JL8051 發表在 痞客邦 留言(0) 人氣()

1. 修改 /etc/ssh/sshd_config
# vim /etc/ssh/sshd_config

PermitRootLogin without-password 前面加上 # 註解

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

Ubuntu / Linux 上,複製檔案是用 cp , 搬移檔案則是用 mv ,

cp 這個指令可以用 -r 或大是 -R 參數來指示說要複製子資料夾,其實,這個 r 的意思是 recursive ( 遞迴),

就是等於是告訴 cp 要整個資料夾都去繞一圈的意思,

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

為了安全的理由,有很多狀況下都要重新生sshdkey,像是docker內包的ssh就是一種

先刪掉舊的
sudo rm -rf /etc/ssh/ssh_host_*

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

C# code

private void button1_Click(object sender, EventArgs e)
{
    MailMessage mail = new MailMessage();
    NetworkCredential cred = new NetworkCredential("xxx@gmail.com", "password");
    //收件者
    mail.To.Add("ggyy@hotmail.com,ooxx@hotmail.com");
    mail.Subject = "subject";
    //寄件者
    mail.From = new System.Net.Mail.MailAddress("xxx@gmail.com");
    mail.IsBodyHtml = true;
    mail.Body = "message";
    //設定SMTP
    SmtpClient smtp = new SmtpClient("smtp.gmail.com");
    smtp.UseDefaultCredentials = false;
    smtp.EnableSsl = true;
    smtp.Credentials = cred;
    smtp.Port = 587;
    //送出Mail
    smtp.Send(mail);
}

VB code

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

zedGraphControl 畫面重新整理

zedGraphControl1.RestoreScale(myPane); //畫面重整

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

一般而言like搭配萬用字元的使用方式 select * from DataTable where ColumnName like '%ConditionName'

不過access的用法則是..

select * from DataTable where ColumnName like '*ConditionName'
文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

VB外掛ZedGraphControl

Dim countchartx As Integer '定義在最前面
DataGridView1.DataSource = set1.Tables("1a")  ' 要先把資料庫資料放入資料表!!!


'在程式中

Dim month(DataGridView1.Rows.Count - 1) As String  '定義一個資料表筆數的矩陣
For Me.countchartx = 1 To DataGridView1.Rows.Count - 1
        month(Me.countchartx - 1) = Format(CDate(DataGridView1.Rows(Me.countchartx - 1).Cells(1).Value), "hh:mm:ss")  '把所有資料表的時間存入矩陣中
Next

ZedGraphControl1.GraphPane.XAxis.Type = AxisType.Text
ZedGraphControl1.GraphPane.XAxis.Scale.TextLabels = month  '然後就會放在X軸囉

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

轉換時間格式或者想轉換成想要的格式可以使用format

Format(CDate(now), "hh:mm:ss")

參考https://docs.microsoft.com/zh-tw/office/vba/language/reference/user-interface-help/format-function-visual-basic-for-applications

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

語法 : 有三種形式的路徑顯示方法如下

Console.WriteLine(System.Reflection.Assembly.GetExecutingAssembly().Location)
'C:\My Application\ClassLibrary1.dll

Console.WriteLine(System.Reflection.Assembly.GetExecutingAssembly().CodeBase)
'file:///C:/My Application/ClassLibrary1.DLL

Console.WriteLine(System.Reflection.Assembly.GetExecutingAssembly().EscapedCodeBase)
'file:///C:/My%20Application/ClassLibrary1.DLL

寫法

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

資料庫讀進來後,在DataGridView1做完排序,之後畫出曲線的用法(抓某行某列值也有)

'資料庫讀進來後,在DataGridView1做排序
DataGridView1.Sort(DataGridView1.Columns(0),System.ComponentModel.ListSortDirection.Ascending)

'之後for迴圈用這個修正

  list1.Clear()  '清掉上次資料

  For Me.kgg = 0 To DataGridView1.Rows.Count - 1

                list1.Add(Me.kgg, DataGridView1.Rows(Me.kgg).Cells(5).Value)
   Next

EX   DataGridView1.Rows(0).Cells(5).Value     第5行  第1列的位置

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

清除LIST1

Dim list1 = New PointPairList() '定義

list1.clear()



Dim myCurve5 As LineItem = myPane5.AddCurve("GapPV1", list5, Color.Blue, SymbolType.None) '不要有點


文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

使用 PerformClick 方法 button1.PerformClick();  //C# button1.PerformClick()  'VB


文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

調整Word項目符號或編號與文字間的間格距離

[Word] 調整Word項目符號或編號與文字間的間格距離

調整項目符號或編號與文字間的間距 編號後面的空白設定
在未妥善對齊的其中一個清單項目前按一下滑鼠。按滑鼠右鍵,然後按一下 [調整清單縮排]。

JL8051 發表在 痞客邦 留言(4) 人氣()

// === 對 Access 資料庫下SQL語法 ===

// Transact-SQL 陳述式
String strSQL = "INSERT INTO 資料表1 (A) VALUES('" + A4.Text + "')";

JL8051 發表在 痞客邦 留言(0) 人氣()

資料庫SQL增新語法 C#

String strSQL = "INSERT INTO sec_user (A,password,user_name) VALUES('" + A4.Text + "','" + password.Text + "','" + user_name.Text + "')"; 

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

VB code

    Private Sub DataGridView1_CellMouseClick(ByVal sender As System.Object, ByVal e As System.Windows.Forms.DataGridViewCellMouseEventArgs) Handles DataGridView1.CellMouseClick
        Me.Text = click_count
        click_count = click_count + 1

        Try
            If click_count = 1 Then
                ' dd1.Text = DataGridView1.CurrentCell.Value.ToString
                dd1.Text = DataGridView1.CurrentRow.Cells(1).Value.ToString
            End If

            If click_count = 2 Then
                'dd2.Text = DataGridView1.CurrentCell.Value.ToString
                dd2.Text = DataGridView1.CurrentRow.Cells(1).Value.ToString
                click_count = 0
            End If

        Catch ex As Exception
            MessageBox.Show("GGGGGGGGGGG")
        End Try

    End Sub
文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

 DataGridView顯示最新的行數

DataGridView1.FirstDisplayedScrollingRowIndex = DataGridView1.Rows.Count - 1

文章標籤

JL8051 發表在 痞客邦 留言(0) 人氣()

[VB教學]用圖片當Button且不要外框

 
 
有時候我們需要用圖片代替難看的預設Button,只要在Button屬性視窗中BackgroundImage匯入你要的圖片.就可以在Button中顯示圖片.

JL8051 發表在 痞客邦 留言(0) 人氣()