求vb.net的源代码,最好说明其解决问题,越多越好,满意加50分。
下面这段代码,是我用来计算每个月存500元进银行,连续30年,最后连本带利能有多少钱。这里面涉及复利计算。界面中右边的文本框用来输出每一次计算的结果。
成都创新互联-专业网站定制、快速模板网站建设、高性价比锡山网站开发、企业建站全套包干低至880元,成熟完善的模板库,直接使用。一站式锡山网站制作公司更省心,省钱,快速模板网站建设找我们,业务覆盖锡山地区。费用合理售后完善,十年实体公司更值得信赖。
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim nianxian As Integer '年限变量
Dim dingcun As Integer '定存变量
Dim fuli_big As Long '大复利
Dim fuli_small As Long '小复利
Dim i As Integer '循环变量
Dim DATAstring As String '数据字符串
nianxian = Val(年限_TextBox.Text)
dingcun = Val(定存_TextBox.Text)
DATAstring = ""
For i = 1 To nianxian
fuli_small = dingcun * (1 + 0.1875)
dingcun = fuli_small
fuli_big = fuli_big + fuli_small
DATAstring = DATAstring + "[" + Trim(Str(i)) + "]" + Str(fuli_big) + Chr(13) + Chr(10)
'DATAstring = DATAstring + "[" + Trim(Str(i)) + "]" + Str(fuli_small) + Chr(13) + Chr(10)
Next
'fuli_big = fuli_small
TextBox1.Text = DATAstring
结果_TextBox.Text = Str(fuli_big) + "元"
End Sub
VB.NET获取需要登录后的源码
很简单的。这个最基本的了。
就是从数据库表中 找出一个记录,名称和密码都和你输入的一样的记录,就表示登陆成功。
简单的思路:(密码也没有加密等)
dim dt As New DataTable
dim cmd As New SqlCommand
With cmd
.CommandText = "Select * From Users Where UserName=@UserName and UserPwd=@UserPwd"
.Parameters.Add(New SqlClient.SqlParameter("@UserName", "=你输入的用户名TextBox1.Text"))
.Parameters.Add(New SqlClient.SqlParameter("@strColorNo", "=你输入的密码TextBox2.Text"))
End With
dt =SqlHelper.GetDatatable(cmd)
if dt.rows.count0 then
msgbox "ok"
else
msgbox "error"
end if
如何把vb.net的做的一个exe文件反编译得到源码
你都懂得反编译还编不了个小信息管理系统啊...vb6程序的话可以的 因为vb6本来就是伪代码,vb.net就不行了,.net framework至少能防止你把程序反编译成特定高级语言的。
请问为什么我公司的vb.net源码到了我的电脑上运行就会显示好多未声明啊?
用API 函数GetVolumeInformation得到的不是硬盘的序列号!!!
BOOL GetVolumeInformation(
LPCTSTR lpRootPathName,
LPTSTR lpVolumeNameBuffer,
DWORD nVolumeNameSize,
LPDWORD lpVolumeSerialNumber,
LPDWORD lpMaximumComponentLength,
LPDWORD lpFileSystemFlags,
LPTSTR lpFileSystemNameBuffer,
DWORD nFileSystemNameSize
);
看看英文啊:VolumeSerialNumber!得到的只是卷区序列号!
硬盘的序列号应该是
Drive Model Number________________: WDC WD400EB-00CPF0
Drive Serial Number_______________: WD-WCAATF083586
Drive Controller Revision Number__: 06.04G06
Controller Buffer Size on Drive___: 2097152 bytes
Drive Type________________________: Fixed
Drive Size________________________: 40020664320 bytes
中:
Drive Serial Number_______________: WD-WCAATF083586 这才是硬盘Serial Number!!!!
这个号是不会因为你格式化硬盘而改动,也不是网上流传的修改工具能改的,(其实网上流传的修改工具的也不过是卷区号而已!)
建议用 DiskID.dll或DiskID32.dll来获取
用diskid.dll和disk32.dll获得硬盘序列号
1.调用diskid.dll实现:
Option Explicit
Private Declare Function IsWinNT Lib "DiskID.DLL" () As Long
Private Declare Function ReadPhysicalDrive9X Lib "DiskID.DLL" (driveID As Long, buffer As Long, bufLen As Long) As Long
Private Declare Function ReadPhysicalDriveInNT Lib "DiskID.DLL" (driveID As Long, buffer As Long, bufLen As Long) As Long
Private Type DRIVER_INFO_OK
ModalNumber(39) As Byte
SerialNumber(19) As Byte
ControlNum(7) As Byte
DriveType As Long
Cylinders As Long
Heads As Long
Sectors As Long
End Type
Private Sub Command1_Click()
Dim x As DRIVER_INFO_OK
Dim i As Long
If IsWinNT = 1 Then
i = ReadPhysicalDriveInNT(ByVal 0, ByVal VarPtr(x), ByVal 256)
Else
i = ReadPhysicalDrive9X(ByVal 0, ByVal VarPtr(x), ByVal 256)
End If
Dim s As String
s = StrConv(x.ModalNumber, vbUnicode)
s = Left(s, InStr(1, s, Chr(0)) - 1)
MsgBox "硬件厂商代码为:" + s
s = StrConv(x.SerialNumber, vbUnicode)
s = Left(s, InStr(1, s, Chr(0)) - 1)
MsgBox "硬盘序列号为:" + s
End Sub
2.调用diskid32.dll实现:
Option Explicit
Private Declare Function DiskID32 Lib "DiskID32.DLL" (ByRef DiskModel As Byte, ByRef DiskID As Byte) As Long
Private Sub Command1_Click()
Dim DiskModel(31) As Byte, DiskID(31) As Byte, i As Integer, Model As String, ID As String
If DiskID32(DiskModel(0), DiskID(0)) 1 Then
MsgBox "get diskid32 err"
Exit Sub
End If
For i = 0 To 31
If Chr(DiskModel(i)) Chr(0) Then
Model = Model Chr(DiskModel(i))
End If
If Chr(DiskID(i)) Chr(0) Then
ID = ID Chr(DiskID(i))
End If
Next
MsgBox "硬件产生代码为:" + Model
MsgBox "硬盘序列号为:" + ID
End Sub
说明:diskid.dll可从下载
diskid32.dll可从下载
求VB 财务软件源码或教程
这个是用友财务8.5的vb代码
左边武汉IDC可以下,我试过
加载后会报N多错,不过代码能看
VB程序源码如何使用
你需要安装vb6.0开发软件
如果安装了,就可以直接打开源码测试了,后缀名是vbp,(就是vb的工程文件)
如果没有安装vb6.0,还想打开源码看程序,那就右击 用记事本 打开后缀名为frm的文件,他是vb的窗口文件,源码都在他里面
一般得源码是没有生成exe可执行文件的,那样文件太多,太大,浪费空间
如果你自己想生成exe可执行文件,那就vb6.0得文件菜单中把文件保存成exe可执行文件就可以了,非常简单
好运!
网站标题:vb.net财务软件源码 vb软件代码
分享路径:http://cqwzjz.cn/article/hioejp.html