|
Thanx for reference Christian Graus;)
(Jameel)
|
|
|
|
|
anyone know of good c# to vb.net converter (free)
I know a few sites that will convert code but I'd like to be able to convert a project. My college works in c# but my boss wants us to work in vb.net so now I have to convert his code
|
|
|
|
|
A programmer who works in C# and a manager who likes VB - how ironic.
There are some free tools on this site, but you get what you pay for, the commercial ones are going to work better.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Sharpdevelop comes with a converter. It is free, so like Christian said, you get what you pay for.
TDDragon wrote: My college works in c# but my boss wants us to work in vb.net so now I have to convert his code
Huh? I thought you were converting from C# to VB.NET? What does your college work have to do with your boss's work?
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
|
|
|
|
|
Well my boss is the one who detirmens what we will do how we will do it and when
At the start of the project he toled my college (just as he told me) we were werking in vb.net but my college started in c# anyway so now I had to convert his code to vb.net
the reason my boss wants us to work in vb.net is that we are a small software firm that untill very recent only worked in access (vba) and to learn c# with a vba background is more difficult than to learn vb.net
granted they will have to learn the framework anyway but at least vb.net and vba have a simular syntax.
hope this explains
Paul Conrad wrote: Huh? I thought you were converting from C# to VB.NET? What does your college work have to do with your boss's work?
|
|
|
|
|
Hi Ryan,
You can look into TableStyles en ColumnStyles. Just look at the properties of your datagrid and you'll find it. You can map a TableStyle to a dataset or something, and next the ColumnStyles to the dataset's columns. Simply add only a ColumnStyle for the columns you want to display.
You will have to take care of the value in the "hidden" columns by code though, or else you'll receive NULL errors and such.
Good luck,
Johan
My advice is free, and you may get what you paid for.
|
|
|
|
|
Thank You. Johan. But I'm not getting paid for this.
Also, what sql string should I write? "SELECT * from member" only, or "SELECT * from member where memberID = 'txtMemberID'" where the txtMemberID is the new member's id on the form.
Or if possible, please tell me how to do this datagrid step by step. Thank You.
Ryan
|
|
|
|
|
Hi Ryan,
alurora wrote: But I'm not getting paid for this.
Perhaps you misinterpreted my quote, otherwise I don't understand...
alurora wrote: what sql string should I write?
I can only guess at what it is exactly that you are trying to accomplish, so I suggest you consider what sort of user will be using your application and what they want to see / what they are allowed to see / what it is you want them to see.
As for the datagrid, from your original question I understood that you have a form with a datagrid on it, and hopefully a dataset that you fill with data from your tables.
If so just select the datagrid in the designer, and look at its properties. There you will find a property called TableStyles.
If not, what do you have so far?
Johan
My advice is free, and you may get what you paid for.
|
|
|
|
|
Hi all,
I have a project that converts different files in to a PDF Document. For that i have used a third party dll(ABCPDF.DLL). The projects works fine in my PC. When i publish This as a smart client application, this works fine in machines that have ABCpdf installed. But in other machines it gives the following error
Unable to install or run the application. The application requires that assembly ABCpdf Version 5.0.2.0 be installed in the Global Assenbly Cache(GAC) first.
So i have tried in another way. In the publish tab of the project properties, there is a button application files, inside that i have changed the publish status of ABCpdf.DLL from Prerequisite to Include. Then published the application. Then also it gives error. Now the error message is
SmartPDF has encountered a problem and needs to close. We are sorry for the inconvenience.
Please tell me how to solve this Problem
Thanks in advance
Sebastian
|
|
|
|
|
SO what other .DLL or .EXE files does this ABCPDF.DLL library depend on?? That's probably why your app is crashing.
|
|
|
|
|
Thanks Dave for your reply.
I will look in to this point and get you back soon....
Thanks & Regards
Sebastian
|
|
|
|
|
Hi Dave,
As you said, abcPDF.dll refers MSCOREE.DLL, and this refers KERNEL32.DLL and this refers NTDLL.DLL.
Can you tell me what should i do to resolve this issue?
Thanks once agian.........
Sebastian
|
|
|
|
|
mscoree.dll is part of the .NET Framework. If the .NET Framework that the component expects isn't installed, you need to install it.
Also, you can NOT have two different versions of the .NET CLR loaded into the same process at the same time. If this component is written under 2.0, you can't use it in a .NET 1.x app.
As for anything else, you'll have to get with the manufacturer of the component for any further support on it.
|
|
|
|
|
Thanks Dave, Thank you very much.
with best Regards
Sebastian
|
|
|
|
|
how to create password and username using vb.net. i would like to save the username and password in microsoft access.. pls help with the coding....
|
|
|
|
|
Well, a password and a username are both strings, so I guess the easiest thing is to create a table with two columns, and make them both strings.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
This is very straightforward. Like Christian said, both username and password would be strings, and stored in the database as text fields in Access. Encrypt the password using an encryption algorithm of your choice, preferably one that isn't crackable like DES...
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
|
|
|
|
|
Hi,
I have a string strA = "12 MyAddress"
strB = "Your Name"
I want to get the first char of string and want to know weather it is integer between 1-9 or char between A-B.
How can I do that.
seema
|
|
|
|
|
if char.isnumber(stra.chars(0)) = true then
'do something if its a number
else
'do something else
end if
|
|
|
|
|
You have cross posted in three forums! Go to your room! Read the forum guidelines!
_____________________________________________
Flea Market! It's just like...it's just like...A MINI-MALL!
|
|
|
|
|
Don't cross post. It is rude and look at the replies you got in the C# forum. Next time, pick one forum, ideally the language you are writing the code in, and stick to it.
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
|
|
|
|
|
Good day to you,
I'm just this a basic component for classDataAnalyzer. It's supposed to manage code establishing OleDb (Access) connections in Web Applications. Use this class to access what you need I guess that it'll help you get on your feet. Here's the Question for those if you choose to accept it. I've trying to convert this into code at use on a windows form. I need to be able to use this code, but the configuration manager namespace was developed for use on the Web. I need your help with a proper function for building a function that will manage the configuration string in a WinForm.
Thanks
<br />
Public Class AccessOleDb<br />
'''-----------------------------------------------------------------<br />
''' <summary>Gets the local access database connection string.</summary><br />
''' <history>[me] 7/02/07 Created </history><br />
'''-----------------------------------------------------------------<br />
Public Shared ReadOnly Property ConnectionString() As String<br />
Get<br />
Return ConfigurationManager.ConnectionStrings("ACCESS").ConnectionString<br />
End Get<br />
End Property<br />
'''-----------------------------------------------------------------<br />
''' <summary>Executes a sql query command.</summary><br />
''' <param name="query">Ole command to execute.</param><br />
''' <returns>Returns the number of rows affected.</returns><br />
''' <history>[me] 7/02/07 Created </history><br />
'''-----------------------------------------------------------------<br />
Public Shared Function ExecuteCommand(ByVal query As String) As Integer<br />
Dim oleConn As OleDbConnection = New OleDbConnection(ConnectionString)<br />
'Dim oleConn As New OleDbConnection(ConnectionString)<br />
oleConn.Open()<br />
Dim oleCmd As New OleDbCommand(query, oleConn)<br />
Dim intRows As Integer = oleCmd.ExecuteNonQuery()<br />
oleConn.Close()<br />
oleConn.Dispose()<br />
oleCmd.Dispose()<br />
Return intRows<br />
End Function<br />
'''-----------------------------------------------------------------<br />
''' <summary>Populates a DataSet from the results of the specified query.</summary><br />
''' <param name="query">OleDB query to run against the Access Database.</param><br />
''' <returns>Returns a DataSet with the results of the Access Query..</returns><br />
''' <history>[me] 7/02/07 Created </history><br />
'''-----------------------------------------------------------------<br />
Public Overloads Shared Function PopulateDataSet(ByVal query As String) As DataSet<br />
Dim oleConn As New OleDbConnection(ConnectionString)<br />
oleConn.Open()<br />
Dim oaTemp As New OleDbDataAdapter()<br />
oaTemp.SelectCommand = New OleDbCommand(query, oleConn)<br />
Dim dsTemp As New DataSet()<br />
oaTemp.Fill(dsTemp)<br />
oleConn.Close()<br />
oleConn.Dispose()<br />
oaTemp.Dispose()<br />
Return dsTemp<br />
End Function<br />
End Class
Thanks for your help and best wishes to you.
J
|
|
|
|
|
Jordan Martz wrote: but the configuration manager namespace was developed for use on the Web.
No, it wasn't. It was developed to be used in either environment. It's the configuration file that changes. There's nothing to convert. This code will work fine in a Windows Forms app, so long as you have a properly written app.config file in your project.
|
|
|
|
|
What do I remodel in my application configuration
Do I work on the connections for
<br />
<connectionStrings><addname=<br />
"MyProgram.My.MySettings.NWConnectionString"<br />
connectionString="Provider=Microsoft.Jet.OLEDB.4.0;<br />
Data Source=|DataDirectory|\DataConnections\NW.mdb providerName="System.Data.OleDb" /></connectionStrings><br />
Thanks Dave
|
|
|
|
|
So long as your app.config has a <connectionStrings> section, something like:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
</configSections>
<connectionStrings>
<add name="MyAccessDBConnectionString"
connectionString="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=...."
providerName="System.Data.OleDb" />
</connectionStrings>
</configuration>
In your code, the connection string name would be, in this example obviously, MyAccessDBConnectionString .
|
|
|
|