|
Can we have a static block in VB.net just like we have in java ?
If yes can you please provide me a syntax for it !
|
|
|
|
|
Your question gives the answer. A static method or property in VB is called Shared.
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
|
A 'static' initializer block in Java is really just a static constructor.
So...
class Foo
{
static
{
...
}
}
just converts to:
Friend Class Foo
Shared Sub New()
...
End Sub
End Class
(via 'Java to VB & C# Converter')
David Anton
http://www.tangiblesoftwaresolutions.com
C++ to C# Converter
C++ to VB Converter
C++ to Java Converter
VB & C# to Java Converter
Java to VB & C# Converter
Instant C#: VB to C# converter
Instant VB: C# to VB converter
Instant C++: convert VB, C#, or Java to C++/CLI
|
|
|
|
|
ok thanks i go through it
|
|
|
|
|
Hi folks
Hope you can give me a hint, I've spent 3 days trying to sort this out!
Working in visual studio 2005 proff, with .net framework 3.5.
Application has got various forms that are children of a parent.
All are loading, adding, saving and deleting fine. Apart from one.
I've tried an insert and made it a scaler. I've tried all sorts and just cannot get this to save.
It will do MemberID (Primary key) ClientsMare, and clientsid(fk) but clientsname, maresname, percentage no go Here's the Public Sub for Saving.
Public Sub SaveMember()
Adding = False
Deleting = False
lblMemberID.Text = CurrentMemberID
Me.SyndicateMembersBindingSource.EndEdit();
Me.SyndicateMembersTableAdapter.InsertMember(CurrentSyndicateID, MaresName, CurrentMareID, CurrentPercentage, CurrentClient)
Me.SyndicateMembersTableAdapter.Update(Me.DachelDataSet.Tables("SyndicateMembers"))
Welcome.btnSave.Enabled = False
'ONCE FINISHED NEED TO MAKE THIS FILL TO A FILLBYSYNDICATEID
Me.SyndicateMembersTableAdapter.FillByMember(Me.DachelDataSet.SyndicateMembers, CurrentMemberID)
Welcome.btnAdd.Enabled = True
End Sub
any ideas why I'm having this prob on just one form?
Thanks
Kris MCP
|
|
|
|
|
Because you're using the nasty built in stuff, you're just plain hoping it magically writes the right SQL for you. Write your own SQL and then you'll have control over what it does.
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
Thanks for that, I'll do that. Sorry for the late reply, been in meeting all day.
Kris MCP
|
|
|
|
|
i have some problems to do a rotation in vb.net.. i found out a few codes but when i applied it in vb.net...it failed..
i hope someone can helped me. tq
|
|
|
|
|
dunkin_ina wrote: i have some problems to do a rotation in vb.net..
Rotation of what?
dunkin_ina wrote: i found out a few codes but when i applied it in vb.net...it failed..
What do you mean exactly with "failed"?
dunkin_ina wrote: i hope someone can helped me.
Not likely unless you get a lot more specific...
Despite everything, the person most likely to be fooling you next is yourself.
|
|
|
|
|
actually..i want to rotate a map..like to do a automatic rotation to a maps for vehicle used. i'm using visual basic 2008 to do the coding for the rotation, but i dont know how to specified the code just for rotation part.
|
|
|
|
|
If you want to rotate an image, then the grapics object as a rotation transform. But, as others ave said, we're left guessing waht you want as you give us nothing to work on.
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
here, i just want to know how i'm supposed to rotate the map / object in vb.net?..what code should i use..
|
|
|
|
|
The code that draws the map uses a graphics object. Set it's rotation transform first, and reset it after.
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
rotation transform?..do you have an example for the codes in vb 2008?
|
|
|
|
|
On the cell elave event how do you get the name of the column? I am wanting to ren certain calculations for certain columns and need to knw what cell was just left.
Thank you, Chester
|
|
|
|
|
Try this:
DataGridView1.CurrentCell.OwningColumn.Name.ToString
"I love deadlines. I like the whooshing sound they make as they fly by." (DNA)
|
|
|
|
|
hello ,
is this possible in VB Net???
I deed write what we can call a wordprocessor ( well an advanced editor )
and i would like to make it WYSIWYG !
but I do not know how
any one can help??
please
if you_know_the_solution then<br />
help me<br />
else <br />
just a comment <br />
end if
|
|
|
|
|
Yes, it's all possible. Now, get to work
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
He asked in another forum earlier
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
Hello friends,
I have developed a windows application in VB.Net.
I want the IP Address of the user using the application.
I found some code on internet but it is returning the local IP Address.
I need the main IP Address provided by the ISP.
Can anyone help me, plz its urgent.
Thanks,
Nagendra.
|
|
|
|
|
Does your application actually interact with the internet ?
http://articles.techrepublic.com.com/5100-10878_11-6120605.html[^]
does that return the computers IP address and not the IP address on the internet ?
Christian Graus
Please read this if you don't understand the answer I've given you
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Yes it does.
It returns my computer's IP address but i want Internet's IP address.
|
|
|
|
|
I hav already tried method told by u, it gives me my local IP address but i want the main IP address provided by ISP
|
|
|
|
|
Hi,
IFAIK there is no code for getting the public IP address; what you need is a web page that
provides you such information, such as http://www.perceler.com/getipadr1.php[^]
You could use HttpWebRequest.GetResponse() to use it programmatically.
|
|
|
|