vb.net怎么打包

firstxiaoli 2008-08-26 02:46:11
初学vb.net,自己写了个程序,想让别人给测试一下,但是别的机器上没装vb.net,所以想打包传过去,写程序打包是必须的,所以请各位高手帮忙解决一下,说详细点,鄙人vb.net很烂
...全文
139 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
xgchou 2008-08-28
  • 打赏
  • 举报
回复
找到发布菜单吧,很简单的。。。。
htpower 2008-08-27
  • 打赏
  • 举报
回复
那就拿个袋子来装吧~说得够清楚的了
firstxiaoli 2008-08-27
  • 打赏
  • 举报
回复
都看不懂,我写的程序没有用到数据库,也没有报表,应该怎么处理
铭鑫0813 2008-08-26
  • 打赏
  • 举报
回复
前提,你装了winrar,可以用下面的函数

Public Function zipFile(ByVal zipName As String, ByVal fileName As String, Optional ByVal containPath As Boolean = False) As Boolean
If (Not IO.File.Exists(fileName)) Then
MsgBox(fileName & " Don't Exist!!!")
Return False
End If

Try
Dim tmpCmd As String = getCmd()
Dim tmpInfo As String

If Not containPath Then
tmpInfo = " a -ep " & zipName & " " & fileName
Else
tmpInfo = " a " & zipName & " " & fileName
End If

the_StartInfo = New ProcessStartInfo
the_StartInfo.FileName = tmpCmd
the_StartInfo.Arguments = tmpInfo
the_StartInfo.WindowStyle = ProcessWindowStyle.Hidden

the_Process = New Process
the_Process.StartInfo = the_StartInfo
the_Process.Start()

Dim processCode As Integer

While Not the_Process.HasExited
'do nothing
End While

processCode = the_Process.ExitCode
the_Process.Close()

If processCode = 0 Then
Return True
Else
Return False
End If
Catch ex As Exception
MsgBox(ex.Message)
Return False
End Try
End Function

Public Function getCmd() As String
Dim tmpObj As Object
Dim tmpString As String
Dim tmpRegister As RegistryKey

tmpRegister = Registry.ClassesRoot.OpenSubKey("Applications\WinRar.exe\Shell\Open\Command")
tmpObj = tmpRegister.GetValue("")
tmpString = tmpObj.ToString

tmpString = tmpString.Substring(1, tmpString.Length - 7)

tmpRegister.Close()

Return tmpString
End Function
downmoon 2008-08-26
  • 打赏
  • 举报
回复
http://www.microsoft.com/china/technet/itsolutions/net/deploy/netdgv2.mspx
ejoe313 2008-08-26
  • 打赏
  • 举报
回复
你看看这个网页:

VS2005项目的安装与布署

http://zehaobest.blog.sohu.com/76575786.html

16,555

社区成员

发帖
与我相关
我的任务
社区描述
VB技术相关讨论,主要为经典vb,即VB6.0
社区管理员
  • VB.NET
  • 水哥阿乐
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧