|
Yeah, so?
"txt" is not a reserved extension for some special format. Likewise the extension of your file could just as easily be "dat" or "casper".
I merely meant to suggest that you not use the format shown if at all possible.
|
|
|
|
|
Hello everyone,
Here is the description about when to use Pulse and when to use PulseAll to achieve best performance.
My question is, I do not quite understand this situation, "Sometimes, however, different threads are waiting on different conditions, but all waiting on the same monitor. In that case, you need to use PulseAll so that you make sure that the thread which is waiting for whatever condition has just occurred is able to notice it and make progress."? Could anyone show a scenario about what means "different threads are waiting on different conditions, but all waiting on the same monitor" please?
(the link and related whole paragraph is quoted below)
http://www.yoda.arachsys.com/csharp/threads/deadlocks.shtml
--------------------
The reason for having both Pulse and PulseAll is for different situations, where you're waiting on different conditions. If either there'll only be one thread waiting, or (as is the case above) any thread can consume any produced object, you can just use Pulse. If there are several threads waiting on the object, that ends up being more efficient than PulseAll - there's no point in waking up a bunch of threads if you know that only one of them is going to be able to make progress, and that it doesn't matter which you wake up. Sometimes, however, different threads are waiting on different conditions, but all waiting on the same monitor. In that case, you need to use PulseAll so that you make sure that the thread which is waiting for whatever condition has just occurred is able to notice it and make progress.
--------------------
thanks in advance,
George
|
|
|
|
|
Hi All,
I'm just looking into the options for including either SQLExpress or SQL CE for my local (one user) data store. Having read up on it some it seems that there are more security considerations if you include SQLExpress (and a larger download). Has anyone here deployed an app that used SQLExpress to very non-thechie users?
How much more complicated is it to embed SQLEXpress over SQLCE?
Cheers,
Jammer
Going where everyone here has gone before!
My Blog
|
|
|
|
|
make a installer that will install SQLExpress before installing your app
i think you cannot embed sql in your app
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Hi,
I've basically opted for SQLCE. After reading up on the two on the MS site (there is loads of good comparison stuff there) it seems that SQLCE should to the trick, and its going to make my download a LOT smaller ... like 1.8mb for SQLCE vs 60mb for SQLExpress.
Your right, SQLExpress is not embeddable like SQLCE and makes the install process potentially a LOT more complex.
Cheers,
Jammer
Going where everyone here has gone before!
My Blog
|
|
|
|
|
If your looking for a small, lightweight db to bundle with your apps how about SQLite?
ADO.NET provider for SQLite available here
But fortunately we have the nanny-state politicians who can step in to protect us poor stupid consumers, most of whom would not know a JVM from a frozen chicken. Bruce Pierson Because programming is an art, not a science. Marc Clifton
|
|
|
|
|
Hi,
I wanted to know if there's a way to stream live audio ( like live radio ) from the web and than saving it in a way so I can hear it. After that I want to be able to convert it to mp3 format.
I tried to use WebClient object but got an array of bytes. where do I go from here? or is there a better wat to do it?
|
|
|
|
|
You could use LAME to encode the stream into MP3 audio. Check out http://lame.sourceforge.net/download.php[^] for the source code. LAME compiles to an executable, so you could then save the stream to disc and pass the saved file to the LAME codec. Command line options are available at http://lame.cvs.sourceforge.net/*checkout*/lame/lame/USAGE[^]
This of course assumes that the audio data you are receiving is in standard RAW WAV format. If the audio is being played in a player like QuickTime or Windows Media player, you will need to convert from the wma, or aac formats to WAV first.
Hope this steers you in the right direction.
modified 30-Aug-22 21:01pm.
|
|
|
|
|
How can I tell what is the format of the data? I just got an array of bytes.
|
|
|
|
|
Well, unless you know where the data is coming from and in which format, there's no real way to tell unless you plan on writing some heavy code that will fish out which format the data is in. A good clue would be which player is used to play the content. My guess would be that quicktime player uses AAC format, Windows Media Player uses WMA. Do you have an example of a URL the stream is coming from?
modified 30-Aug-22 21:01pm.
|
|
|
|
|
|
It seems that the format you are receiving is ASF... You will need to get hold of some sort of ASF to MP3 converter to convert the stream you are receiving from the site. This would be a good time to just mention the word 'copyright'
modified 30-Aug-22 21:01pm.
|
|
|
|
|
I am having difficulty binding to a property exposed on an remoted interface.
I have an interface called IProduct, which is exposed through a data provider class which is hosted on a remoting server using TCP Channels.
The interface:
<br />
public interface IProduct : IEntityBase<br />
{<br />
System.String Name { get; set; }<br />
System.String Description { get; set; }<br />
System.Decimal UnitPrice { get; set; }<br />
System.Guid ProductTypeID { get; set; }<br />
System.Guid CatalogueID { get; set; }<br />
System.Guid ParentProductID { get; set; }<br />
}<br />
The provider:
<br />
public interface IEntityDataProvider<T> where T : IEntityBase<br />
{<br />
T[] GetAll();<br />
T GetNew();<br />
T Get(System.Guid id);<br />
int InsertUpdate(T entity);<br />
void InsertUpdateBatch(List entityList);<br />
void Delete(T entity);<br />
}<br />
When I bind a combobox to the result of GetAll(), it works as expected and the combobox is populated with all instances of the type. The ClientDataProvider caches results, so don't get scared by the continuous use of GetAll().
<br />
IEntityDataProvider<ProductType> ProductTypeDataProvider =<br />
new ClientDataProvider<ProductType>();<br />
<br />
_ProductTypeIDCombo.BeginUpdate();<br />
_ProductTypeIDCombo.DataSource = ProductTypeDataProvider.GetAll();<br />
_ProductTypeIDCombo.ValueMember = "ID";<br />
_ProductTypeIDCombo.DataBind();<br />
_ProductTypeIDCombo.EndUpdate();<br />
My problem is as follows:
<br />
_NameTextEditor.DataBindings.Add("Value", [value returned from Get() on dataprovider], "Name");<br />
When binding to a textbox, I get a "Cannot bind to the property or column Name on the DataSource. Parameter name: dataMember" Argument exception.
What am I doing wrong?
modified 30-Aug-22 21:01pm.
|
|
|
|
|
Hi,
I'm setting up a system (both web based and app based) where there will be roles and permissions. There will be build in roles with specific permissions, but users can also create custom roles, with a certain subset of permissions. So the standard role based security framework doesn't work for me. Could somebody give some pointers of how to setup a role and permission based security framework?
Thanks in advance,
Gidon
|
|
|
|
|
Hello
I have a big problem and don'tt know how to avoid it
basicly the problem is coming because I can't disable the automatic sort on a DataGridView (DGV)
1- I load a table with a query, on column (order) is sorted with ascending numeric values
2- The table is binded to a DGV
3- At this point I programaticaly renum the order column with a step 5 : 5, 10, 15, etc
It is OK
BUT if before to do the renum I sort the DGV on that column and immediately reset the property to notsortable, the automatic sort remain active
dgv_rit.Sort(dgv_rit.Columns["order1"], ListSortDirection.Ascending);
dgv_rit.Columns["order1"].SortMode = DataGridViewColumnSortMode.NotSortable;
So, for now nothing seems to be changed in the DGV because it was already sorted !
But if I renum now, everything goes wrong because the automatic sort is still active and each row I change is automaticaly sorted to another place !!!
Too bad !!
|
|
|
|
|
since you have binded it with table then it cannot be change (CMIMW)
but if you do change in datatable then it will work
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Hello
Thank you
But what do you mean ?
I DO make the changes directly in the datatable
It works fine since I do not make any programatic SORT to the DGV
The problem comes when I sort the column programaticaly in the DGV
After that the DGV stils sort automaticaly on ANY changes to the datatable or manualy by the user
So the question is HOW to avoid that the DGV sort automaticaly
If it is not possible I probably have to feed a DGV manualy without any bind to a datatable
Too bad !
|
|
|
|
|
Hello Xmen
Is it possible to sort the datatable instead DGV maybe this is the solution ??
|
|
|
|
|
perhaps not, but you can do a trick
use Select(), it have a parameter named sortby, this function will return DataRow[], and then you can add those rows to your DGV
this will work as you want
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Hello
I will see what I can do with that
The goal is to allow the user to change a sequence on row using an order column
As long as the value are entered manualy, it works
If I do a sort (programaticaly) at any time, it stills work but the behaviuou of the DGV is changes : it sort now automaticaly
Considering that it is impossible to renu programaticaly because to renum I have to follow the order, so to follow the rows order in the DGV to acceed the datarow and gives a new number. If that new number directly affect the order in the DGV it can't works
I yhink this is a bug in DGV
|
|
|
|
|
One step beyond !
Yes ok
I can work better using Tables.Select()
However the Dgv autosort is still a pain !
|
|
|
|
|
hi all,
I have a question on COM components.
After usage of com component how to clean up the com component ,
Can someone suggest me how can i proceed ,
Thanks
Mukkanti
|
|
|
|
|
You have to explicitly clean the com object in your code.
Use override dispose function in class where you are using the com class and after using the com object clean it in your dispose function.
Sarvesh Upadhyay
Senior Software Engineer
Birlasoft India Ltd.
Microsoft Certified Professional Developer in Dotnet 2.0 Enterprise Application
|
|
|
|
|
Hello..
I have this code:
<br />
float x = 0.5f;<br />
float y = 1.0f;<br />
<br />
private void ProcessInput(float amountOfMovement)<br />
{<br />
Vector3 moveVector = new Vector3();<br />
<br />
KeyboardState keys = Keyboard.GetState();<br />
if (keys.IsKeyDown(Keys.Right))<br />
moveVector.X += amountOfMovement;<br />
if (keys.IsKeyDown(Keys.Left))<br />
moveVector.X -= amountOfMovement;<br />
if (keys.IsKeyDown(Keys.Down))<br />
moveVector.Y -= amountOfMovement;<br />
if (keys.IsKeyDown(Keys.Up))<br />
moveVector.Y += amountOfMovement;<br />
<br />
if (keys.IsKeyDown(Keys.Add))<br />
x += 0.1f;<br />
y += 0.1f;<br />
if (keys.IsKeyDown(Keys.Subtract))<br />
x -= 0.1f;<br />
y -= 0.1f;<br />
<br />
Matrix cameraRotation = Matrix.CreateRotationX(cameraAngles.X) * Matrix.CreateRotationZ(cameraAngles.Z);<br />
cameraPosition += Vector3.Transform(moveVector, cameraRotation);<br />
<br />
MouseState currentMouseState = Mouse.GetState();<br />
if (currentMouseState.X != previousMouseState.X)<br />
cameraAngles.Z -= amountOfMovement / 80.0f * (currentMouseState.X - previousMouseState.X);<br />
if (currentMouseState.Y != previousMouseState.Y)<br />
cameraAngles.X -= amountOfMovement / 80.0f * (currentMouseState.Y - previousMouseState.Y);<br />
Mouse.SetPosition(Window.ClientBounds.Width / 2, Window.ClientBounds.Height / 2);<br />
}
how to change it to gamepad code?
[img]http://img488.imageshack.us/img488/6241/signaturesakirahku9.jpg[/img]
|
|
|
|
|