|
How do I create an install program. My program is written in 2003.net and want to run it on a machine that does not have VB loaded on it.
Any ideas? In VB6 I could create an install program? How do I do that in 2003
|
|
|
|
|
You only need to install .NetFrameworkRuntime (dotnextfx) file on the destination machine. You may use a third party installer, This is the case I always do, I don't know much about Setup projects.
|
|
|
|
|
|
how can i add a string to calendar at a day specific
exmple:
add( calender ,date,string )
thanks
dadax
|
|
|
|
|
i need some sample .net projects.
plzzzzzz tell me some good websites.
|
|
|
|
|
|
|
I want to build my own web downloader and I have done that but i dont know how can i gives the resume suport in that project. Plz Help Me
|
|
|
|
|
Have hit a bit of a brick wall regarding embedding an application inside a web form, i.e. have a page with text and then say the calculator down the right hand side. Is this even possible to do? Essentially I'd like to be able to do this what was explained in http://www.codeproject.com/vb/net/ByPassAutomation.asp", but in a web form rather than a windows form.
Any suggestions?
Many Thanks,
Ken.
-- modified at 15:01 Tuesday 23rd May, 2006
|
|
|
|
|
Hello.
I´m a VB programing and I´m from Brazil.
I need some help with DBF database. I already created a DBF code in VB, but I don´t know how to set size of a field(columns).
For example: When I created a DBF, it came with fields with width 20 and type adNumeric, but I want it with width the size equal 5 and type adNumeric.
How can I do it in VB6?
below it´s my code to generate a DBF
Function fCriaDBF(sPATH As String, sNome As String, vCampos As Variant) As Boolean
Dim cat As New ADOX.Catalog
Dim tbl As New ADOX.Table
Dim i As Integer
Set cat = New ADOX.Catalog
cat.ActiveConnection = "Provider=Microsoft.JET.OLEDB.4.0;Data Source=c:\tmp;Extended Properties=Dbase 5.0;"
Set tbl = New ADOX.Table
With tbl
.Name = sNome
Set .ParentCatalog = cat
With .Columns
For i = 0 To UBound(vCampos)
.Append vCampos(i), adNumeric, CLng(5)
.Item(vCampos(i)).NumericScale = 0
.Item(vCampos(i)).DefinedSize = CByte(5)
.Item(vCampos(i)).Precision = CLng(5)
Next
End With
End With
cat.Tables.Append tbl
Set cat = Nothing
end function
Anyone Help me!
Tanks
-- modified at 7:00 Wednesday 24th May, 2006
|
|
|
|
|
Hi,
Plz tell me how can i, firstly, add the data from the datagrid to the dataset. Secondly, how can i update the data from the datagrid to the dataset. i.e. all the settings or updations must be saved to the dataset.
Thanks.
Plz anybody answer to my question.
|
|
|
|
|
If you bind the datagrid to the dataset, and make sure that the ReadOnly property of the datagrid is set to false, the dataset is updatable by the datagrid. Then you should write
DataAdapter1.Update(DataSet1)
DataSet1.AcceptChanges()
to have the changes take effect in the database....
|
|
|
|
|
|
Can someone tell me what is wrong with this code? The error I'm getting is: "Error #380 was generated by ListItems. Invalid Property value."
I’m trying to place a database table’s information on a listview control. Where the column names are the table’s field names.
Here is the code:
Private Sub List_Fields_In_Table(cnnDB As ADODB.Connection, strTable As String)
On Error GoTo List_Fields_In_Table_Err
Dim itmX As ListItem
Dim clmX As ColumnHeader
Dim Idx As Integer
Dim fld As ADODB.Field
lvTblCols.ListItems.Clear
Set rstSchema = New ADODB.Recordset
strSQL = "SELECT " & strTable & ".* FROM " & strTable & ";"
'Retrieve table field schema
rstSchema.Open strTable, cnnDB, , , adCmdTable
lvTblCols.ColumnHeaders.Clear
lvTblCols.ListItems.Clear
lvTblCols.View = lvwReport
lvTblCols.BorderStyle = ccFixedSingle
Idx = 1
For Each fld In rstSchema.Fields
'Place the Field name on the column, with an index to the column.
'Name the column with the fld.name
Set clmX = lvTblCols.ColumnHeaders.Add(Idx, fld.Name, fld.Name)
'Place the value in the field under the its field name
Set itmX = lvTblCols.ListItems.Add(Idx, fld.Name, fld.Value)
'I get the error here.
itmX.SubItems(lvTblCols.ColumnHeaders(fld.Name).SubItemIndex) = fld.Value
Idx = Idx + 1
Next fld
List_Fields_In_Table_Exit:
On Error Resume Next
rstSchema.Close
Set rstSchema = Nothing
Exit Sub
List_Fields_In_Table_Err:
Msg = "Error in frmPictures - List_Fields_In_Table subroutine. " & vbCr & _
"Error # " & Str(Err.Number) & " was generated by " _
& Err.Source & vbCr & Err.Description
MsgBox Msg, , "Error", Err.HelpFile, Err.HelpContext
Resume List_Fields_In_Table_Exit
End Sub
This is just a variable version of:
Make sure ListView control is in report view.
ListView1.View = lvwReport
' Add three columns.
ListView1.ColumnHeaders.Add , "Name", "Name"
ListView1.ColumnHeaders.Add , "Address", "Address"
ListView1.ColumnHeaders.Add , "Phone", "Phone"
' Add ListItem objects to the control.
Dim itmX As ListItem
' Add names to column 1.
Set itmX= ListView1.ListItems.Add(1, "Mary", "Mary")
' Use the SubItemIndex to associate the SubItem with the correct
' ColumnHeader. Use the key ("Address") to specify the right
' ColumnHeader.
itmX.SubItems(ListView1.ColumnHeaders("Address").SubItemIndex) _
= "212 Grunge Street"
' Use the ColumnHeader key to associate the SubItems string
' with the correct ColumnHeader.
itmX.SubItems(ListView1.ColumnHeaders("Phone").SubItemIndex) _
= "555-1212"
Set itmX = ListView1.ListItems.Add(2, "Bill", "Bill")
itmX.SubItems(ListView1.ColumnHeaders("Address").SubItemIndex) _
= "101 Pacific Way"
itmX.SubItems(ListView1.ColumnHeaders("Phone").SubItemIndex) _
= "555-7879"
Set itmX= ListView1.ListItems.Add(3, "Susan", "Susan")
itmX.SubItems(ListView1.ColumnHeaders("Address").SubItemIndex) = _
"800 Chicago Street"
itmX.SubItems(ListView1.ColumnHeaders("Phone").SubItemIndex) = _
"555-4537"
Set itmX= ListView1.ListItems.Add(4, "Tom", "Tom")
itmX.SubItems(ListView1.ColumnHeaders("Address").SubItemIndex) _
= "200 Ocean City"
itmX.SubItems(ListView1.ColumnHeaders("Phone").SubItemIndex) = _
"555-0348"
Please help,
Quecumber256
|
|
|
|
|
I am writing a web browser that will only show one page, im trying to lock down as many functions as possible. right now i have it so i have to hit go to bring me to the page, but i want to get rid of that and have the page open when the program does.
Also i wanted it to auto fill out a name and password feild for me. If any one can help id appreciate it thanks. Here is my code so far...
Public Class form1
Inherits System.Windows.Forms.Form
#Region " Windows Form Designer generated code "
Public Sub New()
MyBase.New()
'This call is required by the Windows Form Designer.
InitializeComponent()
'Add any initialization after the InitializeComponent() call
End Sub
'Form overrides dispose to clean up the component list.
Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
If disposing Then
If Not (components Is Nothing) Then
components.Dispose()
End If
End If
MyBase.Dispose(disposing)
End Sub
'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer
'NOTE: The following procedure is required by the Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
Friend WithEvents AxWebBrowser1 As AxSHDocVw.AxWebBrowser
Friend WithEvents txtUrl As System.Windows.Forms.TextBox
Friend WithEvents btnGo As System.Windows.Forms.Button
<system.diagnostics.debuggerstepthrough()> Private Sub InitializeComponent()
Dim resources As System.Resources.ResourceManager = New System.Resources.ResourceManager(GetType(form1))
Me.AxWebBrowser1 = New AxSHDocVw.AxWebBrowser
Me.txtUrl = New System.Windows.Forms.TextBox
Me.btnGo = New System.Windows.Forms.Button
CType(Me.AxWebBrowser1, System.ComponentModel.ISupportInitialize).BeginInit()
Me.SuspendLayout()
'
'AxWebBrowser1
'
Me.AxWebBrowser1.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
Or System.Windows.Forms.AnchorStyles.Left) _
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.AxWebBrowser1.Enabled = True
Me.AxWebBrowser1.Location = New System.Drawing.Point(0, 40)
Me.AxWebBrowser1.OcxState = CType(resources.GetObject("AxWebBrowser1.OcxState"), System.Windows.Forms.AxHost.State)
Me.AxWebBrowser1.Size = New System.Drawing.Size(1284, 961)
Me.AxWebBrowser1.TabIndex = 0
'
'txtUrl
'
Me.txtUrl.Location = New System.Drawing.Point(8, 8)
Me.txtUrl.Name = "txtUrl"
Me.txtUrl.Size = New System.Drawing.Size(336, 20)
Me.txtUrl.TabIndex = 1
Me.txtUrl.Text = "sage03/fsdatacollection/login.asp"
'
'btnGo
'
Me.btnGo.Location = New System.Drawing.Point(352, 8)
Me.btnGo.Name = "btnGo"
Me.btnGo.Size = New System.Drawing.Size(40, 24)
Me.btnGo.TabIndex = 2
Me.btnGo.Text = "Go"
'
'form1
'
Me.AcceptButton = Me.btnGo
Me.AutoScaleBaseSize = New System.Drawing.Size(5, 13)
Me.ClientSize = New System.Drawing.Size(1284, 1002)
Me.ControlBox = False
Me.Controls.Add(Me.btnGo)
Me.Controls.Add(Me.txtUrl)
Me.Controls.Add(Me.AxWebBrowser1)
Me.Cursor = System.Windows.Forms.Cursors.Arrow
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None
Me.MaximizeBox = False
Me.MinimizeBox = False
Me.Name = "form1"
Me.Text = "Sytline Log-In"
Me.WindowState = System.Windows.Forms.FormWindowState.Maximized
CType(Me.AxWebBrowser1, System.ComponentModel.ISupportInitialize).EndInit()
Me.ResumeLayout(False)
End Sub
#End Region
Private Sub btnGo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnGo.Click
AxWebBrowser1.Navigate(txtUrl.Text)
End Sub
Private Sub AxWebBrowser1_Enter(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles AxWebBrowser1.Enter
AxWebBrowser1.LocationURL("sage03 / fsdatacollection / login.aps")
End Sub
End Class
Timothy Groleau
TJGroleau@charter.net
|
|
|
|
|
|
?? ??
What does it mean?!!
|
|
|
|
|
Hi, I am programming in vb6 a program that deals with huge arrays which need to be saved/loaded. I used a simple for-next and Print# to print any item in the array to the file and Input# to load it.
But it is too slow... I need a better algorithm/method to do this if available...
could you please help me out?
|
|
|
|
|
I can't believe a 20min process now is done only .6sec!!!!!
Print #1, Join(a,",")
to save and split to load..
|
|
|
|
|
In C# I can do the following:
<br />
int nSize = 24;<br />
object[] pObjArray = new object[nSize];<br />
How do I do the same in VB.NET? Thanks.
|
|
|
|
|
Integer nSize = 24
Object() pObjArray = new Object() {nSize}
|
|
|
|
|
Wooster2006 wrote: Integer nSize = 24
Object() pObjArray = new Object() {nSize}
This is not correct.
This creates an array containing 1 element whose value is 24.
|
|
|
|
|
Dim nSize As Integer = 24<br />
Dim pObjArray(nSize) As Object<br />
<br />
'// And to test it:<br />
pObjArray(24) = "Test"<br />
MsgBox(CType(pObjArray(24), String))
There you go!
-- modified at 11:38 Tuesday 23rd May, 2006
|
|
|
|
|
j-on wrote: Dim nSize As Integer = 24
Dim pObjArray(nSize) As Object
Not quite right.
This array contains 25 elements. Not 24.
In VB.NET, the value that you use to set the array size does not represent the "Capacity" of the array like how it's done in C#. It represents the max "Index" of the array. And remember that arrays in VB.NET are zero based. So, if you count the elements from 0 to 24, you have a total of 25 elements. What you want to do is this instead.
Dim nSize As Integer = 24<br />
Dim pObjArray(nSize - 1) As Object
This is one of the major difference between C# and VB.NET's handling of arrays.
-- modified at 18:51 Tuesday 23rd May, 2006
|
|
|
|
|
Hello Blue Bird.
The first 2 responses that you received were not quite correct. Please look at my responses to them.
The following C# code...
int nSize = 24;
object[] pObjArray = new object[nSize];
Will look like this in VB.NET...
Dim nSize As Integer = 24
Dim pObjArray(nSize - 1) As Object
The big difference here is that the array initializer in VB.NET represents the largest index (ie: upper bound) and not the capacity of the array. That's why you should tack on a "-1" as shown above.
You can also generate an array like this via the "ReDim" statement.
Dim pObjArray() As Object ' Array not created yet.<br />
ReDim pObjArray(nSize - 1) ' This create a new array.<br />
ReDim pObjArray(1) ' This creates a new array having 2 elements.
You can also create an array and initialize it at the same time like this...
Dim pObjArray() As Object = {1, 2, 3}
Or like this...
Dim pObjArray() As Object<br />
pObjArray = New Object() {1, 2, 3}
I hope this helps!
|
|
|
|
|