|
How to let the user write In numbers only in a textbox?? :-? If someone type in letter A the program will pop up a messagebox! How can i read the textbox with ASCII?
Adrian De Battista
|
|
|
|
|
|
PsYcHo_A wrote:
How to let the user write In numbers only in a textbox??
you could override the KeyPress event, with the IsNumeric() function...
PsYcHo_A wrote:
If someone type in letter A the program will pop up a messagebox!
i don't recommend you to popup a message box each time the user press a wrong key ; it will fastly become irritating to him. Prefer the error providers instead ; you could display an icon next to the control you want, without blocking the user.
PsYcHo_A wrote:
How can i read the textbox with ASCII?
use the TextBox.Text() method...
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
error provider will be more sufficient . its also recommended from no. of professionals. u can search this topic from MSDN with keyword "error provider"
|
|
|
|
|
i know i know, it's what i said...
i think you told to the wrong person though
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
sorry dear . actually I wanted to tell the person who putted question there
|
|
|
|
|
Hello'
In crystal report I have used parameters list .I am assigning valuse from my code but when I open the report its promting for parameter values.
I dont want this promting beside I am passing values to parameters. any hint for solution ?
Regards
|
|
|
|
|
I am using ILMerge to merge my DLLs and it works great. I have run into my first problem unfortunately. I am creating A/V apps using DirectX 9.0c SDK for XP. This is the only SDK whose DLLs I cannot merge with my other DLLs to create a combined assembly. If I exclude the DX DLLs, ILMerge works fine. Here is the syntax I use.
c:\> ilmerge /target:library /out:test.dll Interop.Scripting.dll Microsoft.DirectX.AudioVideoPlayback.dll
If I include anyother dll besides the DirectX dll, I will get the merged DLL. If I use the DX dll, ILMerge will start and return to the prompt without creating the merged assembly.
Has anyone run into a similar problem or does any one have a possible solution to this problem?
Thanks.
|
|
|
|
|
I have never used it and don't think I ever will. But, since the AudioVideoPlayback more than likely has dependancies on other .DLL's that your not including. You'll probably also have to include the DirectX base .DLL's the managed version wrap. I think your looking at including another 6-10 .DLL's in your merge.
IMHO, I don't think it's a good idea to do this with the DirectX .DLL's. I think you'll be much better off just making a prerequisite of your application DirectX 9.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I think I might have included the DirectX base DLL but dont think that made a difference. ILMerge will just merge the DLLs, whether it fucntions or not is secondary, at the moment my concern is just the merge. I have merged all sorts of DLLs without a problem, WMP10, Scripting, Runtime, Enviroment etc. The reason I need to merge this is because I am saving my usercontrol on my flash drive and acessing my PC or laptop to futher build my user control from the flash drive. As a result, I get some dependency issues when I try to use my user control on different system besides the one it was created on.
|
|
|
|
|
Dr_Lomax wrote:
I think I might have included the DirectX base DLL
"DLL", as in singular? How about trying to include ALL the drawing .DLL's. Well, not the 3D ones anyway.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
There is a base DirectX dll and there all all the different interfaces i.e. 3D, Sound, Input etc. Eitherway adding all these additional dependency should affect the functionality of the merged DLL, not the merging process itself. I am concerned about the merging. I will add the additional assemblies when required.
|
|
|
|
|
hi ppl,
i'm facing three problems can anyone guide me. it will be of great help. i'm using vb.net and ms access as database. the problems are as follows:-
1). I have a database with one table named project name with only one field. what i need is to get any particular record from that table to be displayed in a textbox named txtproject.
2). another problem is that i have a web form with 3 textboxes, 3 labels and 1 button named print. what i need is to get is that on click of button only the text fields of labels and textboxes to print on paper.
3). The problem is that i want to create a logon page. i have a database in access which has one table and two coulmns username and password. how do i do it.
Thanks and Regards
Manik
|
|
|
|
|
1. Look at the System.Data namespace for connecting to your DB and running SQL against it
2. I doubt you can do it, you need a button that says 'print view' which renders what you want to print in a new window.
3. The web is full of info on how to create a login page using the built in features of ASP.NET.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Hi Chris,
Thanks For your advice. But the first Problem i'm still not able to figure out how assign value to textbox. a bit of code will help. If possible please help me.
Manik
|
|
|
|
|
You need to look up references before asking, because otherwise you'll never learn how to work stuff out for yourself.
If you have a TextBox, called tb, then tb.Text = "This is the Text" will assign a value to a TextBox.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Thanx Chris for your valuable sugesstion of how to assign value to textbox but the question here was to get only one record from a list of records in database. ne ways i solved the problem. i think you are right that everyone should learn on their own.
Thanks and Regards
Manik
|
|
|
|
|
manik nath wrote:
i think you are right that everyone should learn on their own.
Hi Manik. I didn't mean that you shouldn't ask for help, just try to solve the problem yourself first. And perhaps explain it better, I read your second to last response as meaning you didn't know how to set a string to a textbox, and because that's such a basic question, I answered it AND said that for questions like that, you really shouldn't need help.
But, by all means, ask for help when you're stuck, that's what this forum is for.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Good day everyone,
I am using Crystal Report, my report file run on Crystal Report 10.0 is right, I use the Crystal Report Viewer in VB.NET for showing it, when I debug to Show() function, I got the alert "The request could not submitted for background processing." Please verify this problem.
I have to be sure before continue with this approach. So, please guide through your help.
Thanks for your help, Have a good day.
|
|
|
|
|
try to verify database and also use
crystalReportViewer1.RefreshReport
may be helpful
|
|
|
|
|
Hi, i am a beginner in Software programming.
Q1) Can anyone tell me how to design a TCP/IP networking which the Server only listen to a specific CLient...
Let say.
Both Client and Server are using Port 8080.
A client been fixed with an IP ("192.168.0.2").
The Server will only wait(listen) to the CLient with IP("192.168.0.2")only.
My design is as following, but always give error "SocketException", Can anyone help me to correct it.
Dim connection As Socket
Dim socketStream As NetworkStream
Dim writer As BinaryWriter
Dim listener As TcpListener
Dim ipAddress As IPAddress = Dns.Resolve("192.168.0.2").AddressList(0)
' wait for request, then establish connection
Try
listener = New TcpListener(ipAddress, 8080)
listener.Start()
' accept an incoming connection
connection = listener.AcceptSocket()
' create NetworkStream object associated with socket
socketStream = New NetworkStream(connection)
' create objects for reading
writer = New BinaryWriter(socketStream)
' inform client that connection was successfull
writer.Write("SERVER>>> Connection successful")
Catch abc As SocketException
txtDisplay.Text = abc.ToString()
End Try
Q2) How can i display the CLient's IP address in Server side if sucessfully connected. Pls provide example code...
Thanks a million. Cheers.
|
|
|
|
|
Ok, I know what you are thinking. Why was this posted on the VB.Net forum? Well, let me explain.
I Have a DHTML text editor that I currently import Microsoft Word documents into via IE. The only problem is only text comes across currently. I came across info on MSDN that said images can be saved out of Word 2003 as bmp files. So far I can open the document, get a handle on each image, and copy them to the clipboard, but for some odd reason, probably my fault , I can't seem to save them to the hard drive.
I've included the code below, perhaps you can assist, especially if you know MS VB.NET and VBScript better than I, which wouldn't be difficult to do. Basically I get the image copied to the clipboard fine but then I don't seem to be saving anything out. Nothing fails, it just doesn't save. Any help would be greatly appreciated.
Sub ImportWordDoc()
On Error Resume Next
Set wApp = CreateObject("Word.Application")
wApp.Activate
wApp.WindowState=0
call wApp.Resize(400, 400)
Set wDoc = wApp.Documents.Open(document.all.FileToOpen.value)
wApp.Visible = true
For index = 1 To wDoc.InlineShapes.Count
inlineShape = ""
Set inlineShape = wApp.ActiveDocument.InlineShapes(index)
inlineShape.Select()
wApp.Selection.CopyAsPicture()
data = ""
Set data = Clipboard.GetDataObject()
If data.GetDataPresent( GetType( System.Drawing.Bitmap )) Then
bmp = ""
bmp = CType(data.GetData(GetType(System.Drawing.Image)), Bitmap)
bmp.Save( "C:\mybitmap" + cstr(index) + ".bmp" )
End If
Next
Call wDoc.Close(True)
call wApp.Quit(True)
End Sub
|
|
|
|
|
I have made an Excel Addin that creates four buttons and links them to my forms to retrieve data. I used a Shared Addin project so that I would get a .msi file generated for me when I built the solution. All is well until I attempt to remove the addin. The msi file as put an entry into the Add/Remove Programs list so I simply went there and clicked remove. I went back to Excel and the buttons were still there. I have restarted the machine and the buttons continue to exist and connect to the forms that should have also gone away.
Any suggestions on how to get rid of it?
As a side point that may be of some concequence, when I reinstalled the program I ended up with 6 buttons coming up. All of these buttons link to the appropriate form. I believe this problem is related to the following code from my connect.vb file.
This only creates one button:
MyCJ = oStandardBar.Controls.Item("CJ")
If MyCJ Is Nothing Then
MyCJ = oStandardBar.Controls.Add(1)
With MyCJ
.Caption = "CJ"
.Style = MsoButtonStyle.msoButtonCaption
.Tag = "CJ"
.OnAction = "!<SEOEXCELADDIN.Connect>"
.Visible = True
End With
End If
This buttons gets duplicated:
MyTD = oStandardBar.Controls.Item("TD")
If MyTD Is Nothing Then
MyTD = oStandardBar.Controls.Add(1)
With MyTD
.Caption = "TopDrivers"
.Style = MsoButtonStyle.msoButtonCaption
.Tag = "TD"
.OnAction = "!<SEOEXCELADDIN.Connect>"
.Visible = True
End With
End If
|
|
|
|
|
hey,
Here is a wierd problem I've been breaking my head over for the last couple of days........ I am writing a program in VC which reads information off a window written in VB using the windows handles which I obtain programatically (and which can be viewed by Spy++). The object that I want to read stuff from contains 4 other objects
1. A drop down
2. Label (which I want to read)
3. A Tree
4. Some gif
Through Spy++ when I view this object within the VB application it shows it as "ThunderRT6UserControlDC" ( which is a VB thing ). However I cannot view 1 and 2 through Spy ++ while I can view 3 and 4....now I know that 1 and 2 are a part of the "ThunderRT6UserControlDC" cause I can hide the parent and all 1,2,3 and 4 disappear. If I can get the handle to 2 I can read in the text
Someone PLZZZZZZZZZZZZZZ help me with this its killing me.
To show it disgramatically -->
"ThunderRT6UserControlDC"
------------------------------
+ 2 +
+ 1 4 +
+ 3 +
+ +
------------------------------
|
|
|
|
|
sorry that diagram got screwed up the '+' forms the right side of the form user control
|
|
|
|