Community Member
Member Avatar
Topic by Curious Gorge in Game Development

![turretangle.png](/attachments/large/3/0aaf5412186dcf3117ee835052f23754.png "align-center")

This is physics and has to do, in my opinion, with OOP more or less like physical.
The solution I think is θ' = π - θ because I should have taken PP' instead of P'P. Reply by xrj
Member Avatar
Hello. I'm using Unity3d to create a simple turret simulation and I have run in to a problem.

I need to find the angle to an object from the turret in 3d space.

Up to this point I thought I could just take the (arc)trig values retrieved from certain perspectives … Topic by Curious Gorge in Game Development
Member Avatar
Topic by josh_4 in Programming
Try this:

Imports System.Xml
Imports System.Reflection
Imports System.IO
Imports System.Text
Imports System.Text.RegularExpressions

Public Class treeViewLoadXml

Dim imgLst As New ImageList
Dim vImgPath(-1) As String, iv As Int32 = 0
Private Sub treeViewLoadXml_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
imgLst.ImageSize = New Drawing.Size(30, 27)
LoadXML()
End Sub
Private Sub LoadXML() … Reply by xrj
Member Avatar
Topic by Alv45525 in Community Center
Perhaps you are asking for `DataGridView1.CellClick`event ? Reply by xrj
Member Avatar
Hi i have a gridview displaying data at page load and i added a column delete.

i have the primary key of the table displayed in the gridview as foreignkey in another table. so i cannot use wizard to just type my SQL in delete command.

Can someone please help … Topic by Alv45525 in Community Center
Member Avatar
Featured xrj 73 Replied To a Post in What WndProc Windows Message for this
Topic by Mr.M in Software Development
You must develope and install a driver. Search for MS' DDK, driver deveopment kit. Reply by xrj
Member Avatar
Featured xrj 73 Began Watching What WndProc Windows Message for this
Hi DW.

Anyone know what/which type of WndProc Windows Message is raised when someone is burning a CD? What I mean here is that if I'm using a software like Nero which is a well known CD burning software. My question is that what type of WndProc Message this software … Topic by Mr.M in Software Development
Member Avatar
Topic by Bim_2 in Programming
Be more explicit, please, and explain what amount, what listbox and what code is there. Copy here any code you have and tell what you expect the program to do for you. Reply by xrj
Member Avatar
how can i update my Amount text . whenever i remove items in my list box ..

i desperately need this for my project . Topic by Bim_2 in Programming
Member Avatar
Topic by Alv45525 in Databases
Do you get any error message? Enclose in a `try/catch`. Variable `bFound` is what for? Reply by xrj
Member Avatar
Hi guys, i have a login page where i created a session trainer after login. the session is the mail address of the trainer.

now from another apsx page, i would like to retrieve the staffid of the user logged in using the session as criteria.
I tried to write … Topic by Alv45525 in Databases
Member Avatar
Topic by josh_4 in Programming
What I get with the variated code:

![treeView3.PNG](/attachments/large/3/70f4dbd4627c370df1f133d563ae1824.PNG "align-center") Reply by xrj
Member Avatar
Topic by josh_4 in Programming
1) Perhaps it can't find the executables because you didn' t employ your's xml:

<?xml version="1.0" encoding="utf-8" ?> <Nodes> <Node Text="Programme" Icon="BlaBlub.ico"> <Node Text="Test" Icon="C:\MyProgramm\Icons\icon2.ico"> <Programm Path="C:\Program Files (x86)\Microsoft Visual" & _
"Studio\2017\Enterprise\Common7\IDE\devenv.exe">Visual Studio</Programm> <Programm Path="C:\Program Files (x86)\Microsoft" & _
"Office\root\Office16\EXCEL.EXE">Excel</Programm> </Node> <Node Text="andere" Icon="C:\MyProgramm\Icons\23.ico"> <Programm Path="C:\Program Files (x86)\Microsoft Visual" … Reply by xrj
Member Avatar
Topic by josh_4 in Programming
Yes, get the `AddNode()` from my last code, because seems to me the `AddNode()` is not working properly

Private Sub AddNode(ByVal inXmlNode As XmlNode, ByVal inTreeNode As TreeNode)
Dim i As Integer
If inXmlNode.HasChildNodes Then
Dim nodeList As XmlNodeList
nodeList = inXmlNode.ChildNodes
i = 0
While i <= nodeList.Count - … Reply by xrj
Member Avatar
Topic by Paul_55 in Software Development
One thing you may do is try to define exactly what do you mean by a complete solution and try by yourself to accomplish that target. Then you may share your code, doubts and difficulties -if any. Reply by xrj
Member Avatar
Hello Everyone,
This website has really helped me as a newbie, thank you. But I really need help with some thing.

I created a database table in vb.net using SQL ServerlocalDB. I also have a listview .

I am trying to save items from the listview to some columns in … Topic by Paul_55 in Software Development
Member Avatar
Topic by Jayanta_1 in Software Development
...also it may be a static variable. Reply by xrj
Member Avatar
Topic by Jayanta_1 in Software Development
The number does not increment because the error counter in `erorcunt` is defined locally, so each time there is a try for username and password `erorcunt` value is 0 and incremented to 1. Define this variable `errorcnt`at class level. Reply by xrj
Member Avatar
Topic by Jayanta_1 in Software Development
What's the message? In which line? Reply by xrj
Member Avatar
Hello
Only one time count the msg ok result. but after that when I type wrong username and password coding not work. please help me .........



Try
Dim erorcunt As Integer
erorcunt = 0
Dim myConnection As OleDbConnection
myConnection = New OleDbConnection("Provider=Microsoft.ACE.OLEDB.12.0;Data Source=|DataDirectory|\DB.accdb;Persist Security Info=False;")
Dim myCommand As OleDbCommand
myCommand … Topic by Jayanta_1 in Software Development
Member Avatar
xrj 73 Replied To a Post in DataGridView Formating
Topic by VIPER5646 in Software Development
I hope it makes sense to you:

Private Sub Dgv_Formate(ByVal e As DataGridViewCellFormattingEventArgs, _
ByVal Stat As String, _
ByVal processDate As Date, _
ByVal Extra_Days As Boolean)
Try
Dim YN As Int32 = IIf(Me.DGV_Machining.Rows(e.RowIndex).Cells(Stat).FormattedValue = "n", 0, 1)
Dim extraDays As String = IIf(Not DGV_Machining.Rows(e.RowIndex).Cells(0).Value, 1, 0)
Dim procDate … Reply by xrj
Member Avatar
Topic by josh_4 in Programming
You are welcome. Reply by xrj
Member Avatar
Topic by josh_4 in Programming
I pass to you all the code again to be sure you can get it well.

Imports System.Xml
Imports System.Reflection
Imports System.IO
Imports System.Text
Imports System.Text.RegularExpressions

Public Class treeViewLoadXml

Dim imgLst As New ImageList
Dim vImgPath(-1) As String, iv As Int32 = 0
Private Sub treeViewLoadXml_Load(sender As System.Object, e As … Reply by xrj
Member Avatar
Topic by josh_4 in Programming
Yes, sorry, you must remove baseStream so the instruction in line #11 will be `dom.Load(_rStream)` Reply by xrj
Member Avatar
Topic by josh_4 in Programming
Then copy the xml file to the executable's folder and replace what now is commented by the uncommented:

' Get Xml's file stream.

'Dim _assembly As [Assembly] = [Assembly].GetExecutingAssembly
''Dim _stream As Stream = _assembly.GetManifestResourceStream("MyNameSpace.XMLFile1.xml")
''Dim _rStream As New IO.StreamReader(_stream)
'
Dim vPath() As String = Split(Application.ExecutablePath, "\")
vPath(vPath.Length - … Reply by xrj
Member Avatar
Topic by josh_4 in Programming
You may perfectly change the xml file outside VS. But whenever you want to distribute or use the executable you'll have to compile first, that's all. Reply by xrj
Member Avatar
Topic by josh_4 in Programming
Each time you compile in VS, the xml file is embedded into the .exe file. Reply by xrj
Member Avatar
Topic by josh_4 in Programming
I am not very sure if I have understood. The xml file can be modified inside or outside VS, but because it's embedded it goes 'inside' the .exe file. This is, if you copy the executable .exe file to another folder you are also copying the xml file because it's … Reply by xrj
Member Avatar
Topic by josh_4 in Programming

![xmlembed1.PNG](/attachments/large/3/52639665d3fb067a39d7a9f0f3a50b4e.PNG "align-center") ![xmlembed1.PNG](/attachments/small/3/52639665d3fb067a39d7a9f0f3a50b4e.PNG "align-left") ![xmlembed2.PNG](/attachments/small/3/2a6ac470be9bb573cdfce03228a5c1b4.PNG "align-left") ![xmlembed4.PNG](/attachments/large/3/48cf866c32b49b6c40cda484dd844b90.PNG "align-center") ![xmlembed5.PNG](/attachments/large/3/073ca9cc1e2d2dd6ff5ec9a73e5fcedc.PNG "align-center")

In Visual Studio explorer right click over the application name and add a new element: a xml file. Paste the xml text inside the new xml file. Next, right click (in VS explorer) over the xml file name and select … Reply by xrj
Member Avatar
Topic by Alv45525 in Web Development
I hope this helps:

Dim rdr As SqlDataReader = cmd.ExecuteReader
Dim bFound As Boolean = False
If rdr.Read() Then
Dim category As String = rdr("categoryname")
If txtcontent = category Then
bFound = True
End If
End If
rdr.Close()
If Not bFound Then
cmd = New SqlCommand(query2, connect)
x = cmd.ExecuteNonQuery … Reply by xrj