|
you would need to do it at the form level.
+turn keypreview on (property of the form)
+in the keydown_event, add the code to test if the control key is pressed and the b key is pressed via the 'e' argument of the routine
+if so, call brwse_button_click(nothing,nothing)
typically however, you also give the user a "hint" that the hot-key is available via a menu item or someother means. if you use the menu item, then you can assign the hot-key there.
Nathan
'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous
'Life's real failure is when you do not realize how close you were to success when you gave up.' ~ anonymous
|
|
|
|
|
Whoops! Wrong reply button...
|
|
|
|
|
In addition to what nlarson said, move that code you want to call to its own sub instead of putting everything in the button handler. This will allow you to call the code from anywhere in the form without passing in arguments you don't have.
|
|
|
|
|
hi there
i want to check that IS SqlServer2005 is installed on my machine ???
i am using VB6.0
how can i do that ??
If the message is useful for U then please Rate This message...
Be a good listener...Because Opprtunity knoughts softly...N-Joy
|
|
|
|
|
Really am not a Fan of VB6 and i dont know why you still use it. But here is an example of C#
http://blogs.msdn.com/sqlexpress/archive/2006/07/29/682254.aspx[^]
to convert between languages use the Following link http://converter.telerik.com/[^]
Remember this is not for vb6
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.somee.com
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
Hi,
I'm new to the programming world, but not the computer world. Anyway, I've just recently downloaded Visual Basic 2008 Express Edition, and so far I love it. However, I came across an old source file that's opensource on SourceForge.net and downloaded it. I was trying to upgrade the Project1.vbp using the VB2k8 Express upgrade wizard when it told me that the upgrade failed because the mdlFormHandling.bas file was missing. The problem is, I went into the folder and looked and it's not missing. It's right there. I took some screenshots to show you if anyone could please, please, please, please help me. I'm just a lowly college kid! No money for the big guns yet! >.<
The Upload Error Screenshot - http://i927.photobucket.com/albums/ad117/teknozwizard/UpgradeError.jpg[^]
File is there Screenshot - http://i927.photobucket.com/albums/ad117/teknozwizard/Fileisthere.jpg[^]
Please help this newb!!!
|
|
|
|
|
By the look of it, the studio is looking for the file in a different place. Check the path in the error message, against the path that the bas file is actually in.
You may have to copy the file to the path mentioned in the error message.
My advice is free, and you may get what you paid for.
|
|
|
|
|
I've got and tried to track through that filepath and.....nothing. I've done a system wide search and I don't have a file labelled "VB98" to try and find and get into to follow the rest of the path. I'm completely at a loss here. I thought that maybe it was looking for a library I didn't have so I went online and downloaded the libraries for VB2k8EE from microsoft's website and installed them, but unfortunately, I'm still having the same trouble....I can't copy the file's into the location because the location it's looking for them in doesn't seem exist and I'm not even sure what the full filepath would be because it gets cut off with the "\...\...\...\VB98\" and etc...I thank you for your response though.
|
|
|
|
|
You could try to copy the entire folder with the project you want to upgrade, to another location (preferably a simple one like c:/temp/myproject/), and try and upgrade again from there.
My advice is free, and you may get what you paid for.
|
|
|
|
|
hi to all
this may sound stupid cause i'm new to VBA.
in C# we are able to write in this way if i'm not wrong
int n = Convert.Toint16(textbox.Text)<br />
but how to write in VBA ???
thanks
veon
|
|
|
|
|
Dim n As Integer
n = CInt(textbox.Text)
I don't speak Idiot - please talk slowly and clearly
I don't know what all the fuss is about with America getting it's first black president. Zimbabwe's had one for years and he's sh*t. - Percy Drake , Shrewsbury
Driven to the arms of Heineken by the wife
|
|
|
|
|
hi
i have try this code but it jus keep saying object required?
this is what i code
Sub Delete_Row_Excel_VBA()
Dim n As Integer
n = CInt(tbxRow.Text)
Rows(n).Select
Selection.Delete Shift:=xlUp
End Sub
|
|
|
|
|
What is
<br />
<blockquote class="FQ"><div class="FQA">veon cheng wrote:</div>tbxRow.Text</blockquote><br />
I don't speak Idiot - please talk slowly and clearly
I don't know what all the fuss is about with America getting it's first black president. Zimbabwe's had one for years and he's sh*t. - Percy Drake , Shrewsbury
Driven to the arms of Heineken by the wife
|
|
|
|
|
hi
tbxRow is the id of the textbox, i name it as tbxRow
thanks
veon
|
|
|
|
|
try to use
Val in the place of CInt
hope it helps....
If the message is useful for U then please Rate This message...
Be a good listener...Because Opprtunity knoughts softly...N-Joy
|
|
|
|
|
hi
thanks for replying, but its the same error
thanks
veon
|
|
|
|
|
Are you sure your variable has any value?
|
|
|
|
|
hi
thanks =)) its solved. as i run the code in macro it does not work but when i change it to a button it works =)) thanks for all the helps guys.
anw can i have some comments, my boss wants me to programe a excel programe to help them generate report. do you think i should do in spreadsheet or forms. which one would be presentable and more interactive??
thanks
veon
|
|
|
|
|
I have to do Excel VBA a lot.
I tend to use the Forms, sometimes just have a macro to call it.
(eg, Ctrl Q to call the form).
I find them easier and more adaptable.
Obviously for simple things like a column transfer or a set of create and save Sheets etc a Macro is easier, especially as you can use the recorder.
It really is a matter of choice, but I think the Forms a) look more professional, and b) imply you have done more work(even if you haven't), so it is better for workplace kudos.
------------------------------------
"When Belly Full, Chin Hit Chest"
Confucius 502BC
|
|
|
|
|
hi
ok so form will be more ideal, but what will be the possible challeng that i will face. besides that is form able to read data from excel, as in use the spreadsheet as the data.
thanks
veon
|
|
|
|
|
Are you asking if the form can use data from the spreadsheet, manipulate it and then move it back to the same or different spreadsheet?
If so, then yes.
Something like ...
<br />
Dim Something as Int<br />
With ActiveWorkbook<br />
Sheets("Name of worksheet").Select<br />
Range ("A1").Select<br />
Something = Selection.Value<br />
Range ("B1").Select<br />
Selection.Value = Something<br />
<br />
Of course you can choose different sheets and manipulate the data or other things as required, this was just a simple example.
------------------------------------
"When Belly Full, Chin Hit Chest"
Confucius 502BC
|
|
|
|
|
hi
ok thanks a lot realy thanks for the help and this is what i want thanks
thanks
veon 
|
|
|
|
|
Hello Experts!!
I am developing crystal reports in vb.net and used MS Access as database having password security, when i want to view reports in project it asked for password of database.
Now i want to avoid that step, so what kind of coding required to pass username and password to crystal report?
|
|
|
|
|
Hi Guys, is there a simple code that I can use. I have a database and I collect information using a query and I want to see all the columns that are in the query when I use a combo box drop down. I am a newbie to visual basic
|
|
|
|
|
You would use a datagridView...
Create a DataTable to hold the query results:
Dim dt As DataTable = New DataTable("MyTable")
Get the data from the database:
Dim conn as New SqlConnection(connString)
Dim sql as String = "SELECT * FROM SomeTable"
Try
conn.Open()
Dim cmd As New SqlCommand(sql,conn)
Dim da As New SqlDataAdapter(cmd)
da.Fill(dt)
conn.Close()
cmd.Dispose()
Catch ex As Exception
End Try
Assign the DataTable to the DataGridView Control's DataSource property:;
DataGridView1.DataSource = dt
...or something like that.
<edit -="" changed="" datagrid="" to="" datagridview="" cmd="" dt="" in="" sqldataadapter="" initialiser="" too="" many="" vb6="" questions="" around="" here...="">
I don't speak Idiot - please talk slowly and clearly
I don't know what all the fuss is about with America getting it's first black president. Zimbabwe's had one for years and he's sh*t. - Percy Drake , Shrewsbury
Driven to the arms of Heineken by the wife
modified on Monday, July 20, 2009 2:48 AM
|
|
|
|