Which is why I explained (or tried) to you that this is not the appropriate place. This forum is for technical questions on Visual Basic. If you want to have a general discussion then the Lounge is the place for it..
Hi, Dave, thank you for your answer, but hereby I mentioned is visualized data computing instead of abstract scripting like R, SQL or esProc. Such computing mode may help users more agilely and directly while dealing with complex data process.
I think users will get interested in it if such mode can improve their convenience and efficiency.
i would like to ask on how to use the control Adobe Pdf Viewer in Visual basic 2010 in terms of Saving ,Retreiving and modifying the pdf file displayed on it through sql server 2005 database.
I can do this with image using picture box but how about in pdf files using Adobe Pdf Viewer?
i have a code for saving and retrieving my image
any modification to my code to solve my problem would be appreciated ..
PublicSub writeImage(ByVal picbox As PictureBox, ByVal sql AsString)
Dim imageBinary = NothingDim myImage As Image = picbox.Image
'Image to byteDim imgMemoryStream As MemoryStream = New MemoryStream()
Dim imgByteArray AsByte() = Nothing
'converts the image to an array of byte :D
imgByteArray = imgMemoryStream.GetBuffer()
'calls the save image function ^_^
EndSubPublicFunction readImages(ByVal pic AsByte()) As Image
Dim imgMemoryStream As MemoryStream = New MemoryStream()
Dim imgByteArray AsByte() = NothingDim myimage As Image
imgByteArray = pic
'convert the binary data and return it as an image ;D
imgMemoryStream = New IO.MemoryStream(imgByteArray)
myimage = Drawing.Image.FromStream(imgMemoryStream)
But is there any other soulution to my problem rather than writing the file to
What did I say?? Using Acrobat Reader, it will ONLY work with files, so NO, there is no other solution. Unless you want to scrap Acrobat and use a 3rd party component. In which case, you've got some researching to do to see what's going to fit your needs and if it's going to be supportable by you.
if you dont mind do you have sample codes for pdf? this will be very helpful for
I don't have any examples, but I'm sure the Web does. A simple Google for "Using Acrobat Reader with VB.NET" should come up with lots of them.
I'm trying to create a class which behaves like a Double only allows values within a certain range.
One of the goals is to have it behave as a normal Double, i.e.: being able to assign Double values to it and pass it to functions taking a Double value.
PublicSubNew(ByVal D AsDouble, OptionalByVal Min AsDouble = 0, OptionalByVal Max AsDouble = 100)
_MinValue = Min
_MaxValue = Max
_dValue = D
If _dValue < _MinValue Then
_dValue = _MinValue
ElseIf _dValue > _MaxValue Then
_dValue = _MaxValue
EndIfEndSubPublic _MinValue AsDoublePrivate _MaxValue AsDoublePrivate _dValue AsDoublePublicSharedWideningOperatorCType(ByVal d As RDouble) AsDoubleReturn d._dValue
EndOperatorPublicSharedNarrowingOperatorCType(ByVal d AsDouble) As RDouble
Dim rd AsNew RDouble(50.0, 10.0, 100.0)
rd = 20.54Dim D AsDouble
D = Math.Round(rd)
The problem with this code is of course that any assignment to the RDouble causes its boundaries to be "reset" since a new one is created with the default _MinValue and _MaxValue; and with the conversion operators being shared there is no way to access the Min/Max values of an instance.
Let me explain in advanced what my goal is and then later I will ask the question. I have to get data from an Oracle database that is spread over several tables. The database connection and view to get the data is already up and running. I am now breaking my head over what the best way is to use the data from the database. The system I am working on work per document. To each document there needs to be data added from the database. I can run a query for each document when needed but I am thinking of loading all the data in to a recordset and use that recordset as a database. I know that if the amount of data is large the memory of the clients computer needs to be sufficient.
So the question now is how would I go about with this?
What is the best way of doing this?
Can I cache the record sets data and then perform SELECT * FROM obj.Recordset?
OK, then you would need to roll your own class to do the caching. Your biggest problem is going to be implementing a some kind of SQL (or some other dialect you invent) parser to do queries against the cached data.
OOOOORRRRR you could write a COM-exposed class in C# or VB.NET and use the DataTable.Select to do the heavy lifting for you. Then you would need to install and register this component and have to VBScript code CreateObject an instance of it, ...blah, blah, blah.
I wanted to avoid installing extra libraries and keep the footprint on the client minimal. I already used a DSN-less connection to the database.
I can instantiate a recordset object so why can't I use the properties you mentioned of the recordset object?
I already used a DSN-less connection to the database.
Which is very common. All a DSN is is a connection string in a text file. Ask some people why their obsessed with using a DSN and they can't give you an answer other than "that's the way I was taught!"
I can instantiate a recordset object so why can't I use the properties you
mentioned of the recordset object?
You can, so long as you don't want to do "SELECT * FROM ..." on that RecrodSet object. You can Filter on the RecordSet and alter what it iteractes over, but whether that will do what you want is unknown. Only you can answer that question.
can instantiate a recordset object so why can't I use the properties you
mentioned of the recordset object?
...and because the Select method doesn't exist on the ODBC.RecordSet object. It exists on .NET's DataTable class, which VBScript cannot use unless you write a COM-exposed wrapper class around it as I mentioned.