|
Hello evrybdy,
i've a question about vb.net 2005.
actually i was developing one project in vb.net 2003..but now i've vb.2005 ..so i am trying to convert my application in vb.net 2005. when i'm try to open my solution,it gives me error "{Project location is not trusted"...
actually i am trying to give the full trust to assembly..but at that time it gives me the same error adn quits..
this is on my network drive.
so i moved my project to my local(c:\) drive. now its worjking fine..
but my user /server is on my network drive...so i've to run exe from my network drive..
if anybody knows abt some thing ..let me know
my e-mail add is hemakshi74@hotmail.com
hemaxi
|
|
|
|
|
I am trying to create a Windows Form to update a simple database, but cannot get the code right for the update process. I felt like I had it down in class, but ... not!
The SQL 2000 database has 21 fields (datetime, nvarchar, int) data types. I created 2 forms, one with textboxs for each field and the other with a data grid. I cannot seem to get either one to work. As some of the fields are lengthy, the form with individual textboxs would be the preferred way. Any help would be greatly appreciated! I have the load function working to see all of the records. I also 3 fields that use a listbox and I am able to select the different values.
Thank you,
LWhite
|
|
|
|
|
What do you want to do?
Maybe DATAFORM Wizard could help you.
ICQ:258-235-734
MSN:msnadair@hotmail.com
|
|
|
|
|
I do use the wizard, but since the wizard defaults to OleDb vs SQL, my problem occurs changing the connection over to SQL.
LWhite
|
|
|
|
|
Hi i am new in this frum
i am trying to find a way to search through listview by typing in textbox
so by typing each charecter program has to find first a first item in listview that starts with that charecter and sort it by that charecter
any idea would be a great help for me
|
|
|
|
|
I have an image button on my form. But the problem is the button is round, but the button is square. So I want a round button on an imagebutton, where the white around the sides doens't show up. Much like if you make it non-opaque in a graphics package, i.e. it just disregards any white as being not there.
Can anyone help?
|
|
|
|
|
Hi All,
I was given a task at my job where I have to implement the click events of a "Next" button and a "Previous" button, for example. However, in the code, I see that another event is raised in the click event. Below is the example for the "previous" button in vb.net. My question is why not just use a normal method? As shown below, why call a NextClick() event in the click() event?
Private Sub btnNext_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnNext.Click
RaiseEvent NextClick()
End Sub
|
|
|
|
|
No reason - the code for the NextClick method should really just be in the click handler, unless it's a method that gets called in more than one place. Even then, just calling the method should be all that's needed.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
I want to retrieve schema information about a specific table. What I would like to know is;
The field that is the primary key.
The field(s) that are foreign key(s).
And list the data types for these fields.
Visual Basic 6.0 help has a nice routine to retrieve schema information, but you must loop through an entire recordset. I want to just send field names and retrieve their data types so I can mark the primary key field from the foreign key field.
Here is the VB6 routine:
Public Function Primary_Key(cnnDB As ADODB.Connection, strTbl As String) As Boolean
On Error GoTo Primary_Key_Err
Set rstPriKey = cnnDB.OpenSchema(adSchemaConstraintColumnUsage)
Do Until rstPriKey.EOF
With rstPriKey
If (UCase(!TABLE_NAME) = UCase(strTbl)) And (UCase(!CONSTRAINT_NAME) = "PRIMARYKEY") Then
Primary_Key = True
GoTo Primary_Key_Exit
Else
Primary_Key = False
End If
.MoveNext
End With
Loop
Primary_Key_Exit:
On Error Resume Next
rstPriKey.Close
Set rstPriKey = Nothing
Exit Function
Primary_Key_Err:
Msg = "Error in Startup module - Primary_Key function. " & vbCr & _
"Error # " & Hex(Str(Err.Number)) & " was generated by " _
& Err.Source & vbCr & Err.Description
MsgBox Msg, , "Error", Err.HelpFile, Err.HelpContext
Resume Primary_Key_Exit
End Function
Any help would be appreciated.
Thank you,
Quecumber256
|
|
|
|
|
I have the windows media player in my form already but can't get it to play a specific movie file located on my hard disk. I don't know which command to use to tell my program to play the file. Could someone please explain to me how I can tell my program to (load and play) a small movie clip in my form?
Any help would be greatly appreciated!
-- modified at 16:48 Tuesday 16th May, 2006
|
|
|
|
|
Place Common Dialog Control,command button on form & put following code in command button's click event which is used to load movie file.
code:
CommonDialog1.ShowOpen
MediaPlayer1.FileName = CommonDialog1.FileName
If you want to open movie file directly,without using Common Dialog Control
then put this code in command button's click event which is used to load movie file.
code:
MediaPlayer1.FileName = "Path of movie file located on your hard disk"
e.g.MediaPlayer1.FileName = "D:\Movie.dat"
You have to add Common Dialog Control from Add Components.
Sachin
Think of your goal when you are confused.
|
|
|
|
|
<b>how to send mail in vb.net</b>
|
|
|
|
|
Look into system.net.mail namespace and smtpclient.send() method
Bhaskara
|
|
|
|
|
I am trying to use System.IO.Compression to compress/decompress the buffer. I have the data in byte format in sql server and I need to create an CLR user defined function. I have everything running except that for some of the files, the compressed size is larger than the actual file size. I tried to use both Deflate and GZip compression types. Did anyone face the similar situation. Thanks in advance for your help.
Thanks
Bhaskara
|
|
|
|
|
If you try to compress a file that is already compressed (like zip, jpg, mp3, mpeg, wmv, etc.) you may end up with a file that is larger than the original, as the file can't be compressed further and the compression adds metadata.
-- modified at 18:27 Tuesday 16th May, 2006
Note: GZip uses the same algorithm as Deflate, so you won't see any noteable differences in file size between them.
---
b { font-weight: normal; }
|
|
|
|
|
is it possible to utilize features from micorsoft word in a vb.net application? For example, connecting to the word thesarus in vb.net?
|
|
|
|
|
Folks;
I have looked at the article By David Broooks, "Dynamically adding ActiveX controls in managed code", but I am still uncertain about how I can replace the VB6 'VBcontrolExtender' functional under VB.NET in order to add OCXes to my application at run time.
I have a few years of code in the OCXes that I am trying to host this way. Each OCX represents an interface to data aqcquisition hardware, and in my current VB6 application, is dynamicallty loaded depending on which piece of hardware the user wishes to connect to.
Without going into too much detail, compiling the application with all of the OCXes in it would force me to distribute an awful lot of code - which is why I was using the VBcontrolExtender under VB6 in the first place.
Following the code example by David Broooks, I can add an OCX to a form at run time, but I do not know how to get 'ObjectEvent' messages from the OCX's that I have added to the form.
I have looked high & low for a solution to this, but I am not yet expert enough in VB.NET to figure this out.
A friend of Liberty is a friend of mine!
www.lp.org
|
|
|
|
|
OK I've scoured the WEB for this but can't find a working solution.
I'm trying to create a "fade" effect for a user control without any luck.
Basically I'm trying to get the control to gradually "appear" on a form as part of it's methods, i.e. add the control to a from and then "fade" it in.
As an example, assume I have a user control containing various other controls (text boxes, labels, listviews, etc.). The control should then fade all of these in.
NOte - I can't use a Form and then change the opacity, it has to be a user control, but that's basically the equivalent effect...
Any ideas?
Thanks.
???
Carp
|
|
|
|
|
i am printing information on a form and i send all the items individually to the printer, however i have a textbox that contains a large body of text, and when i print it just goes in one straight line, how do i break it down so it shows all the text
thanx
|
|
|
|
|
|
|
Hii,
I need to set minimumpasswordlength for my system Using Visual Basic .
For this Iam Using IADsDomain interface.
My code is as follows....
Private Declare Function GetComputerName Lib "Kernel32.dll" Alias "GetComputerNameA" (ByVal strString As String, strSize As Long) As Long
Private Sub Command1_Click()
On Error GoTo ErrorHandler
Dim dom As IADsDomain
Dim cls As IADsClass
Dim v
Dim x As Variant
Dim str As String
Set dom = GetObject("WinNT://" & ComputerName & " ")
Iam getting an exception in the above line
Set cls = GetObject(dom.Schema)
For Each x In cls.OptionalProperties
v = dom.ADsPath
If x = "MinPasswordLength" Then
dom.MinPasswordLength = 10
End If
Next
ErrorHandler:
MsgBox Err.Description
End Sub
Function ComputerName() As String
Dim buffer As String * 512, length As Long
length = Len(buffer)
'GetComputerName returns zero on failure
If GetComputerName(buffer, length) Then
ComputerName = Left$(buffer, length)
End If
End Function
'My computer is connected in domain. if I specify the domain name instead of ComputerName in
Set dom = GetObject("WinNT://" & mydomain & " ")
,i could execute the code successfuly.But i need to execute the code on a system which is connected to work group.
Can anyone please provide me the relevant information??
Thanx
|
|
|
|
|
narayanagvs wrote: Can anyone please provide me the relevant information??
Yes, if you do.
What exception do you get?
---
b { font-weight: normal; }
|
|
|
|
|
I have an xslt file main.xsl whose output is XML & uses Main.xml .I use document function in my main.xsl to get data from Submain.xml(Document('Submain.xml')) file and transform some information from submain.xsl.my above main.Xsl transforms perfectly on xmlspy or stylusstudio but when i try to transform using vb.net submain.xml is never read & so i don't see any relevant information from Submain.xml.
can somebody help me
i will paste the vb.net code below
xmldoc.Load("Main.xml")
xsltTransformer.Load("main.xsl")
writerHtmlOutput = New System.IO.StringWriter
xsltTransformer.Transform(xmldoc, Nothing, writerHtmlOutput, Nothing)
Stream = New StringReader(writerHtmlOutput.ToString())
Vijayendra
|
|
|
|
|
.net 2.0 seems to be a little different when saving data back to a database. In the form designer I created a datasource and dragged fields to the textboxes on the form. VB created some objects including a dataadapter an inserted these objects in the form designer tray. When I click on the save button the following code runs but does not update the database. What do I need to do to updata the database? Thanks for anyhelp given!
Me.Validate()
Me.MyTableBindingSource.EndEdit()
Me.MyTableTableAdapter.Update(Me.MyDataSet.MyTable)
Me.MyDataSet.MyTable.AcceptChanges()
|
|
|
|